public class SparseVector extends java.lang.Object
Constructor and Description |
---|
SparseVector(int N) |
Modifier and Type | Method and Description |
---|---|
double |
dot(double[] that) |
double |
dot(SparseVector that) |
double |
get(int i) |
static void |
main(java.lang.String[] args) |
int |
nnz() |
double |
norm() |
SparseVector |
plus(SparseVector that) |
void |
put(int i,
double value) |
SparseVector |
scale(double alpha) |
int |
size() |
java.lang.String |
toString() |
public void put(int i, double value)
public double get(int i)
public int nnz()
public int size()
public double dot(SparseVector that)
public double dot(double[] that)
public double norm()
public SparseVector scale(double alpha)
public SparseVector plus(SparseVector that)
public java.lang.String toString()
toString
in class java.lang.Object
public static void main(java.lang.String[] args)