Solves the linear system AX = B.

Namespace:  CenterSpace.NMath.Matrix
Assembly:  NMath (in NMath.dll) Version: 5.1.0.0

Syntax

C#
public static FloatMatrix Solve(
	FloatTriDiagMatrix A,
	FloatMatrix B,
	bool isSymmetricPD
)
Visual Basic (Declaration)
Public Shared Function Solve ( _
	A As FloatTriDiagMatrix, _
	B As FloatMatrix, _
	isSymmetricPD As Boolean _
) As FloatMatrix
Visual C++
public:
static FloatMatrix^ Solve(
	FloatTriDiagMatrix^ A, 
	FloatMatrix^ B, 
	bool isSymmetricPD
)

Parameters

A
Type: CenterSpace.NMath.Matrix..::.FloatTriDiagMatrix
A tridiagonal matrix.
B
Type: CenterSpace.NMath.Core..::.FloatMatrix
The matrix of right hand sides. B must have the same number of rows as A.
isSymmetricPD
Type: System..::.Boolean
true if A is symmetric and positive definite.

Return Value

A matrix with the same number of columns as B containing the solutions.

Remarks

The ith column of X, X(i), is the solution to the equation AX(i) = B(i), where B(i) is the ith column of B.

Exceptions

ExceptionCondition
CenterSpace.NMath.Core..::.SingularMatrixExceptionThrown if A is singular.
CenterSpace.NMath.Core..::.MismatchedSizeExceptionThrown if the number of rows in B is different than the number of rows in A.

See Also