72 parameter( zero = 0.0d+0 )
75 INTEGER i, ihi, ihiin, ilo, iloin, info, j, knt, n,
77 DOUBLE PRECISION anorm, meps, rmax, sfmin, temp, vmax
81 DOUBLE PRECISION a( lda, lda ), ain( lda, lda ), dummy( 1 ),
82 $ scale( lda ), scalin( lda )
108 READ( nin, fmt = * )n
112 READ( nin, fmt = * )( a( i, j ), j = 1, n )
115 READ( nin, fmt = * )iloin, ihiin
117 READ( nin, fmt = * )( ain( i, j ), j = 1, n )
119 READ( nin, fmt = * )( scalin( i ), i = 1, n )
121 anorm =
dlange(
'M', n, n, a, lda, dummy )
124 CALL
dgebal(
'B', n, a, lda, ilo, ihi, scale, info )
131 IF( ilo.NE.iloin .OR. ihi.NE.ihiin )
THEN
138 temp = max( a( i, j ), ain( i, j ) )
139 temp = max( temp, sfmin )
140 vmax = max( vmax, abs( a( i, j )-ain( i, j ) ) / temp )
145 temp = max( scale( i ), scalin( i ) )
146 temp = max( temp, sfmin )
147 vmax = max( vmax, abs( scale( i )-scalin( i ) ) / temp )
151 IF( vmax.GT.rmax )
THEN
160 WRITE( nout, fmt = 9999 )
161 9999 format( 1x,
'.. test output of DGEBAL .. ' )
163 WRITE( nout, fmt = 9998 )rmax
164 9998 format( 1x,
'value of largest test error = ', d12.3 )
165 WRITE( nout, fmt = 9997 )lmax( 1 )
166 9997 format( 1x,
'example number where info is not zero = ', i4 )
167 WRITE( nout, fmt = 9996 )lmax( 2 )
168 9996 format( 1x,
'example number where ILO or IHI wrong = ', i4 )
169 WRITE( nout, fmt = 9995 )lmax( 3 )
170 9995 format( 1x,
'example number having largest error = ', i4 )
171 WRITE( nout, fmt = 9994 )ninfo
172 9994 format( 1x,
'number of examples where info is not 0 = ', i4 )
173 WRITE( nout, fmt = 9993 )knt
174 9993 format( 1x,
'total number of examples tested = ', i4 )