MB02RD

Solution of a system of linear equations with upper Hessenberg matrix

[Specification] [Arguments] [Method] [References] [Comments] [Example]

Purpose

  To solve a system of linear equations
     H * X = B  or  H' * X = B
  with an upper Hessenberg N-by-N matrix H using the LU
  factorization computed by MB02SD.

Specification
      SUBROUTINE MB02RD( TRANS, N, NRHS, H, LDH, IPIV, B, LDB, INFO )
C     .. Scalar Arguments ..
      CHARACTER          TRANS
      INTEGER            INFO, LDB, LDH, N, NRHS
C     .. Array Arguments ..
      INTEGER            IPIV( * )
      DOUBLE PRECISION   B( LDB, * ), H( LDH, * )

Arguments

Mode Parameters

  TRANS   CHARACTER*1
          Specifies the form of the system of equations:
          = 'N':  H * X = B  (No transpose)
          = 'T':  H'* X = B  (Transpose)
          = 'C':  H'* X = B  (Conjugate transpose = Transpose)

Input/Output Parameters
  N       (input) INTEGER
          The order of the matrix H.  N >= 0.

  NRHS    (input) INTEGER
          The number of right hand sides, i.e., the number of
          columns of the matrix B.  NRHS >= 0.

  H       (input) DOUBLE PRECISION array, dimension (LDH,N)
          The factors L and U from the factorization H = P*L*U
          as computed by MB02SD.

  LDH     INTEGER
          The leading dimension of the array H.  LDH >= max(1,N).

  IPIV    (input) INTEGER array, dimension (N)
          The pivot indices from MB02SD; for 1<=i<=N, row i of the
          matrix was interchanged with row IPIV(i).

  B       (input/output) DOUBLE PRECISION array, dimension
          (LDB,NRHS)
          On entry, the right hand side matrix B.
          On exit, the solution matrix X.

  LDB     INTEGER
          The leading dimension of the array B.  LDB >= max(1,N).

Error Indicator
  INFO    (output) INTEGER
          = 0:  successful exit;
          < 0:  if INFO = -i, the i-th argument had an illegal
                value.

Method
  The routine uses the factorization
     H = P * L * U
  where P is a permutation matrix, L is lower triangular with unit
  diagonal elements (and one nonzero subdiagonal), and U is upper
  triangular.

References
  -

Numerical Aspects
                             2
  The algorithm requires 0( N x NRHS ) operations.

Further Comments
  None
Example

Program Text

  None
Program Data
  None
Program Results
  None

Return to index