133 SUBROUTINE cqrt16( TRANS, M, N, NRHS, A, LDA, X, LDX, B, LDB,
143 INTEGER LDA, LDB, LDX, M, N, NRHS
148 COMPLEX A( lda, * ), B( ldb, * ), X( ldx, * )
155 parameter ( zero = 0.0e+0, one = 1.0e+0 )
157 parameter ( cone = ( 1.0e+0, 0.0e+0 ) )
161 REAL ANORM, BNORM, EPS, XNORM
165 REAL CLANGE, SCASUM, SLAMCH
166 EXTERNAL lsame, clange, scasum, slamch
178 IF( m.LE.0 .OR. n.LE.0 .OR. nrhs.EQ.0 )
THEN
183 IF( lsame( trans,
'T' ) .OR. lsame( trans,
'C' ) )
THEN
184 anorm = clange(
'I', m, n, a, lda, rwork )
188 anorm = clange(
'1', m, n, a, lda, rwork )
193 eps = slamch(
'Epsilon' )
197 CALL cgemm( trans,
'No transpose', n1, nrhs, n2, -cone, a, lda, x,
198 $ ldx, cone, b, ldb )
205 bnorm = scasum( n1, b( 1, j ), 1 )
206 xnorm = scasum( n2, x( 1, j ), 1 )
207 IF( anorm.EQ.zero .AND. bnorm.EQ.zero )
THEN
209 ELSE IF( anorm.LE.zero .OR. xnorm.LE.zero )
THEN
212 resid = max( resid, ( ( bnorm / anorm ) / xnorm ) /
213 $ ( max( m, n )*eps ) )
subroutine cqrt16(TRANS, M, N, NRHS, A, LDA, X, LDX, B, LDB, RWORK, RESID)
CQRT16
subroutine cgemm(TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
CGEMM