160 SUBROUTINE zhesv_aa( UPLO, N, NRHS, A, LDA, IPIV, B, LDB, WORK,
169 INTEGER INFO, LDA, LDB, LWORK, N, NRHS
173 COMPLEX*16 A( LDA, * ), B( LDB, * ), WORK( * )
180 INTEGER LWKOPT, LWKOPT_HETRF, LWKOPT_HETRS
185 EXTERNAL lsame, ilaenv
198 lquery = ( lwork.EQ.-1 )
199 IF( .NOT.lsame( uplo,
'U' ) .AND. .NOT.lsame( uplo,
'L' ) )
THEN
201 ELSE IF( n.LT.0 )
THEN
203 ELSE IF( nrhs.LT.0 )
THEN
205 ELSE IF( lda.LT.max( 1, n ) )
THEN
207 ELSE IF( ldb.LT.max( 1, n ) )
THEN
209 ELSE IF( lwork.LT.max(2*n, 3*n-2) .AND. .NOT.lquery )
THEN
214 CALL zhetrf_aa( uplo, n, a, lda, ipiv, work, -1, info )
215 lwkopt_hetrf = int( work(1) )
216 CALL zhetrs_aa( uplo, n, nrhs, a, lda, ipiv, b, ldb, work,
218 lwkopt_hetrs = int( work(1) )
219 lwkopt = max( lwkopt_hetrf, lwkopt_hetrs )
224 CALL xerbla(
'ZHESV_AA ', -info )
226 ELSE IF( lquery )
THEN
232 CALL zhetrf_aa( uplo, n, a, lda, ipiv, work, lwork, info )
237 CALL zhetrs_aa( uplo, n, nrhs, a, lda, ipiv, b, ldb, work,
subroutine xerbla(srname, info)
subroutine zhesv_aa(uplo, n, nrhs, a, lda, ipiv, b, ldb, work, lwork, info)
ZHESV_AA computes the solution to system of linear equations A * X = B for HE matrices
subroutine zhetrf_aa(uplo, n, a, lda, ipiv, work, lwork, info)
ZHETRF_AA
subroutine zhetrs_aa(uplo, n, nrhs, a, lda, ipiv, b, ldb, work, lwork, info)
ZHETRS_AA