108 SUBROUTINE ctrtri( UPLO, DIAG, N, A, LDA, INFO )
126 parameter( one = ( 1.0e+0, 0.0e+0 ),
127 $ zero = ( 0.0e+0, 0.0e+0 ) )
130 LOGICAL NOUNIT, UPPER
131 INTEGER J, JB, NB, NN
136 EXTERNAL lsame, ilaenv
149 upper = lsame( uplo,
'U' )
150 nounit = lsame( diag,
'N' )
151 IF( .NOT.upper .AND. .NOT.lsame( uplo,
'L' ) )
THEN
153 ELSE IF( .NOT.nounit .AND. .NOT.lsame( diag,
'U' ) )
THEN
155 ELSE IF( n.LT.0 )
THEN
157 ELSE IF( lda.LT.max( 1, n ) )
THEN
161 CALL xerbla(
'CTRTRI', -info )
174 IF( a( info, info ).EQ.zero )
182 nb = ilaenv( 1,
'CTRTRI', uplo // diag, n, -1, -1, -1 )
183 IF( nb.LE.1 .OR. nb.GE.n )
THEN
187 CALL ctrti2( uplo, diag, n, a, lda, info )
197 jb = min( nb, n-j+1 )
201 CALL ctrmm(
'Left',
'Upper',
'No transpose', diag, j-1,
202 $ jb, one, a, lda, a( 1, j ), lda )
203 CALL ctrsm(
'Right',
'Upper',
'No transpose', diag, j-1,
204 $ jb, -one, a( j, j ), lda, a( 1, j ), lda )
208 CALL ctrti2(
'Upper', diag, jb, a( j, j ), lda, info )
214 nn = ( ( n-1 ) / nb )*nb + 1
216 jb = min( nb, n-j+1 )
221 CALL ctrmm(
'Left',
'Lower',
'No transpose', diag,
222 $ n-j-jb+1, jb, one, a( j+jb, j+jb ), lda,
223 $ a( j+jb, j ), lda )
224 CALL ctrsm(
'Right',
'Lower',
'No transpose', diag,
225 $ n-j-jb+1, jb, -one, a( j, j ), lda,
226 $ a( j+jb, j ), lda )
231 CALL ctrti2(
'Lower', diag, jb, a( j, j ), lda, info )
subroutine xerbla(srname, info)
subroutine ctrmm(side, uplo, transa, diag, m, n, alpha, a, lda, b, ldb)
CTRMM
subroutine ctrsm(side, uplo, transa, diag, m, n, alpha, a, lda, b, ldb)
CTRSM
subroutine ctrti2(uplo, diag, n, a, lda, info)
CTRTI2 computes the inverse of a triangular matrix (unblocked algorithm).
subroutine ctrtri(uplo, diag, n, a, lda, info)
CTRTRI