List of all members | Public Member Functions | Private Attributes | Friends
FdEnergyDepositFinderKG::LowerTriangularMatrix Class Reference

#include <LinearAlgebra.h>

Public Member Functions

void Clear ()
 Free the matrix (requiring another SetSize(n) call for reuse) More...
 
LowerTriangularMatrix GetInverse () const
 Get the inverse of the matrix. More...
 
unsigned int GetSize () const
 
 LowerTriangularMatrix (const int n)
 (n*n) lower triangular matrix More...
 
 LowerTriangularMatrix (const int n, const double x)
 (n*n) lower triangular matrix, elements intialized to x More...
 
 LowerTriangularMatrix ()
 Empty matrix (needs SetSize() later) More...
 
const double & operator() (const int row, const int col) const
 Read-only access to a matrix element. More...
 
double & operator() (const int row, const int col)
 Read/write access to a matrix element. More...
 
ColumnVector operator* (const ColumnVector &rhs) const
 
LowerTriangularMatrix operator+ (const LowerTriangularMatrix &rhs) const
 
LowerTriangularMatrix operator+ (const DiagonalMatrix &rhs) const
 
void Print () const
 Dump ASCII representation to STDOUT (for debugging) More...
 
void SetSize (const int n)
 
void Zero ()
 Set all elements to 0. More...
 

Private Attributes

std::vector< double > fElements
 

Friends

class DiagonalMatrix
 

Detailed Description

Definition at line 60 of file LinearAlgebra.h.

Constructor & Destructor Documentation

FdEnergyDepositFinderKG::LowerTriangularMatrix::LowerTriangularMatrix ( const int  n)
inline

(n*n) lower triangular matrix

Definition at line 63 of file LinearAlgebra.h.

FdEnergyDepositFinderKG::LowerTriangularMatrix::LowerTriangularMatrix ( const int  n,
const double  x 
)
inline

(n*n) lower triangular matrix, elements intialized to x

Definition at line 66 of file LinearAlgebra.h.

FdEnergyDepositFinderKG::LowerTriangularMatrix::LowerTriangularMatrix ( )
inline

Empty matrix (needs SetSize() later)

Definition at line 70 of file LinearAlgebra.h.

Member Function Documentation

void FdEnergyDepositFinderKG::LowerTriangularMatrix::Clear ( )
inline

Free the matrix (requiring another SetSize(n) call for reuse)

Definition at line 81 of file LinearAlgebra.h.

References fElements.

LowerTriangularMatrix FdEnergyDepositFinderKG::LowerTriangularMatrix::GetInverse ( ) const

Get the inverse of the matrix.

Definition at line 78 of file LinearAlgebra.cc.

References diag(), and GetSize().

unsigned int FdEnergyDepositFinderKG::LowerTriangularMatrix::GetSize ( ) const
const double& FdEnergyDepositFinderKG::LowerTriangularMatrix::operator() ( const int  row,
const int  col 
) const
inline

Read-only access to a matrix element.

Definition at line 74 of file LinearAlgebra.h.

References fElements.

double& FdEnergyDepositFinderKG::LowerTriangularMatrix::operator() ( const int  row,
const int  col 
)
inline

Read/write access to a matrix element.

Definition at line 77 of file LinearAlgebra.h.

References fElements.

ColumnVector FdEnergyDepositFinderKG::LowerTriangularMatrix::operator* ( const ColumnVector rhs) const
LowerTriangularMatrix FdEnergyDepositFinderKG::LowerTriangularMatrix::operator+ ( const LowerTriangularMatrix rhs) const

Definition at line 58 of file LinearAlgebra.cc.

References fElements, and GetSize().

LowerTriangularMatrix FdEnergyDepositFinderKG::LowerTriangularMatrix::operator+ ( const DiagonalMatrix rhs) const
void FdEnergyDepositFinderKG::LowerTriangularMatrix::Print ( ) const

Dump ASCII representation to STDOUT (for debugging)

Definition at line 119 of file LinearAlgebra.cc.

References GetSize().

void FdEnergyDepositFinderKG::LowerTriangularMatrix::SetSize ( const int  n)
inline

Set the size of the matrix (the n in n*n). Does NOT initialize elements to 0.

Definition at line 87 of file LinearAlgebra.h.

References fElements.

void FdEnergyDepositFinderKG::LowerTriangularMatrix::Zero ( )

Set all elements to 0.

Definition at line 15 of file LinearAlgebra.cc.

References fElements.

Friends And Related Function Documentation

friend class DiagonalMatrix
friend

Definition at line 103 of file LinearAlgebra.h.

Member Data Documentation

std::vector<double> FdEnergyDepositFinderKG::LowerTriangularMatrix::fElements
private

Definition at line 101 of file LinearAlgebra.h.

Referenced by Clear(), GetSize(), operator()(), operator*(), operator+(), SetSize(), and Zero().


The documentation for this class was generated from the following files:

, generated on Tue Sep 26 2023.