private static class FieldLUDecompositionImpl.Solver<T extends FieldElement<T>> extends java.lang.Object implements FieldDecompositionSolver<T>
| Modifier and Type | Field and Description |
|---|---|
private Field<T> |
field
Field to which the elements belong.
|
private T[][] |
lu
Entries of LU decomposition.
|
private int[] |
pivot
Pivot permutation associated with LU decomposition.
|
private static long |
serialVersionUID
Serializable version identifier.
|
private boolean |
singular
Singularity indicator.
|
| Modifier | Constructor and Description |
|---|---|
private |
FieldLUDecompositionImpl.Solver(Field<T> field,
T[][] lu,
int[] pivot,
boolean singular)
Build a solver from decomposed matrix.
|
| Modifier and Type | Method and Description |
|---|---|
FieldMatrix<T> |
getInverse()
Get the inverse (or pseudo-inverse) of the decomposed matrix.
|
boolean |
isNonSingular()
Check if the decomposed matrix is non-singular.
|
ArrayFieldVector<T> |
solve(ArrayFieldVector<T> b)
Solve the linear equation A × X = B.
|
FieldMatrix<T> |
solve(FieldMatrix<T> b)
Solve the linear equation A × X = B for matrices A.
|
FieldVector<T> |
solve(FieldVector<T> b)
Solve the linear equation A × X = B for matrices A.
|
T[] |
solve(T[] b)
Solve the linear equation A × X = B for matrices A.
|
private static final long serialVersionUID
private final Field<T extends FieldElement<T>> field
private final T extends FieldElement<T>[][] lu
private final int[] pivot
private final boolean singular
private FieldLUDecompositionImpl.Solver(Field<T> field, T[][] lu, int[] pivot, boolean singular)
field - field to which the matrix elements belonglu - entries of LU decompositionpivot - pivot permutation associated with LU decompositionsingular - singularity indicatorpublic boolean isNonSingular()
isNonSingular in interface FieldDecompositionSolver<T extends FieldElement<T>>public T[] solve(T[] b) throws java.lang.IllegalArgumentException, InvalidMatrixException
The A matrix is implicit, it is provided by the underlying decomposition algorithm.
solve in interface FieldDecompositionSolver<T extends FieldElement<T>>b - right-hand side of the equation A × X = Bjava.lang.IllegalArgumentException - if matrices dimensions don't matchInvalidMatrixException - if decomposed matrix is singularpublic FieldVector<T> solve(FieldVector<T> b) throws java.lang.IllegalArgumentException, InvalidMatrixException
The A matrix is implicit, it is provided by the underlying decomposition algorithm.
solve in interface FieldDecompositionSolver<T extends FieldElement<T>>b - right-hand side of the equation A × X = Bjava.lang.IllegalArgumentException - if matrices dimensions don't matchInvalidMatrixException - if decomposed matrix is singularpublic ArrayFieldVector<T> solve(ArrayFieldVector<T> b) throws java.lang.IllegalArgumentException, InvalidMatrixException
The A matrix is implicit here. It is
b - right-hand side of the equation A × X = Bjava.lang.IllegalArgumentException - if matrices dimensions don't matchInvalidMatrixException - if decomposed matrix is singularpublic FieldMatrix<T> solve(FieldMatrix<T> b) throws java.lang.IllegalArgumentException, InvalidMatrixException
The A matrix is implicit, it is provided by the underlying decomposition algorithm.
solve in interface FieldDecompositionSolver<T extends FieldElement<T>>b - right-hand side of the equation A × X = Bjava.lang.IllegalArgumentException - if matrices dimensions don't matchInvalidMatrixException - if decomposed matrix is singularpublic FieldMatrix<T> getInverse() throws InvalidMatrixException
getInverse in interface FieldDecompositionSolver<T extends FieldElement<T>>InvalidMatrixException - if decomposed matrix is singularCopyright (c) 2003-2013 Apache Software Foundation