Developer Reference for Intel® oneAPI Math Kernel Library for Fortran
p?gbtrs
Solves a system of distributed linear equations with a general band matrix, using the LU factorization computed by p?gbtrf .
Syntax
call psgbtrs ( trans , n , bwl , bwu , nrhs , a , ja , desca , ipiv , b , ib , descb , af , laf , work , lwork , info )
call pdgbtrs ( trans , n , bwl , bwu , nrhs , a , ja , desca , ipiv , b , ib , descb , af , laf , work , lwork , info )
call pcgbtrs ( trans , n , bwl , bwu , nrhs , a , ja , desca , ipiv , b , ib , descb , af , laf , work , lwork , info )
call pzgbtrs ( trans , n , bwl , bwu , nrhs , a , ja , desca , ipiv , b , ib , descb , af , laf , work , lwork , info )
Include Files
mkl_scalapack.h
Description
psgbtrs pdgbtrs pcgbtrs pzgbtrs The p?gbtrs routine function solves a system of distributed linear equations with a general band distributed matrix sub( A ) = A (1: n , ja : ja + n -1) using the LU factorization computed by p?gbtrf.
The system has one of the following forms specified by trans :
sub( A )* X = sub( B ) (no transpose),
sub( A ) :code:`T` *X = sub( B ) (transpose),
sub( A ) :code:`H` * X = sub( B ) (conjugate transpose),
where sub( B ) = B ( ib : ib + n -1, 1: nrhs ).
Before calling this routine function ,you must call p?gbtrf (Computes the LU factorization of a general n-by-n banded distributed matrix.) to compute the LU factorization of sub( A ).
Input Parameters
trans
(global) CHARACTER*1 . Must be ‘N’ or ‘T’ or ‘C’ .
Indicates the form of the equations: If trans = 'N' , then sub( A )* X = sub( B ) is solved for X . If trans = 'T' , then sub( A ) :code:`T` * X = sub( B ) is solved for X . If trans = 'C' , then sub( A ) :code:`H` * X = sub( B ) is solved for X .
n
(global) INTEGER . The number of linear equations; the order of the distributed matrix sub( A ) (n≥ 0) .
bwl
(global) INTEGER . The number of sub-diagonals within the band of A( 0 ≤ bwl ≤ n-1 ) .
bwu
(global) INTEGER . The number of super-diagonals within the band of A( 0 ≤ bwu ≤ n-1 ) .
nrhs
(global) INTEGER . The number of right hand sides; the number of columns of the distributed matrix sub( B ) (nrhs≥ 0) .
- a , b
-
(local) REAL for psgbtrs DOUBLE PRECISION for pdgbtrs COMPLEX for pcgbtrs DOUBLE COMPLEX for pzgbtrs .
Pointers into the local memory to arrays of local sizes (lld_a,LOCc(ja+n-1)) and (lld_b,LOCc(nrhs)) , respectively.
The array a contains details of the LU factorization of the distributed band matrix A . On entry, the array b contains the local pieces of the right hand sides B ( ib : ib + n -1, 1: nrhs ).
ja
(global) INTEGER . The index in the global matrix A indicating the start of the matrix to be operated on ( which may be either all of A or a submatrix of A ).
desca
(global and local) INTEGER array of size dlen_ . The array descriptor for the distributed matrix A .
If dtype_a = 501 , then dlen_≥ 7 ; else if dtype_a = 1 , then dlen_≥ 9 .
ib
(global) INTEGER . The index in the global matrix A indicating the start of the matrix to be operated on (which may be either all of A or a submatrix of A ).
descb
(global and local) INTEGER array of size dlen_ . The array descriptor for the distributed matrix A .
If dtype_b = 502 , then dlen_≥ 7 ; else if dtype_b = 1 , then dlen_≥ 9 .
laf
(local) INTEGER . The size of the array af .
Must be laf ≥ nb_a *( bwl + bwu )+6*( bwl + bwu )*( bwl +2* bwu ).
If laf is not large enough, an error code will be returned and the minimum acceptable size will be returned in af (1) .
- work
-
(local) Same type as a . Workspace array of size lwork .
lwork
(local or global) INTEGER . The size of the work array, must be at least lwork≥nrhs*(nb_a+2*bwl+4*bwu) .
Output Parameters
ipiv
(local) INTEGER array.
The size of ipiv must be ≥nb_a . Contains pivot indices for local factorizations. Note that you should not alter the contents of this array between factorization and solve.
- b
-
On exit, overwritten by the local pieces of the solution distributed matrix X .
- af
-
(local) REAL for psgbtrs DOUBLE PRECISION for pdgbtrs COMPLEX for pcgbtrs DOUBLE COMPLEX for pzgbtrs . Array of size laf .
Auxiliary Fill-in space. The fill-in space is created in a call to the factorization routine p?gbtrf and is stored in af .
Note that if a linear system is to be solved using p?gbtrs after the factorization routine , af must not be altered after the factorization.
work(1)[0]
On exit, work(1)[0] contains the minimum value of lwork required for optimum performance.
info
INTEGER . If info=0 , the execution is successful.
info < 0 :
If the i -th argument is an array and the j- th entry had an illegal value, then info = -( i *100+ j ); if the i- th argument is a scalar and had an illegal value, then info = -i .