118 SUBROUTINE cbdt02( M, N, B, LDB, C, LDC, U, LDU, WORK, RWORK,
126 INTEGER LDB, LDC, LDU, M, N
131 COMPLEX B( LDB, * ), C( LDC, * ), U( LDU, * ),
139 parameter( zero = 0.0e+0, one = 1.0e+0 )
143 REAL BNORM, EPS, REALMN
146 REAL CLANGE, SCASUM, SLAMCH
147 EXTERNAL clange, scasum, slamch
153 INTRINSIC cmplx, max, min, real
160 IF( m.LE.0 .OR. n.LE.0 )
162 realmn = real( max( m, n ) )
163 eps = slamch(
'Precision' )
168 CALL ccopy( m, b( 1, j ), 1, work, 1 )
169 CALL cgemv(
'No transpose', m, m, -cmplx( one ), u, ldu,
170 $ c( 1, j ), 1, cmplx( one ), work, 1 )
171 resid = max( resid, scasum( m, work, 1 ) )
176 bnorm = clange(
'1', m, n, b, ldb, rwork )
178 IF( bnorm.LE.zero )
THEN
182 IF( bnorm.GE.resid )
THEN
183 resid = ( resid / bnorm ) / ( realmn*eps )
185 IF( bnorm.LT.one )
THEN
186 resid = ( min( resid, realmn*bnorm ) / bnorm ) /
189 resid = min( resid / bnorm, realmn ) / ( realmn*eps )
subroutine cbdt02(m, n, b, ldb, c, ldc, u, ldu, work, rwork, resid)
CBDT02
subroutine ccopy(n, cx, incx, cy, incy)
CCOPY
subroutine cgemv(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
CGEMV