gslmm::cholesky_decomposition< double > Struct Template Reference
[Cholesky decomposition]

#include <cholesky_decomposition_double.hh>

Inheritance diagram for gslmm::cholesky_decomposition< double >:

Inheritance graph
[legend]
Collaboration diagram for gslmm::cholesky_decomposition< double >:

Collaboration graph
[legend]
List of all members.

Detailed Description

template<>
struct gslmm::cholesky_decomposition< double >

class template specialisation for Cholesky decompositions of matricies of type double .

A symmetric, positive definite square matrix A has a Cholesky decomposition into a product of a lower triangular matrix $ L$ and its transpose $ L^T$,

\[ A = L L^T \]

This is sometimes referred to as taking the square-root of a matrix. The Cholesky decomposition can only be carried out when all the eigenvalues of the matrix are positive. This decomposition can be used to convert the linear system $ A x = b$ into a pair of triangular systems ($ L y = b$, $ L^T x = y$), which can be solved by forward and back-substitution.

Todo:
Implement gsl_linalg_cholesky_decomp_unit


Public Types

typedef vector< double > vector_type
typedef matrix< double > matrix_type
typedef matrix_type::value_type value_type
typedef matrix_type::element_type element_type

Public Member Functions

 cholesky_decomposition (const matrix_type &m, bool unit=false)
virtual ~cholesky_decomposition ()
bool solve (const vector_type &b, vector_type &x) const
bool solve (vector_type &x) const
const vector_typed () const
const matrix_typel () const
const matrix_typelt () const
const matrix_typellt () const

Protected Member Functions

void unpack () const

Private Types

typedef matrix_type::data_type data_type

Private Attributes

matrix_type_l
matrix_type_lt
vector_type _d


Member Typedef Documentation

typedef matrix_type::data_type gslmm::cholesky_decomposition< double >::data_type [private]
 

The low level matrix type.

Reimplemented from gslmm::matrix< double >.

typedef matrix_type::element_type gslmm::cholesky_decomposition< double >::element_type
 

The element type.

Reimplemented from gslmm::matrix< double >.

typedef matrix<double > gslmm::cholesky_decomposition< double >::matrix_type
 

The matrix type.

typedef matrix_type::value_type gslmm::cholesky_decomposition< double >::value_type
 

The element type.

Reimplemented from gslmm::matrix< double >.

typedef vector<double > gslmm::cholesky_decomposition< double >::vector_type
 

The vector type.

Reimplemented from gslmm::matrix< double >.


Constructor & Destructor Documentation

gslmm::cholesky_decomposition< double >::cholesky_decomposition const matrix_type m,
bool  unit = false
[inline]
 

Create an Cholesky decomposition of the input matrix m.

virtual gslmm::cholesky_decomposition< double >::~cholesky_decomposition  )  [inline, virtual]
 

Destructor.


Member Function Documentation

const vector_type& gslmm::cholesky_decomposition< double >::d  )  const [inline]
 

Returns:
The scale diagonal of the decomposition

const matrix_type& gslmm::cholesky_decomposition< double >::l  )  const [inline]
 

Returns:
The matrix $ L$ of the $ LL^T$ decomposition of $ A$

const matrix_type& gslmm::cholesky_decomposition< double >::llt  )  const [inline]
 

Returns:
The matrix $ LL^T$ of the Cholesky decomposition of $ A$

const matrix_type& gslmm::cholesky_decomposition< double >::lt  )  const [inline]
 

Returns:
The matrix $ L^T$ of the $ LL^T$ decomposition of $ A$

bool gslmm::cholesky_decomposition< double >::solve vector_type x  )  const [inline]
 

This member function solve the system $ A x = b$ using the Cholesky decomposition of $ A$.

Parameters:
x On input, the vector $ b$, and on output the vector $ x$

bool gslmm::cholesky_decomposition< double >::solve const vector_type b,
vector_type x
const [inline]
 

This member function solve the system $ A x = b$ using the Cholesky decomposition of $ A$.

Parameters:
b The vector $ b$
x The vector $ x$
Returns:
true on success

void gslmm::cholesky_decomposition< double >::unpack  )  const [inline, protected]
 

Unpack $ LL^T$ into $ L$ and $ L^T$.


Member Data Documentation

vector_type gslmm::cholesky_decomposition< double >::_d [private]
 

Diagonal.

matrix_type* gslmm::cholesky_decomposition< double >::_l [mutable, private]
 

The Q of the QR decomposition of the input matrix.

matrix_type* gslmm::cholesky_decomposition< double >::_lt [mutable, private]
 

The R of the QR decomposition of the input matrix.


The documentation for this struct was generated from the following file:
Top of page Last update Tue May 9 10:11:31 2006
Christian Holm
Created by DoxyGen 1.4.6