105 RECURSIVE SUBROUTINE zpotrf2( UPLO, N, A, LDA, INFO )
116 COMPLEX*16 a( lda, * )
122 DOUBLE PRECISION one, zero
123 parameter( one = 1.0d+0, zero = 0.0d+0 )
125 parameter( cone = (1.0d+0, 0.0d+0) )
129 INTEGER n1, n2, iinfo
140 INTRINSIC max, dble, sqrt
147 upper =
lsame( uplo,
'U' )
148 IF( .NOT.upper .AND. .NOT.
lsame( uplo,
'L' ) )
THEN
150 ELSE IF( n.LT.0 )
THEN
152 ELSE IF( lda.LT.max( 1, n ) )
THEN
156 CALL xerbla(
'ZPOTRF2', -info )
171 ajj = dble( a( 1, 1 ) )
172 IF( ajj.LE.zero.OR.
disnan( ajj ) )
THEN
179 a( 1, 1 ) = sqrt( ajj )
189 CALL zpotrf2( uplo, n1, a( 1, 1 ), lda, iinfo )
190 IF ( iinfo.NE.0 )
THEN
201 CALL ztrsm(
'L',
'U',
'C',
'N', n1, n2, cone,
202 $ a( 1, 1 ), lda, a( 1, n1+1 ), lda )
206 CALL zherk( uplo,
'C', n2, n1, -one, a( 1, n1+1 ), lda,
207 $ one, a( n1+1, n1+1 ), lda )
208 CALL zpotrf2( uplo, n2, a( n1+1, n1+1 ), lda, iinfo )
209 IF ( iinfo.NE.0 )
THEN
220 CALL ztrsm(
'R',
'L',
'C',
'N', n2, n1, cone,
221 $ a( 1, 1 ), lda, a( n1+1, 1 ), lda )
225 CALL zherk( uplo,
'N', n2, n1, -one, a( n1+1, 1 ), lda,
226 $ one, a( n1+1, n1+1 ), lda )
227 CALL zpotrf2( uplo, n2, a( n1+1, n1+1 ), lda, iinfo )
228 IF ( iinfo.NE.0 )
THEN
subroutine xerbla(srname, info)
subroutine zherk(uplo, trans, n, k, alpha, a, lda, beta, c, ldc)
ZHERK
logical function disnan(din)
DISNAN tests input for NaN.
logical function lsame(ca, cb)
LSAME
recursive subroutine zpotrf2(uplo, n, a, lda, info)
ZPOTRF2
subroutine ztrsm(side, uplo, transa, diag, m, n, alpha, a, lda, b, ldb)
ZTRSM