Public Member Functions | List of all members
SurgSim::Math::LinearSolveAndInverse Class Referenceabstract

LinearSolveAndInverse aims at performing an efficient linear system resolution and calculating its inverse matrix at the same time. More...

#include <SurgSim/Math/LinearSolveAndInverse.h>

Inheritance diagram for SurgSim::Math::LinearSolveAndInverse:
SurgSim::Math::LinearSolveAndInverseDenseMatrix SurgSim::Math::LinearSolveAndInverseDiagonalMatrix SurgSim::Math::LinearSolveAndInverseTriDiagonalBlockMatrix< BlockSize > SurgSim::Math::LinearSolveAndInverseSymmetricTriDiagonalBlockMatrix< BlockSize >

Public Member Functions

virtual ~LinearSolveAndInverse ()
 
virtual void setMatrix (const Matrix &matrix)=0
 Set the linear solver matrix. More...
 
virtual Vector solve (const Vector &b)=0
 Solve the linear system (matrix.x=b) using the matrix provided by the latest setMatrix call. More...
 
virtual Matrix getInverse ()=0
 

Detailed Description

LinearSolveAndInverse aims at performing an efficient linear system resolution and calculating its inverse matrix at the same time.

This class is very useful in the OdeSolver resolution to improve performance.

See also
SurgSim::Math::OdeSolver

Constructor & Destructor Documentation

◆ ~LinearSolveAndInverse()

virtual SurgSim::Math::LinearSolveAndInverse::~LinearSolveAndInverse ( )
inlinevirtual

Member Function Documentation

◆ getInverse()

virtual Matrix SurgSim::Math::LinearSolveAndInverse::getInverse ( )
pure virtual
Returns
The linear system's inverse matrix, i.e. the inverse of the matrix provided on the last setMatrix call

Implemented in SurgSim::Math::LinearSolveAndInverseTriDiagonalBlockMatrix< BlockSize >, SurgSim::Math::LinearSolveAndInverseDiagonalMatrix, and SurgSim::Math::LinearSolveAndInverseDenseMatrix.

◆ setMatrix()

virtual void SurgSim::Math::LinearSolveAndInverse::setMatrix ( const Matrix matrix)
pure virtual

◆ solve()

virtual Vector SurgSim::Math::LinearSolveAndInverse::solve ( const Vector b)
pure virtual

Solve the linear system (matrix.x=b) using the matrix provided by the latest setMatrix call.

Parameters
bThe rhs vector
Returns
The solution vector

Implemented in SurgSim::Math::LinearSolveAndInverseTriDiagonalBlockMatrix< BlockSize >, SurgSim::Math::LinearSolveAndInverseDiagonalMatrix, and SurgSim::Math::LinearSolveAndInverseDenseMatrix.


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