|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.mahout.math.PersistentObject
org.apache.mahout.math.matrix.linalg.Algebra
@Deprecated public final class Algebra
Field Summary | |
---|---|
static Algebra |
DEFAULT
Deprecated. A default Algebra object; has Property.DEFAULT attached for tolerance. |
Constructor Summary | |
---|---|
Algebra()
Deprecated. Constructs a new instance with an equality tolerance given by Property.DEFAULT.tolerance(). |
|
Algebra(double tolerance)
Deprecated. Constructs a new instance with the given equality tolerance. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Deprecated. Returns a copy of the receiver. |
static double |
det(DoubleMatrix2D A)
Deprecated. Returns the determinant of matrix A. |
static DoubleMatrix1D |
permute(DoubleMatrix1D A,
int[] indexes,
double[] work)
Deprecated. Modifies the given vector A such that it is permuted as specified; Useful for pivoting. |
static DoubleMatrix2D |
permute(DoubleMatrix2D A,
int[] rowIndexes,
int[] columnIndexes)
Deprecated. Constructs and returns a new row and column permuted selection view of matrix A; equivalent to DoubleMatrix2D.viewSelection(int[],int[]) . |
static DoubleMatrix2D |
permuteColumns(DoubleMatrix2D A,
int[] indexes,
int[] work)
Deprecated. Modifies the given matrix A such that it's columns are permuted as specified; Useful for pivoting. |
static DoubleMatrix2D |
permuteRows(DoubleMatrix2D A,
int[] indexes,
int[] work)
Deprecated. Modifies the given matrix A such that it's rows are permuted as specified; Useful for pivoting. |
Property |
property()
Deprecated. Returns the property object attached to this Algebra, defining tolerance. |
void |
setProperty(Property property)
Deprecated. Attaches the given property object to this Algebra, defining tolerance. |
static DoubleMatrix2D |
solve(DoubleMatrix2D A,
DoubleMatrix2D B)
Deprecated. Solves A*X = B. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Algebra DEFAULT
Property.DEFAULT
attached for tolerance. Allows ommiting to construct an
Algebra object time and again.
Note that this Algebra object is immutable. Any attempt to assign a new Property object to it (via method
setProperty), or to alter the tolerance of its property object (via property().setTolerance(...))
will throw an exception.
Constructor Detail |
---|
public Algebra()
public Algebra(double tolerance)
tolerance
- the tolerance to be used for equality operations.Method Detail |
---|
public java.lang.Object clone()
clone
in class org.apache.mahout.math.PersistentObject
public static double det(DoubleMatrix2D A)
public static DoubleMatrix1D permute(DoubleMatrix1D A, int[] indexes, double[] work)
Example:
Reordering [A,B,C,D,E] with indexes [0,4,2,3,1] yields [A,E,C,D,B] In other words A[0]<--A[0], A[1]<--A[4], A[2]<--A[2], A[3]<--A[3], A[4]<--A[1]. Reordering [A,B,C,D,E] with indexes [0,4,1,2,3] yields [A,E,B,C,D] In other words A[0]<--A[0], A[1]<--A[4], A[2]<--A[1], A[3]<--A[2], A[4]<--A[3].
A
- the vector to permute.indexes
- the permutation indexes, must satisfy indexes.length==A.size() && indexes[i] >= 0 && indexes[i]
< A.size();work
- the working storage, must satisfy work.length >= A.size(); set work==null if you
don't care about performance.
java.lang.IndexOutOfBoundsException
- if indexes.length != A.size().public static DoubleMatrix2D permute(DoubleMatrix2D A, int[] rowIndexes, int[] columnIndexes)
DoubleMatrix2D.viewSelection(int[],int[])
. The returned matrix is backed by this matrix, so changes in the
returned matrix are reflected in this matrix, and vice-versa. Use idioms like result = permute(...).copy()
to generate an independent sub matrix.
public static DoubleMatrix2D permuteColumns(DoubleMatrix2D A, int[] indexes, int[] work)
A
- the matrix to permute.indexes
- the permutation indexes, must satisfy indexes.length==A.columns() && indexes[i] >= 0 &&
indexes[i] < A.columns();work
- the working storage, must satisfy work.length >= A.columns(); set work==null if
you don't care about performance.
java.lang.IndexOutOfBoundsException
- if indexes.length != A.columns().public static DoubleMatrix2D permuteRows(DoubleMatrix2D A, int[] indexes, int[] work)
Example:
Reordering [A,B,C,D,E] with indexes [0,4,2,3,1] yields [A,E,C,D,B] In other words A[0]<--A[0], A[1]<--A[4], A[2]<--A[2], A[3]<--A[3], A[4]<--A[1]. Reordering [A,B,C,D,E] with indexes [0,4,1,2,3] yields [A,E,B,C,D] In other words A[0]<--A[0], A[1]<--A[4], A[2]<--A[1], A[3]<--A[2], A[4]<--A[3].
A
- the matrix to permute.indexes
- the permutation indexes, must satisfy indexes.length==A.rows() && indexes[i] >= 0 && indexes[i]
< A.rows();work
- the working storage, must satisfy work.length >= A.rows(); set work==null if you
don't care about performance.
java.lang.IndexOutOfBoundsException
- if indexes.length != A.rows().public Property property()
setProperty(Property)
public void setProperty(Property property)
property
- the Property object to be attached.
java.lang.UnsupportedOperationException
- if this==DEFAULT && property!=this.property() - The DEFAULT Algebra
object is immutable.
java.lang.UnsupportedOperationException
- if this==ZERO && property!=this.property() - The ZERO Algebra object
is immutable.property
public static DoubleMatrix2D solve(DoubleMatrix2D A, DoubleMatrix2D B)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |