XLPack 7.0
XLPack Numerical Library (C API) Reference Manual
Loading...
Searching...
No Matches

◆ zptsv()

void zptsv ( int  n,
int  nrhs,
double  d[],
doublecomplex  e[],
int  ldb,
doublecomplex  b[],
int *  info 
)

(Simple driver) Solution to system of linear equations AX = B for a Hermitian positive definite tridiagonal matrix

Purpose
This routine computes the solution to a complex system of linear equations
A * X = B,
where A is an n x n Hermitian positive definite tridiagonal matrix, and X and B are n x nrhs matrices.

A is factored as A = L*D*L^H, and the factored form of A is then used to solve the system of equations.
Parameters
[in]nOrder of the matrix A. (n >= 0) (If n = 0, returns without computation)
[in]nrhsNumber of right hand sides, i.e., number of columns of the matrix B. (nrhs >= 0) (If nrhs = 0, returns without computation)
[in,out]d[]Array d[ld] (ld >= n)
[in] n diagonal elements of the Hermitian positive definite tridiagonal matrix A
[out] n diagonal elements of the diagonal matrix D from the factorization A = L*D*L^H
[in,out]e[]Array e[le] (le >= n - 1)
[in] n-1 sub-diagonal elements of the Hermitian positive definite tridiagonal matrix A.
[out] n-1 sub-diagonal elements of the unit bidiagonal factor L from the L*D*L^H factorization of A. E can also be regarded as the super-diagonal of the unit bidiagonal factor U from the U^H*D*U factorization of A.
[in]ldbLeading dimension of the two dimensional array b[][]. (ldb >= max(1, n))
[in,out]b[][]Array b[lb][ldb] (lb >= nrhs)
[in] n x nrhs right hand side matrix B.
[out] If info = 0, n x nrhs solution matrix X.
[out]info= 0: Successful exit
= -1: The argument n had an illegal value (n < 0)
= -2: The argument nrhs had an illegal value (nrhs < 0)
= -5: The argument ldb had an illegal value (ldb < max(1, n))
= i > 0: The leading minor of order i is not positive definite, and the solution has not been computed. The factorization has not been completed unless i = n.
Reference
LAPACK