145 $ IPIV, CMODE, C, INFO, WORK,
154 INTEGER n, lda, ldaf, info, cmode
157 INTEGER iwork( * ), ipiv( * )
158 DOUBLE PRECISION a( lda, * ), af( ldaf, * ), work( * ), c( * )
166 DOUBLE PRECISION ainvnm, smlnum, tmp
190 ELSE IF( lda.LT.max( 1, n ) )
THEN
192 ELSE IF( ldaf.LT.max( 1, n ) )
THEN
196 CALL xerbla(
'DLA_SYRCOND', -info )
204 IF (
lsame( uplo,
'U' ) ) up = .true.
212 IF ( cmode .EQ. 1 )
THEN
214 tmp = tmp + abs( a( j, i ) * c( j ) )
217 tmp = tmp + abs( a( i, j ) * c( j ) )
219 ELSE IF ( cmode .EQ. 0 )
THEN
221 tmp = tmp + abs( a( j, i ) )
224 tmp = tmp + abs( a( i, j ) )
228 tmp = tmp + abs( a( j, i ) / c( j ) )
231 tmp = tmp + abs( a( i, j ) / c( j ) )
239 IF ( cmode .EQ. 1 )
THEN
241 tmp = tmp + abs( a( i, j ) * c( j ) )
244 tmp = tmp + abs( a( j, i ) * c( j ) )
246 ELSE IF ( cmode .EQ. 0 )
THEN
248 tmp = tmp + abs( a( i, j ) )
251 tmp = tmp + abs( a( j, i ) )
255 tmp = tmp + abs( a( i, j) / c( j ) )
258 tmp = tmp + abs( a( j, i) / c( j ) )
267 smlnum =
dlamch(
'Safe minimum' )
273 CALL dlacn2( n, work( n+1 ), work, iwork, ainvnm, kase, isave )
280 work( i ) = work( i ) * work( 2*n+i )
284 CALL dsytrs(
'U', n, 1, af, ldaf, ipiv, work, n,
287 CALL dsytrs(
'L', n, 1, af, ldaf, ipiv, work, n,
293 IF ( cmode .EQ. 1 )
THEN
295 work( i ) = work( i ) / c( i )
297 ELSE IF ( cmode .EQ. -1 )
THEN
299 work( i ) = work( i ) * c( i )
306 IF ( cmode .EQ. 1 )
THEN
308 work( i ) = work( i ) / c( i )
310 ELSE IF ( cmode .EQ. -1 )
THEN
312 work( i ) = work( i ) * c( i )
317 CALL dsytrs(
'U', n, 1, af, ldaf, ipiv, work, n,
320 CALL dsytrs(
'L', n, 1, af, ldaf, ipiv, work, n,
327 work( i ) = work( i ) * work( 2*n+i )
336 IF( ainvnm .NE. 0.0d+0 )
double precision function dla_syrcond(uplo, n, a, lda, af, ldaf, ipiv, cmode, c, info, work, iwork)
DLA_SYRCOND estimates the Skeel condition number for a symmetric indefinite matrix.
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...