STRSV/DTRSV/CTRSV/ZTRSV

Solve triangular system

Name

STRSV/DTRSV/CTRSV/ZTRSV

 

 

Solve triangular system

 

Purpose

Given an n-by-nupper- or lower-triangular matrix A and an n-vector x, these

 

subprograms overwrite x with the solution y to the system of linear equations

 

Ay = x. This is the forward elimination or back substitution step of Gaussian

 

elimination. Optionally, A can be replaced by AT, the transpose of A, or by A*,

 

the conjugate transpose of A. Specifically, these subprograms compute

 

x A–1x, x ATx, and

x A–*x,

 

where AT is the inverse of the transpose of A, and A–*is the inverse of the

 

conjugate transpose of A.

 

 

These subprograms are more primitive than the LAPACK linear equation

 

solvers. As such, they are intended to supplement but not replace them, serving

 

instead as building blocks in constructing optimized linear algebra software. In

 

fact, many of the LAPACK subprograms have been recoded to call these

 

subprograms.

 

 

Refer to “F_STRSV/F_DTRSV/F_CTRSV/F_ZTRSV” on page 417 for details of

 

the equivalent BLAS Standard subprograms.

 

Matrix

For these subprograms, you supply A in a two-dimensional array large enough

Storage

to hold a square matrix. The other triangle of the array is not referenced. If A

 

has an unstored unit diagonal (see input argument diag), then the diagonal

 

elements of the array also are not referenced.

 

Usage

VECLIB:

 

CHARACTER*1

uplo, trans, diag

INTEGER*4

n, lda, incx

REAL*4

a(lda, n), x(lenx)

CALL STRSV(uplo, trans, diag, n, a, lda, x, incx)

CHARACTER*1

uplo, trans, diag

INTEGER*4

n, lda, incx

REAL*8

a(lda, n), x(lenx)

CALL DTRSV(uplo, trans, diag, n, a, lda, x, incx)

CHARACTER*1

uplo, trans, diag

INTEGER*4

n, lda, incx

COMPLEX*8

a(lda, n), x(lenx)

CALL CTRSV(uplo, trans, diag, n, a, lda, x, incx)

332HP MLIB User’s Guide