p?pttrsv
p?pttrsv
Solves a single triangular linear system via frontsolve or backsolve where the triangular matrix is a factor of a tridiagonal matrix computed by
p?pttrf
.Syntax
void
pspttrsv
(
char
*uplo
,
MKL_INT
*n
,
MKL_INT
*nrhs
,
float
*d
,
float
*e
,
MKL_INT
*ja
,
MKL_INT
*desca
,
float
*b
,
MKL_INT
*ib
,
MKL_INT
*descb
,
float
*af
,
MKL_INT
*laf
,
float
*work
,
MKL_INT
*lwork
,
MKL_INT
*info
);
void
pdpttrsv
(
char
*uplo
,
MKL_INT
*n
,
MKL_INT
*nrhs
,
double
*d
,
double
*e
,
MKL_INT
*ja
,
MKL_INT
*desca
,
double
*b
,
MKL_INT
*ib
,
MKL_INT
*descb
,
double
*af
,
MKL_INT
*laf
,
double
*work
,
MKL_INT
*lwork
,
MKL_INT
*info
);
void
pcpttrsv
(
char
*uplo
,
char
*trans
,
MKL_INT
*n
,
MKL_INT
*nrhs
,
float
*d
,
MKL_Complex8
*e
,
MKL_INT
*ja
,
MKL_INT
*desca
,
MKL_Complex8
*b
,
MKL_INT
*ib
,
MKL_INT
*descb
,
MKL_Complex8
*af
,
MKL_INT
*laf
,
MKL_Complex8
*work
,
MKL_INT
*lwork
,
MKL_INT
*info
);
void
pzpttrsv
(
char
*uplo
,
char
*trans
,
MKL_INT
*n
,
MKL_INT
*nrhs
,
double
*d
,
MKL_Complex16
*e
,
MKL_INT
*ja
,
MKL_INT
*desca
,
MKL_Complex16
*b
,
MKL_INT
*ib
,
MKL_INT
*descb
,
MKL_Complex16
*af
,
MKL_INT
*laf
,
MKL_Complex16
*work
,
MKL_INT
*lwork
,
MKL_INT
*info
);
Include Files
- mkl_scalapack.h
Description
The
p?pttrsv
function
solves a tridiagonal triangular system of linear equationsA
(1:
n
, ja
:ja
+n
-1)*X
= B
(
jb
:jb+n
-1, 1:nrhs
) or
A
(1:*
n
, ja
:ja
+n
-1)T
X
= B
(
for real flavors,jb
:jb+n
-1, 1:nrhs
)A
(1:*
n
, ja
:ja
+n
-1)H
X
= B
(
for complex flavors,jb
:jb+n
-1, 1:nrhs
)where
A
(1:
is a tridiagonal triangular matrix factor produced by the Cholesky factorization code n
, ja
:ja
+n
-1)p?pttrf
and is stored in A
(1:
and n
, ja
:ja
+n
-1)af
. The matrix stored in A
(1:
is either upper or lower triangular according to n
, ja
:ja
+n
-1)uplo
. The function
p?pttrf
must be called first.Input Parameters
- uplo
- (global) Must be'U'or'L'.If, upper triangle ofuplo='U'A(1:is stored;n,ja:ja+n-1)If, lower triangle ofuplo='L'A(1:is stored.n,ja:ja+n-1)
- trans
- (global) Must be'N'or'C'.If, solve withtrans='N'A(1:;n,ja:ja+n-1)Iftrans='C'(for complex flavors), solve with conjugate transpose (A(1:)n,ja:ja+n-1).H
- n
- (global)The number of rows and columns to be operated on, that is, the order of the distributed submatrixA(1:.n,ja:ja+n-1).n≥0
- nrhs
- (global)The number of right hand sides; the number of columns of the distributed submatrixB(jb:jb+n-1, 1:nrhs);.nrhs≥0
- d
- (local)Pointer to the local part of the global vector storing the main diagonal of the matrix; must be of size≥nb_a.
- e
- (local)Pointer to the local part of the global vectordustoring the upper diagonal of the matrix; must be of size≥nb_a. Globally,du(n) is not referenced, anddumust be aligned withd.
- ja
- (global) The index in the global matrixAthat points to the start of the matrix to be operated on (which may be either all ofAor a submatrix ofA).
- desca
- (global and local) array of sizedlen_. The array descriptor for the distributed matrixA.If1D type (, thendtype_a= 501 or 502);dlen≥7If2D type (, thendtype_a= 1).dlen≥9Contains information on mapping ofAto memory. See ScaLAPACK manual for full description and options.
- b
- (local)Pointer into the local memory to an array of local lead size.lld_b≥nbOn entry, this array contains the local pieces of the right hand sidesB(.jb:jb+n-1, 1:nrhs)
- ib
- (global) The row index in the global matrixBthat points to the first row of the matrix to be operated on (which may be either all ofBor a submatrix ofB).
- descb
- (global and local) array of sizedlen_. The array descriptor for the distributed matrixB.If1D type (, thendtype_b= 502);dlen≥7If2D type (, thendtype_b= 1).dlen≥9Contains information on mapping ofBto memory. See ScaLAPACK manual for full description and options.
- laf
- (local)The size of user-input auxiliary fill-in spaceaf. Must be.laf≥(nb+2*bw)*bwIflafis not large enough, an error code will be returned and the minimum acceptable size will be returned in.af[0]
- work
- (local)The arrayworkis a temporary workspace array of sizelwork. This space may be overwritten in betweenfunction calls.
- lwork
- (local or global) The size of the user-input workspacework, must be at least. Iflwork≥(10+2*min(100,nrhs))*npcol+4*nrhslworkis too small, the minimal acceptable size will be returned inand an error code is returned.work[0]
Output Parameters
- d,e
- (local).On exit, these arrays contain information on the factors of the matrix.
- af
- (local)
- b
- On exit, this array contains the local piece of the solutions distributed matrixX.
- work[0]
- On exit,contains the minimum value ofwork[0]lwork.
- info
- (local)= 0: successful exit< 0: if thei-th argument is an array and thej-th entry, indexedhad an illegal value,j-1,theninfo= - (i*100 +j),if thei-th argument is a scalar and had an illegal value,theninfo= -i.