|
SuanShu, a Java numerical and statistical library | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.numericalmethod.suanshu.matrix.doubles.matrixtype.mathoperation.SimpleMatrixMathOperation
public class SimpleMatrixMathOperation
This class is one implementation of MatrixMathOperation.
It exists only for the purpose of code reuse by subclasses.
Since these functions work with all Matrix implementations, they are bound to have suboptimal performance.
Subclasses can override them by taking advantage of having access to the internal members to increase performance.
| Constructor Summary | |
|---|---|
SimpleMatrixMathOperation()
|
|
| Method Summary | |
|---|---|
Matrix |
add(Matrix A1,
Matrix A2)
A1 + A2. |
Matrix |
minus(Matrix A1,
Matrix A2)
A1 - A2. |
Matrix |
multiply(Matrix A1,
Matrix A2)
A1 %*% A2. |
Vector |
multiply(Matrix A,
Vector v)
A %*% v |
Matrix |
scaled(Matrix A,
double scalar)
s * A |
Matrix |
transpose(Matrix A)
t(A) |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleMatrixMathOperation()
| Method Detail |
|---|
public Matrix add(Matrix A1,
Matrix A2)
A1 + A2.
add in interface MatrixMathOperationA1 - the first matrixA2 - the second matrix
A1 and A2
public Matrix minus(Matrix A1,
Matrix A2)
A1 - A2.
minus in interface MatrixMathOperationA1 - the first matrixA2 - the second matrix
A1 and A2
public Matrix multiply(Matrix A1,
Matrix A2)
A1 %*% A2.
multiply in interface MatrixMathOperationA1 - the first matrixA2 - the second matrix
A1 and A2
public Vector multiply(Matrix A,
Vector v)
MatrixMathOperationA %*% v
multiply in interface MatrixMathOperationA - a matrixv - a vector
A and v
public Matrix scaled(Matrix A,
double scalar)
MatrixMathOperations * A
scaled in interface MatrixMathOperationA - a matrixscalar - a scalar
A scaled by spublic Matrix transpose(Matrix A)
MatrixMathOperationt(A)
transpose in interface MatrixMathOperationA - a matrix
A
|
SuanShu, a Java numerical and statistical library | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||