LAPACK 3.12.0
LAPACK: Linear Algebra PACKage
Loading...
Searching...
No Matches

◆ cla_gbrpvgrw()

real function cla_gbrpvgrw ( integer  n,
integer  kl,
integer  ku,
integer  ncols,
complex, dimension( ldab, * )  ab,
integer  ldab,
complex, dimension( ldafb, * )  afb,
integer  ldafb 
)

CLA_GBRPVGRW computes the reciprocal pivot growth factor norm(A)/norm(U) for a general banded matrix.

Download CLA_GBRPVGRW + dependencies [TGZ] [ZIP] [TXT]

Purpose:
 CLA_GBRPVGRW computes the reciprocal pivot growth factor
 norm(A)/norm(U). The "max absolute element" norm is used. If this is
 much less than 1, the stability of the LU factorization of the
 (equilibrated) matrix A could be poor. This also means that the
 solution X, estimated condition numbers, and error bounds could be
 unreliable.
Parameters
[in]N
          N is INTEGER
     The number of linear equations, i.e., the order of the
     matrix A.  N >= 0.
[in]KL
          KL is INTEGER
     The number of subdiagonals within the band of A.  KL >= 0.
[in]KU
          KU is INTEGER
     The number of superdiagonals within the band of A.  KU >= 0.
[in]NCOLS
          NCOLS is INTEGER
     The number of columns of the matrix A.  NCOLS >= 0.
[in]AB
          AB is COMPLEX array, dimension (LDAB,N)
     On entry, the matrix A in band storage, in rows 1 to KL+KU+1.
     The j-th column of A is stored in the j-th column of the
     array AB as follows:
     AB(KU+1+i-j,j) = A(i,j) for max(1,j-KU)<=i<=min(N,j+kl)
[in]LDAB
          LDAB is INTEGER
     The leading dimension of the array AB.  LDAB >= KL+KU+1.
[in]AFB
          AFB is COMPLEX array, dimension (LDAFB,N)
     Details of the LU factorization of the band matrix A, as
     computed by CGBTRF.  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]LDAFB
          LDAFB is INTEGER
     The leading dimension of the array AFB.  LDAFB >= 2*KL+KU+1.
Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.

Definition at line 115 of file cla_gbrpvgrw.f.

117*
118* -- LAPACK computational routine --
119* -- LAPACK is a software package provided by Univ. of Tennessee, --
120* -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
121*
122* .. Scalar Arguments ..
123 INTEGER N, KL, KU, NCOLS, LDAB, LDAFB
124* ..
125* .. Array Arguments ..
126 COMPLEX AB( LDAB, * ), AFB( LDAFB, * )
127* ..
128*
129* =====================================================================
130*
131* .. Local Scalars ..
132 INTEGER I, J, KD
133 REAL AMAX, UMAX, RPVGRW
134 COMPLEX ZDUM
135* ..
136* .. Intrinsic Functions ..
137 INTRINSIC abs, max, min, real, aimag
138* ..
139* .. Statement Functions ..
140 REAL CABS1
141* ..
142* .. Statement Function Definitions ..
143 cabs1( zdum ) = abs( real( zdum ) ) + abs( aimag( zdum ) )
144* ..
145* .. Executable Statements ..
146*
147 rpvgrw = 1.0
148
149 kd = ku + 1
150 DO j = 1, ncols
151 amax = 0.0
152 umax = 0.0
153 DO i = max( j-ku, 1 ), min( j+kl, n )
154 amax = max( cabs1( ab( kd+i-j, j ) ), amax )
155 END DO
156 DO i = max( j-ku, 1 ), j
157 umax = max( cabs1( afb( kd+i-j, j ) ), umax )
158 END DO
159 IF ( umax /= 0.0 ) THEN
160 rpvgrw = min( amax / umax, rpvgrw )
161 END IF
162 END DO
163 cla_gbrpvgrw = rpvgrw
164*
165* End of CLA_GBRPVGRW
166*
real function cla_gbrpvgrw(n, kl, ku, ncols, ab, ldab, afb, ldafb)
CLA_GBRPVGRW computes the reciprocal pivot growth factor norm(A)/norm(U) for a general banded matrix.
Here is the call graph for this function:
Here is the caller graph for this function: