Linear solvers¶
HPD solve¶
Solves either \(AX=B\) or \(A^T X=B\) for \(X\) given Hermitian positivedefinite (HPD) \(A\) and righthand side matrix \(B\). The solution is computed by first finding the Cholesky factorization of \(A\) and then performing two successive triangular solves against \(B\).

void
HPDSolve
(UpperOrLower uplo, Orientation orientation, Matrix<F> &A, Matrix<F> &B)¶

void
HPDSolve
(UpperOrLower uplo, Orientation orientation, DistMatrix<F> &A, DistMatrix<F> &B)¶ Overwrite B with the solution to \(AX=B\) or \(A^T X=B\), where A is Hermitian positivedefinite and only the triangle of A specified by uplo is accessed.
Gaussian elimination¶
Solves \(AX=B\) for \(X\) given a general square nonsingular matrix \(A\) and righthand side matrix \(B\). The solution is computed through (partially pivoted) Gaussian elimination.

void
GaussianElimination
(Matrix<F> &A, Matrix<F> &B)¶

void
GaussianElimination
(DistMatrix<F> &A, DistMatrix<F> &B)¶ Upon completion, \(A\) will have been overwritten with Gaussian elimination and \(B\) will be overwritten with \(X\).
Leastsquares¶
Solves \(AX=B\) or \(A^H X = B\) for \(X\) in a leastsquares sense given a general fullrank matrix \(A \in \mathbb{F}^{m \times n}\). If \(m \ge n\), then the first step is to form the QR factorization of \(A\), otherwise the LQ factorization is computed.
 If solving \(AX=B\), then either \(X=R^{1} Q^H B\) or \(X=Q^H L^{1} B\).
 If solving \(A^H X=B\), then either \(X=Q R^{H} B\) or \(X=L^{H} Q B\).

void
LeastSquares
(Orientation orientation, Matrix<F> &A, const Matrix<F> &B, Matrix<F> &X)¶

void
LeastSquares
(Orientation orientation, DistMatrix<F> &A, const DistMatrix<F> &B, DistMatrix<F> &X)¶ If orientation is set to
NORMAL
, then solve \(AX=B\), otherwise orientation must be equal toADJOINT
and \(A^H X=B\) will be solved. Upon completion, \(A\) is overwritten with its QR or LQ factorization, and \(X\) is overwritten with the solution.
Solve after Cholesky¶
Uses an existing inplace Cholesky factorization to solve against one or more righthand sides.

void
cholesky::
SolveAfter
(UpperOrLower uplo, Orientation orientation, const Matrix<F> &A, Matrix<F> &B)¶

void
cholesky::
SolveAfter
(UpperOrLower uplo, Orientation orientation, const DistMatrix<F> &A, DistMatrix<F> &B)¶ Update \(B := A^{1} B\), \(B := A^{T} B\), or \(B := A^{H} B\), where one triangle of \(A\) has been overwritten with its Cholesky factor.
Solve after LU¶
Uses an existing inplace LU factorization (with or without partial pivoting) to solve against one or more righthand sides.

void
lu::
SolveAfter
(Orientation orientation, const Matrix<F> &A, Matrix<F> &B)¶

void
lu::
SolveAfter
(Orientation orientation, const DistMatrix<F> &A, DistMatrix<F> &B)¶ Update \(B := A^{1} B\), \(B := A^{T} B\), or \(B := A^{H} B\), where \(A\) has been overwritten with its LU factors (without partial pivoting).

void
lu::
SolveAfter
(Orientation orientation, const Matrix<F> &A, const Matrix<int> &p, Matrix<F> &B)¶

void
lu::
SolveAfter
(Orientation orientation, const DistMatrix<F> &A, const DistMatrix<int, VC, STAR> &p, DistMatrix<F> &B)¶ Update \(B := A^{1} B\), \(B := A^{T} B\), or \(B := A^{H} B\), where \(A\) has been overwritten with its LU factors with partial pivoting, which satisfy \(P A = L U\), where the permutation matrix \(P\) is represented by the pivot vector
p
.

void
lu::
SolveAfter
(Orientation orientation, const Matrix<F> &A, const Matrix<int> &p, const Matrix<int> &q, Matrix<F> &B)¶

void
lu::
SolveAfter
(Orientation orientation, const DistMatrix<F> &A, const DistMatrix<int, VC, STAR> &p, const DistMatrix<int, VC, STAR> &q, DistMatrix<F> &B)¶ Update \(B := A^{1} B\), \(B := A^{T} B\), or \(B := A^{H} B\), where \(A\) has been overwritten with its LU factors with full pivoting, which satisfy \(P A Q = L U\), where the permutation matrices \(P\) and \(Q\) are represented by the pivot vector
p
andq
, respectively.