|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.ojalgo.array.BigArray
org.ojalgo.matrix.store.BigDenseStore
public final class BigDenseStore
A BigDecimal implementation of PhysicalStore.
| Field Summary | |
|---|---|
static PhysicalFactory<BigDecimal> |
FACTORY
|
int |
length
|
| Method Summary | |
|---|---|
void |
add(BigDecimal aNmbr)
|
void |
add(PhysicalStore<BigDecimal> aStore)
|
void |
applyHouseholder(int aFirstTargetCol,
MatrixStore<BigDecimal> aHouseholderStore,
int aHouseholderCol,
Object aColumnArray)
|
BigDecimal |
calculateColumnNorm(int aRow,
int aCol,
int aDegree)
|
BigDecimal |
calculateRowNorm(int aRow,
int aCol,
int aDegree)
|
BigDecimal |
calculateTrace()
|
BigDecimal |
calculateVectorNorm(int aDegree)
|
BigDecimal |
calculateVectorProduct(PhysicalStore<BigDecimal> aStore)
|
boolean |
computeCholesky()
|
LUDecomposition.Pivot |
computeLU()
|
void |
computeQR()
|
BigDenseStore |
copy()
Each call must produce a new instance. |
BigDecimal |
countNonZeroElements()
|
void |
divide(BigDecimal aNmbr)
|
void |
divideElements(PhysicalStore<BigDecimal> aStore)
|
double |
doubleValue(int anInd)
|
double |
doubleValue(int aRow,
int aCol)
|
boolean |
equals(Object anObj)
|
boolean |
equals(PhysicalStore<BigDecimal> aStore,
NumberContext aCntxt)
|
boolean |
equals(org.ojalgo.array.ReferenceTypeArray<N> anArray)
|
void |
exchangeRows(int aRowA,
int aRowB)
|
void |
exchangeSets(int aFirstA,
int aFirstB,
int aStep,
int aCount)
|
void |
fillAll(N aNmbr)
|
void |
fillOne(int anInd,
N aNmbr)
|
void |
fillSet(int[] someIndeces,
N aNmbr)
|
void |
fillSet(int aFirst,
int aLimit,
int aStep,
N aNmbr)
|
int |
getColDim()
|
BigDecimal |
getLargestElement()
|
int |
getMinDim()
|
N |
getNumber(int anInd)
|
BigDecimal |
getNumber(int aRow,
int aCol)
|
PhysicalFactory<BigDecimal> |
getPhysicalFactory()
|
int |
getRowDim()
|
int |
hashCode()
|
boolean |
isAbsolute(int aRow,
int aCol)
|
boolean |
isLowerLeftShaded()
The lower (left) triangle is shaded leaving an upper Hessenberg matrix. |
boolean |
isShaded()
Either the lower (left) or the upper (right) triangles are shaded. |
boolean |
isUpperRightShaded()
The upper (right) triangle is shaded leaving a lower Hessenberg matrix. |
boolean |
isZero(int aRow,
int aCol)
|
void |
modifyAll(BinaryFunction<N> aFunc,
N aNmbr)
|
void |
modifyAll(ParameterFunction<N> aFunc,
int aParam)
|
void |
modifyAll(UnaryFunction<N> aFunc)
|
void |
modifyOne(int anInd,
BinaryFunction<N> aFunc,
N aNmbr)
|
void |
modifyOne(int anInd,
ParameterFunction<N> aFunc,
int aParam)
|
void |
modifyOne(int anInd,
UnaryFunction<N> aFunc)
|
void |
modifySet(int[] someIndeces,
BinaryFunction<N> aFunc,
N aNmbr)
|
void |
modifySet(int[] someIndeces,
ParameterFunction<N> aFunc,
int aParam)
|
void |
modifySet(int[] someIndeces,
UnaryFunction<N> aFunc)
|
void |
modifySet(int aFirst,
int aLimit,
int aStep,
BinaryFunction<N> aFunc,
N aNmbr)
|
void |
modifySet(int aFirst,
int aLimit,
int aStep,
ParameterFunction<N> aFunc,
int aParam)
|
void |
modifySet(int aFirst,
int aLimit,
int aStep,
UnaryFunction<N> aFunc)
|
void |
multiply(BigDecimal aNmbr)
|
BigDecimal |
multiplyBothSides(MatrixStore<BigDecimal> aStore)
Calculates [aStore]T[this][aStore] as in a quadratic function [x]T[Q][x]. |
void |
multiplyElements(PhysicalStore<BigDecimal> aStore)
|
MatrixStore<BigDecimal> |
multiplyLeft(MatrixStore<BigDecimal> aStore)
|
void |
multiplyLeft(Rotation<BigDecimal> aRotation)
|
MatrixStore<BigDecimal> |
multiplyRight(MatrixStore<BigDecimal> aStore)
|
void |
multiplyRight(Rotation<BigDecimal> aRotation)
|
void |
negateAll()
|
void |
rotateLeft(int aLowerIndex,
int aHigherIndex,
BigDecimal anAngle)
As in MatrixStore.multiplyLeft(MatrixStore) where the
left/parameter matrix is a plane rotation. |
void |
rotateRight(int aLowerIndex,
int aHigherIndex,
BigDecimal anAngle)
As in MatrixStore.multiplyRight(MatrixStore) where the
right/parameter matrix is a plane rotation. |
int |
searchAscending(N aNmbr)
|
void |
set(int aRow,
int aCol,
BigDecimal aNmbr)
|
void |
set(int aRow,
int aCol,
double aNmbr)
|
void |
shadeLowerLeft()
Shades the lower (left) triangle, leaving an upper Hessenberg matrix. |
void |
shadeUpperRight()
Shades the upper (right) triangle, leaving a lower Hessenberg matrix. |
int |
size()
|
void |
sortAscending()
|
void |
substituteBackwards(MatrixStore<BigDecimal> aBody,
boolean assumeOne)
|
void |
substituteForwards(MatrixStore<BigDecimal> aBody,
boolean assumeOne)
|
void |
subtract(BigDecimal aNmbr)
|
void |
subtract(PhysicalStore<BigDecimal> aStore)
|
List<BigDecimal> |
toList()
|
PhysicalStore<BigDecimal> |
toPhysicalStore()
May (probably will) return the same instance with every call. |
double[][] |
toRawCopy()
|
Scalar<BigDecimal> |
toScalar(int aRow,
int aCol)
|
String |
toString()
|
Array1Dim<N> |
toUtility1Dim()
A utility facade that conveniently/consistently presents the BasicArray as a one-dimensional array. |
Array2Dim<N> |
toUtility2Dim()
A utility facade that conveniently/consistently presents the BasicArray as a two-dimensional array. |
ArrayAnyDim<N> |
toUtilityAnyDim()
A utility facade that conveniently/consistently presents the BasicArray as a multi-dimensional array. |
void |
unshade()
Unshades both the lower (left) and upper (right) triangles. |
void |
visitAll(AggregatorFunction<N> aVisitor)
|
void |
visitOne(int anInd,
AggregatorFunction<N> aVisitor)
|
void |
visitSet(int[] someIndeces,
AggregatorFunction<N> aVisitor)
|
void |
visitSet(int aFirst,
int aLimit,
int aStep,
AggregatorFunction<N> aVisitor)
|
| Methods inherited from class org.ojalgo.array.BigArray |
|---|
enforceAll, isAbsolute, isReal, isZero, toScalar |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.ojalgo.matrix.store.PhysicalStore |
|---|
enforceAll, fillAll, visitAll |
| Field Detail |
|---|
public static final PhysicalFactory<BigDecimal> FACTORY
public final int length
| Method Detail |
|---|
public void add(BigDecimal aNmbr)
add in interface PhysicalStore<BigDecimal>public void add(PhysicalStore<BigDecimal> aStore)
add in interface PhysicalStore<BigDecimal>
public void applyHouseholder(int aFirstTargetCol,
MatrixStore<BigDecimal> aHouseholderStore,
int aHouseholderCol,
Object aColumnArray)
aFirstTargetCol - The first column of "this" to be transformed.aHouseholderStore - The MatrixStore where the householder
column is stored.aHouseholderCol - the index of the householder column in aHouseholderStore.aColumnArray - An array (values not set) for internal/temporary
storage of the householder column. Should be of type N[] or double[].
public BigDecimal calculateColumnNorm(int aRow,
int aCol,
int aDegree)
calculateColumnNorm in interface PhysicalStore<BigDecimal>
public BigDecimal calculateRowNorm(int aRow,
int aCol,
int aDegree)
calculateRowNorm in interface PhysicalStore<BigDecimal>public BigDecimal calculateTrace()
calculateTrace in interface PhysicalStore<BigDecimal>public BigDecimal calculateVectorNorm(int aDegree)
calculateVectorNorm in interface PhysicalStore<BigDecimal>public BigDecimal calculateVectorProduct(PhysicalStore<BigDecimal> aStore)
calculateVectorProduct in interface PhysicalStore<BigDecimal>public boolean computeCholesky()
computeCholesky in interface CholeskyDecomposition.CholeskyStore<BigDecimal>public LUDecomposition.Pivot computeLU()
computeLU in interface LUDecomposition.LUStore<BigDecimal>public void computeQR()
computeQR in interface QRDecomposition.QRStore<BigDecimal>public BigDenseStore copy()
PhysicalStore
copy in interface PhysicalStore<BigDecimal>PhysicalStore copy.public BigDecimal countNonZeroElements()
countNonZeroElements in interface PhysicalStore<BigDecimal>public void divide(BigDecimal aNmbr)
divide in interface PhysicalStore<BigDecimal>public void divideElements(PhysicalStore<BigDecimal> aStore)
divideElements in interface PhysicalStore<BigDecimal>
public double doubleValue(int aRow,
int aCol)
doubleValue in interface MatrixStore<BigDecimal>
public boolean equals(PhysicalStore<BigDecimal> aStore,
NumberContext aCntxt)
equals in interface PhysicalStore<BigDecimal>
public void exchangeRows(int aRowA,
int aRowB)
exchangeRows in interface PhysicalStore<BigDecimal>public int getColDim()
getColDim in interface MatrixStore<BigDecimal>public BigDecimal getLargestElement()
getLargestElement in interface PhysicalStore<BigDecimal>public int getMinDim()
getMinDim in interface MatrixStore<BigDecimal>
public BigDecimal getNumber(int aRow,
int aCol)
getNumber in interface MatrixStore<BigDecimal>public PhysicalFactory<BigDecimal> getPhysicalFactory()
getPhysicalFactory in interface MatrixStore<BigDecimal>public int getRowDim()
getRowDim in interface MatrixStore<BigDecimal>
public boolean isAbsolute(int aRow,
int aCol)
isAbsolute in interface PhysicalStore<BigDecimal>public boolean isLowerLeftShaded()
MatrixStoreThe lower (left) triangle is shaded leaving an upper Hessenberg matrix.
isLowerLeftShaded in interface MatrixStore<BigDecimal>MatrixStore.isUpperRightShaded(),
MatrixStore.isShaded(),
PhysicalStore.shadeLowerLeft(),
PhysicalStore.unshade()public boolean isShaded()
MatrixStoreEither the lower (left) or the upper (right) triangles are shaded.
Shading part of a MatrixStore causes that
part to be ignored (as if it had zero valued elements) when doing matrix
multiplication. It is possible to shade part of a
PhysicalStore even though the shaded
elements are not actually zero valued. Calling doubleValue(i, j),
getNumber(i, j) or toScalar(i, j) will return the actual
stored value.
isShaded in interface MatrixStore<BigDecimal>MatrixStore.isLowerLeftShaded(),
MatrixStore.isUpperRightShaded(),
PhysicalStore.unshade()public boolean isUpperRightShaded()
MatrixStoreThe upper (right) triangle is shaded leaving a lower Hessenberg matrix.
isUpperRightShaded in interface MatrixStore<BigDecimal>MatrixStore.isLowerLeftShaded(),
MatrixStore.isShaded(),
PhysicalStore.shadeUpperRight(),
PhysicalStore.unshade()
public boolean isZero(int aRow,
int aCol)
isZero in interface PhysicalStore<BigDecimal>public void multiply(BigDecimal aNmbr)
multiply in interface PhysicalStore<BigDecimal>public BigDecimal multiplyBothSides(MatrixStore<BigDecimal> aStore)
MatrixStore
multiplyBothSides in interface MatrixStore<BigDecimal>public void multiplyElements(PhysicalStore<BigDecimal> aStore)
multiplyElements in interface PhysicalStore<BigDecimal>public MatrixStore<BigDecimal> multiplyLeft(MatrixStore<BigDecimal> aStore)
multiplyLeft in interface MatrixStore<BigDecimal>public void multiplyLeft(Rotation<BigDecimal> aRotation)
multiplyLeft in interface PhysicalStore<BigDecimal>public MatrixStore<BigDecimal> multiplyRight(MatrixStore<BigDecimal> aStore)
multiplyRight in interface MatrixStore<BigDecimal>public void multiplyRight(Rotation<BigDecimal> aRotation)
multiplyRight in interface PhysicalStore<BigDecimal>public void negateAll()
negateAll in interface PhysicalStore<BigDecimal>
public void rotateLeft(int aLowerIndex,
int aHigherIndex,
BigDecimal anAngle)
PhysicalStore
As in MatrixStore.multiplyLeft(MatrixStore) where the
left/parameter matrix is a plane rotation.
Multiplying by a plane rotation from the left means that [this] gets two of its rows updated to new combinations of those two (current) rows.
There are two ways to transpose/invert a rotation. Either you negate the angle or you interchange the two indeces that define the rotation plane.
rotateLeft in interface PhysicalStore<BigDecimal>PhysicalStore.rotateRight(int, int, Number)
public void rotateRight(int aLowerIndex,
int aHigherIndex,
BigDecimal anAngle)
PhysicalStore
As in MatrixStore.multiplyRight(MatrixStore) where the
right/parameter matrix is a plane rotation.
Multiplying by a plane rotation from the right means that [this] gets two of its columns updated to new combinations of those two (current) columns.
There result is undefined if the two input indeces are the same (in which case the rotation plane is undefined).
rotateRight in interface PhysicalStore<BigDecimal>PhysicalStore.rotateLeft(int, int, Number)
public void set(int aRow,
int aCol,
BigDecimal aNmbr)
set in interface PhysicalStore<BigDecimal>
public void set(int aRow,
int aCol,
double aNmbr)
set in interface PhysicalStore<BigDecimal>public void shadeLowerLeft()
PhysicalStoreShades the lower (left) triangle, leaving an upper Hessenberg matrix.
shadeLowerLeft in interface PhysicalStore<BigDecimal>PhysicalStore.unshade()public void shadeUpperRight()
PhysicalStoreShades the upper (right) triangle, leaving a lower Hessenberg matrix.
shadeUpperRight in interface PhysicalStore<BigDecimal>PhysicalStore.unshade()
public void substituteBackwards(MatrixStore<BigDecimal> aBody,
boolean assumeOne)
public void substituteForwards(MatrixStore<BigDecimal> aBody,
boolean assumeOne)
public void subtract(BigDecimal aNmbr)
subtract in interface PhysicalStore<BigDecimal>public void subtract(PhysicalStore<BigDecimal> aStore)
subtract in interface PhysicalStore<BigDecimal>public List<BigDecimal> toList()
toList in interface PhysicalStore<BigDecimal>public PhysicalStore<BigDecimal> toPhysicalStore()
MatrixStorePhysicalStore instances are mutable.
If you plan to modify it you should make a copy first. Depending on what
you do with the PhysicalStore you may
have to unshade it.
toPhysicalStore in interface MatrixStore<BigDecimal>PhysicalStore representation
of this MatrixStore.PhysicalStore.copy(),
PhysicalStore.unshade()public double[][] toRawCopy()
toRawCopy in interface PhysicalStore<BigDecimal>
public Scalar<BigDecimal> toScalar(int aRow,
int aCol)
toScalar in interface MatrixStore<BigDecimal>public void unshade()
PhysicalStore
unshade in interface PhysicalStore<BigDecimal>PhysicalStore.shadeLowerLeft(),
PhysicalStore.shadeUpperRight()public final double doubleValue(int anInd)
public final boolean equals(Object anObj)
equals in class Objectpublic final boolean equals(org.ojalgo.array.ReferenceTypeArray<N> anArray)
public final void exchangeSets(int aFirstA,
int aFirstB,
int aStep,
int aCount)
public final void fillAll(N aNmbr)
public final void fillOne(int anInd,
N aNmbr)
public final void fillSet(int aFirst,
int aLimit,
int aStep,
N aNmbr)
public final void fillSet(int[] someIndeces,
N aNmbr)
public final N getNumber(int anInd)
public final int hashCode()
hashCode in class Object
public final void modifyAll(BinaryFunction<N> aFunc,
N aNmbr)
public final void modifyAll(ParameterFunction<N> aFunc,
int aParam)
public final void modifyAll(UnaryFunction<N> aFunc)
public final void modifyOne(int anInd,
BinaryFunction<N> aFunc,
N aNmbr)
public final void modifyOne(int anInd,
ParameterFunction<N> aFunc,
int aParam)
public final void modifyOne(int anInd,
UnaryFunction<N> aFunc)
public final void modifySet(int aFirst,
int aLimit,
int aStep,
BinaryFunction<N> aFunc,
N aNmbr)
public final void modifySet(int aFirst,
int aLimit,
int aStep,
ParameterFunction<N> aFunc,
int aParam)
public final void modifySet(int aFirst,
int aLimit,
int aStep,
UnaryFunction<N> aFunc)
public final void modifySet(int[] someIndeces,
BinaryFunction<N> aFunc,
N aNmbr)
public final void modifySet(int[] someIndeces,
ParameterFunction<N> aFunc,
int aParam)
public final void modifySet(int[] someIndeces,
UnaryFunction<N> aFunc)
public final int searchAscending(N aNmbr)
BasicArray.searchAscending(java.lang.Number)public final void sortAscending()
Arrays.sort(Object[]),
searchAscending(Number)public final void visitAll(AggregatorFunction<N> aVisitor)
public final void visitOne(int anInd,
AggregatorFunction<N> aVisitor)
public final void visitSet(int aFirst,
int aLimit,
int aStep,
AggregatorFunction<N> aVisitor)
public final void visitSet(int[] someIndeces,
AggregatorFunction<N> aVisitor)
public final int size()
public final String toString()
toString in class Objectpublic final Array1Dim<N> toUtility1Dim()
A utility facade that conveniently/consistently presents the
BasicArray as a one-dimensional array.
Note that you will modify the actual array by accessing it
through this facade.
Disregards the array structure, and simply treats it as one-domensional.
public final Array2Dim<N> toUtility2Dim()
A utility facade that conveniently/consistently presents the
BasicArray as a two-dimensional array.
Note that you will modify the actual array by accessing it
through this facade.
If "this" has more than two dimensions then only the first plane of the first cube of the first... is used/accessed. If this only has one dimension then everything is assumed to be in the first column of the first plane of the first cube...
public final ArrayAnyDim<N> toUtilityAnyDim()
A utility facade that conveniently/consistently presents the
BasicArray as a multi-dimensional array.
Note that you will modify the actual array by accessing it
through this facade.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||