135 SUBROUTINE dlacn2( N, V, X, ISGN, EST, KASE, ISAVE )
146 INTEGER ISGN( * ), ISAVE( 3 )
147 DOUBLE PRECISION V( * ), X( * )
154 parameter( itmax = 5 )
155 DOUBLE PRECISION ZERO, ONE, TWO
156 parameter( zero = 0.0d+0, one = 1.0d+0, two = 2.0d+0 )
160 DOUBLE PRECISION ALTSGN, ESTOLD, TEMP, XS
164 DOUBLE PRECISION DASUM
165 EXTERNAL idamax, dasum
171 INTRINSIC abs, dble, nint
177 x( i ) = one / dble( n )
184 GO TO ( 20, 40, 70, 110, 140 )isave( 1 )
196 est = dasum( n, x, 1 )
199 IF( x(i).GE.zero )
THEN
204 isgn( i ) = nint( x( i ) )
214 isave( 2 ) = idamax( n, x, 1 )
223 x( isave( 2 ) ) = one
232 CALL dcopy( n, x, 1, v, 1 )
234 est = dasum( n, v, 1 )
236 IF( x(i).GE.zero )
THEN
241 IF( nint( xs ).NE.isgn( i ) )
253 IF( x(i).GE.zero )
THEN
258 isgn( i ) = nint( x( i ) )
269 isave( 2 ) = idamax( n, x, 1 )
270 IF( ( x( jlast ).NE.abs( x( isave( 2 ) ) ) ) .AND.
271 $ ( isave( 3 ).LT.itmax ) )
THEN
272 isave( 3 ) = isave( 3 ) + 1
281 x( i ) = altsgn*( one+dble( i-1 ) / dble( n-1 ) )
292 temp = two*( dasum( n, x, 1 ) / dble( 3*n ) )
293 IF( temp.GT.est )
THEN
294 CALL dcopy( n, x, 1, v, 1 )
subroutine dcopy(n, dx, incx, dy, incy)
DCOPY
subroutine dlacn2(n, v, x, isgn, est, kase, isave)
DLACN2 estimates the 1-norm of a square matrix, using reverse communication for evaluating matrix-vec...