org.optimizationservices.oscommon.datastructure.osgeneral
Class SparseVector

java.lang.Object
  extended by org.optimizationservices.oscommon.datastructure.osgeneral.SparseVector

public class SparseVector
extends java.lang.Object

The SparseVector class holds a two array data structure for sparse representation of vector.

Since:
OS 1.0
Version:
1.0, 03/14/2004
Author:
Robert Fourer, Jun Ma, Kipp Martin

Field Summary
 int[] indexes
          indexes holds an integer array of indexes, which corresponding values are nonzero.
 double[] values
          values holds a double array of nonzero values.
 
Constructor Summary
SparseVector()
          Default constructor.
 
Method Summary
static void main(java.lang.String[] args)
          main for test purposes.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

indexes

public int[] indexes
indexes holds an integer array of indexes, which corresponding values are nonzero.


values

public double[] values
values holds a double array of nonzero values.

Constructor Detail

SparseVector

public SparseVector()
Default constructor.

Method Detail

main

public static void main(java.lang.String[] args)
main for test purposes.

Parameters:
argv - command line arguments.