|
◆ Zgbtrs()
Sub Zgbtrs |
( |
Trans As |
String, |
|
|
N As |
Long, |
|
|
Kl As |
Long, |
|
|
Ku As |
Long, |
|
|
Ab() As |
Complex, |
|
|
IPiv() As |
Long, |
|
|
B() As |
Complex, |
|
|
Info As |
Long, |
|
|
Optional Nrhs As |
Long = 1 |
|
) |
| |
Solution to LU factorized system of linear equations AX = B, ATX = B or AHX = B for a complex band matrix
- Purpose
- This routine solves a system of linear equations
A * X = B, A^T * X = B or A^H * X = B
with a complex band matrix A using the LU factorization computed by Zgbtrf.
- Parameters
-
[in] | Trans | Specifies the form of the system of equations:
= "N": A * X = B. (no transpose)
= "T": A^T * X = B. (transpose)
= "C": A^H * X = B. (conjugate transpose) |
[in] | N | Number of linear equations, i.e., order of the matrix A. (N >= 0) (If N = 0, returns without computation) |
[in] | Kl | Number of subdiagonals within the band of A (Kl >= 0) |
[in] | Ku | Number of superdiagonals within the band of A (Ku >= 0) |
[in] | Ab() | Array Ab(LAb1 - 1, LAb2 - 1) (LAb1 >= 2*Kl+Ku+1, LAb2 >= N)
Details of the LU factorization of the band matrix A, as computed by Zgbtrf. U is stored as an upper triangular band matrix with Kl+Ku superdiagonals 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 - 1) (LIPiv >= N)
Pivot indices from Zgbtrf; for 1 <= i <= n, row i of the matrix was interchanged with row IPiv(i-1). |
[in,out] | B() | Array B(LB1 - 1, LB2 - 1) (LB1 >= max(1, N), LB2 >= Nrhs) (2D array) or B(LB - 1) (LB >= max(1, N), Nrhs = 1) (1D array)
[in] N x Nrhs matrix of right hand side matrix B.
[out] If Info = 0, the N x Nrhs 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 Ab() is invalid.
= -6: The argument IPiv() is invalid.
= -7: The argument B() is invalid.
= -9: The argument Nrhs had an illegal value. (Nrhs < 0) |
[in] | Nrhs | (Optional)
Number of right hand sides, i.e., number of columns of the matrix B. (Nrhs >= 0) (If Nrhs = 0, returns without computation) (default = 1) |
- Reference
- LAPACK
- Example Program
- See example of Zgbtrf.
|