147 SUBROUTINE cgeequb( M, N, A, LDA, R, C, ROWCND, COLCND, AMAX,
156 INTEGER info, lda, m, n
157 REAL amax, colcnd, rowcnd
168 parameter( one = 1.0e+0, zero = 0.0e+0 )
172 REAL bignum, rcmax, rcmin, smlnum, radix, logrdx
183 INTRINSIC abs, max, min, log,
REAL, aimag
189 cabs1( zdum ) = abs(
REAL( ZDUM ) ) + abs( aimag( zdum ) )
198 ELSE IF( n.LT.0 )
THEN
200 ELSE IF( lda.LT.max( 1, m ) )
THEN
204 CALL
xerbla(
'CGEEQUB', -info )
210 IF( m.EQ.0 .OR. n.EQ.0 )
THEN
220 bignum = one / smlnum
222 logrdx = log( radix )
234 r( i ) = max( r( i ), cabs1( a( i, j ) ) )
238 IF( r( i ).GT.zero )
THEN
239 r( i ) = radix**int( log(r( i ) ) / logrdx )
248 rcmax = max( rcmax, r( i ) )
249 rcmin = min( rcmin, r( i ) )
253 IF( rcmin.EQ.zero )
THEN
258 IF( r( i ).EQ.zero )
THEN
268 r( i ) = one / min( max( r( i ), smlnum ), bignum )
273 rowcnd = max( rcmin, smlnum ) / min( rcmax, bignum )
287 c( j ) = max( c( j ), cabs1( a( i, j ) )*r( i ) )
289 IF( c( j ).GT.zero )
THEN
290 c( j ) = radix**int( log( c( j ) ) / logrdx )
299 rcmin = min( rcmin, c( j ) )
300 rcmax = max( rcmax, c( j ) )
303 IF( rcmin.EQ.zero )
THEN
308 IF( c( j ).EQ.zero )
THEN
318 c( j ) = one / min( max( c( j ), smlnum ), bignum )
323 colcnd = max( rcmin, smlnum ) / min( rcmax, bignum )