|
JMSLTM Numerical Library 4.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.imsl.math.Cholesky
Cholesky factorization of a matrix of type double.
Class Cholesky is based on the LINPACK routine SCHDC;
see Dongarra et al. (1979).
Before the decomposition is computed, initial elements are moved to the leading part of
A and final elements to the trailing part of A.
During the decomposition only rows and columns corresponding to the free elements are moved.
The result of the decomposition is an upper triangular matrix R and a
permutation matrix P that satisfy
,
where P is represented by ipvt.
The method update is based on the LINPACK routine SCHUD;
see Dongarra et al. (1979).
The Cholesky factorization of a matrix is
,
where R is an upper triangular matrix. Given this factorization,
downdate computes the factorization
![]()
downdate determines an orthogonal matrix U as the product
of Givens rotations, such that
![]()
By multiplying this equation by its transpose and noting that
,
the desired result
![]()
Let a be the solution of the linear system
and let
![]()
The Givens rotations,
, are chosen such that
![]()
The
, are (N + 1) * (N + 1) matrices of the form
![G_i =
left[ {begin{array}{*{20}c}{
I_{i - 1} } & 0 & 0 & 0 \
0 & {c_i } & 0 & { - s_i } \
0 & 0 & {I_{N - i} } & 0 \
0 & {s_i } & 0 & {c_i } \
end{array}} right]](eqn_1003.png)
The Givens rotations are then used to form
![]()
The matrix
![]()
![]()
![]()
| Nested Class Summary | |
static class |
Cholesky.NotSPDException
The matrix is not symmetric, positive definite. |
| Constructor Summary | |
Cholesky(double[][] a)
Create the Cholesky factorization of a symmetric positive definite matrix of type double. |
|
| Method Summary | |
void |
downdate(double[] x)
Downdates the factorization by subtracting a rank-1 matrix. |
double[][] |
getR()
Returns the R matrix that results from the Cholesky factorization. |
double[][] |
inverse()
Returns the inverse of this matrix |
double[] |
solve(double[] b)
Solve Ax = b where A is a positive definite matrix with elements of type double. |
void |
update(double[] x)
Updates the factorization by adding a rank-1 matrix. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Cholesky(double[][] a)
throws SingularMatrixException,
Cholesky.NotSPDException
double.
a - a double square matrix to be factored
IllegalArgumentException - Thrown when the row lengths of matrix a are not equal
(for example, the matrix edges are "jagged".)
SingularMatrixException - Thrown when the input matrix a is singular.
Cholesky.NotSPDException - Thrown when the input matrix is not symmetric, positive definite.| Method Detail |
public void downdate(double[] x)
throws Cholesky.NotSPDException
x - A double array which specifies the rank-1 matrix.
x is not modified by this function.
Cholesky.NotSPDException - if public double[][] getR()
double matrix which contains the R matrix
that results from the Cholesky factorizationpublic double[][] inverse()
double matrix containing the inversepublic double[] solve(double[] b)
double.
b - a double array containing the right-hand side of the linear
system
double array containing the solution to the system of
linear equationspublic void update(double[] x)
x - A double array which specifies the rank-1 matrix.
x is not modified by this function.
|
JMSLTM Numerical Library 4.0 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||