143 SUBROUTINE ctbcon( NORM, UPLO, DIAG, N, KD, AB, LDAB, RCOND, WORK,
152 CHARACTER diag, norm, uplo
153 INTEGER info, kd, ldab, n
158 COMPLEX ab( ldab, * ), work( * )
165 parameter( one = 1.0e+0, zero = 0.0e+0 )
168 LOGICAL nounit, onenrm, upper
170 INTEGER ix, kase, kase1
171 REAL ainvnm, anorm, scale, smlnum, xnorm
187 INTRINSIC abs, aimag, max, real
193 cabs1( zdum ) = abs(
REAL( ZDUM ) ) + abs( aimag( zdum ) )
200 upper =
lsame( uplo,
'U' )
201 onenrm = norm.EQ.
'1' .OR.
lsame( norm,
'O' )
202 nounit =
lsame( diag,
'N' )
204 IF( .NOT.onenrm .AND. .NOT.
lsame( norm,
'I' ) )
THEN
206 ELSE IF( .NOT.upper .AND. .NOT.
lsame( uplo,
'L' ) )
THEN
208 ELSE IF( .NOT.nounit .AND. .NOT.
lsame( diag,
'U' ) )
THEN
210 ELSE IF( n.LT.0 )
THEN
212 ELSE IF( kd.LT.0 )
THEN
214 ELSE IF( ldab.LT.kd+1 )
THEN
218 CALL
xerbla(
'CTBCON', -info )
230 smlnum =
slamch(
'Safe minimum' )*
REAL( MAX( N, 1 ) )
234 anorm =
clantb( norm, uplo, diag, n, kd, ab, ldab, rwork )
238 IF( anorm.GT.zero )
THEN
251 CALL
clacn2( n, work( n+1 ), work, ainvnm, kase, isave )
253 IF( kase.EQ.kase1 )
THEN
257 CALL
clatbs( uplo,
'No transpose', diag, normin, n, kd,
258 $ ab, ldab, work, scale, rwork, info )
263 CALL
clatbs( uplo,
'Conjugate transpose', diag, normin,
264 $ n, kd, ab, ldab, work, scale, rwork, info )
270 IF( scale.NE.one )
THEN
272 xnorm = cabs1( work( ix ) )
273 IF( scale.LT.xnorm*smlnum .OR. scale.EQ.zero )
275 CALL
csrscl( n, scale, work, 1 )
283 $ rcond = ( one / anorm ) / ainvnm
real function clantb(NORM, UPLO, DIAG, N, K, AB, LDAB, WORK)
CLANTB returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a triangular band matrix.
subroutine xerbla(SRNAME, INFO)
XERBLA
integer function icamax(N, CX, INCX)
ICAMAX
subroutine csrscl(N, SA, SX, INCX)
CSRSCL multiplies a vector by the reciprocal of a real scalar.
logical function lsame(CA, CB)
LSAME
real function slamch(CMACH)
SLAMCH
subroutine clatbs(UPLO, TRANS, DIAG, NORMIN, N, KD, AB, LDAB, X, SCALE, CNORM, INFO)
CLATBS solves a triangular banded system of equations.
subroutine ctbcon(NORM, UPLO, DIAG, N, KD, AB, LDAB, RCOND, WORK, RWORK, INFO)
CTBCON
subroutine clacn2(N, V, X, EST, KASE, ISAVE)
CLACN2 estimates the 1-norm of a square matrix, using reverse communication for evaluating matrix-vec...