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

◆ dgbtrs()

void dgbtrs ( char  trans,
int  n,
int  kl,
int  ku,
int  nrhs,
int  ldab,
double  ab[],
int  ipiv[],
int  ldb,
double  b[],
int *  info 
)

Solution to LU factorized system of linear equations AX = B or ATX = B for a general band matrix

Purpose
This routine solves a system of linear equations
A * X = B or A^T * X = B
with a general band matrix A using the LU factorization computed by dgbtrf.
Parameters
[in]transSpecifies the form of the system of equations:
= 'N': A * X = B. (no transpose)
= 'T' or 'C': A^T * X = B. (transpose)
[in]nOrder of the matrix A. (n >= 0) (If n = 0, returns without computation)
[in]klNumber of sub-diagonals within the band of A. (kl >= 0)
[in]kuNumber of super-diagonals within the band of A. (ku >= 0)
[in]nrhsNumber of right hand sides, i.e., number of columns of the matrix B. (nrhs >= 0) (if nrhs = 0, returns without computation)
[in]ldabLeading dimension of the two dimensional array ab[][]. (ldab >= 2kl + ku + 1)
[in]ab[][]Array ab[lab][ldab] (lab >= n)
Details of the LU factorization of the band matrix A, as computed by dgbtrf. U is stored as an upper triangular band matrix with kl+ku super-diagonals in rows 1 to kl+ku+1, and the multipliers used during the factorization are stored in rows kl+ku+2 to 2*kl+ku+1.
[in]ipiv[]Array ipiv[lipiv] (lipiv >= n)
Pivot indices from dgbtrf; for 1 <= i <= n, row i of the matrix was interchanged with row ipiv[i-1].
[in]ldbLeading dimension of the two dimensional array b[][]. (ldb >= max(1, n))
[in,out]b[][]Array b[lb][ldb] (lb >= nrhs)
[in] Right hand side matrix B.
[out] Solution matrix X.
[out]info= 0: Successful exit
= -1: The argument trans had an illegal value (trans != 'N', 'T' nor 'C')
= -2: The argument n had an illegal value (n < 0)
= -3: The argument kl had an illegal value (kl < 0)
= -4: The argument ku had an illegal value (ku < 0)
= -5: The argument nrhs had an illegal value (nrhs < 0)
= -6: The argument ldab had an illegal value (ldab < 2kl+ku+1)
= -9: The argument ldb had an illegal value (ldb < max(1, n))
Reference
LAPACK