|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.stanford.multiagent.gamer.DoubleTensor
The DoubleTensor class can be used to store matrices of any dimension.
Constructor Summary | |
DoubleTensor(int[] dimSize)
Constructor |
Method Summary | |
int |
getNumDimensions()
|
int[] |
getSizeOfDim()
|
int |
getSizeOfDim(int dim)
|
double |
getValue(int[] indices)
Get the value stored at the indexed spot in the tensor |
double[] |
getValues()
Probably won't use this much, but occasionally may be useful to get all values returned in one array. |
void |
setValue(double value,
int[] indices)
Set the value stored at the indexed spot in the tensor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DoubleTensor(int[] dimSize)
dimSize
- an array holding the size of the tensor
in each dimension.Method Detail |
public void setValue(double value, int[] indices)
public double getValue(int[] indices)
public int getNumDimensions()
public int getSizeOfDim(int dim)
public int[] getSizeOfDim()
public double[] getValues()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |