111 SUBROUTINE dspt01( UPLO, N, A, AFAC, IPIV, C, LDC, RWORK, RESID )
121 DOUBLE PRECISION resid
125 DOUBLE PRECISION a( * ), afac( * ), c( ldc, * ), rwork( * )
131 DOUBLE PRECISION zero, one
132 parameter( zero = 0.0d+0, one = 1.0d+0 )
135 INTEGER i, info,
j, jc
136 DOUBLE PRECISION anorm, eps
161 anorm =
dlansp(
'1', uplo, n, a, rwork )
165 CALL
dlaset(
'Full', n, n, zero, one, c, ldc )
169 CALL
dlavsp( uplo,
'Transpose',
'Non-unit', n, n, afac, ipiv, c,
174 CALL
dlavsp( uplo,
'No transpose',
'Unit', n, n, afac, ipiv, c,
179 IF(
lsame( uplo,
'U' ) )
THEN
183 c( i,
j ) = c( i,
j ) - a( jc+i )
191 c( i,
j ) = c( i,
j ) - a( jc+i-
j )
199 resid =
dlansy(
'1', uplo, n, c, ldc, rwork )
201 IF( anorm.LE.zero )
THEN
205 resid = ( ( resid / dble( n ) ) / anorm ) / eps
LOGICAL function lsame(CA, CB)
LSAME
DOUBLE PRECISION function dlansy(NORM, UPLO, N, A, LDA, WORK)
DLANSY returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real symmetric matrix.
subroutine dspt01(UPLO, N, A, AFAC, IPIV, C, LDC, RWORK, RESID)
DSPT01
set ue cd $ADTTMP cat<< EOF > tmp f Program LinearEquations Implicit none Real j
DOUBLE PRECISION function dlansp(NORM, UPLO, N, AP, WORK)
DLANSP returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a symmetric matrix supplied in packed form.
DOUBLE PRECISION function dlamch(CMACH)
DLAMCH
subroutine dlavsp(UPLO, TRANS, DIAG, N, NRHS, A, IPIV, B, LDB, INFO)
DLAVSP
subroutine dlaset(UPLO, M, N, ALPHA, BETA, A, LDA)
DLASET initializes the off-diagonal elements and the diagonal elements of a matrix to given values...