Functions | |
| subroutine | checon (uplo, n, a, lda, ipiv, anorm, rcond, work, info) |
| CHECON | |
| subroutine | checon_3 (uplo, n, a, lda, e, ipiv, anorm, rcond, work, info) |
| CHECON_3 | |
| subroutine | checon_rook (uplo, n, a, lda, ipiv, anorm, rcond, work, info) |
| CHECON_ROOK estimates the reciprocal of the condition number fort HE matrices using factorization obtained with one of the bounded diagonal pivoting methods (max 2 interchanges) | |
| subroutine | cheequb (uplo, n, a, lda, s, scond, amax, work, info) |
| CHEEQUB | |
| subroutine | chegs2 (itype, uplo, n, a, lda, b, ldb, info) |
| CHEGS2 reduces a Hermitian definite generalized eigenproblem to standard form, using the factorization results obtained from cpotrf (unblocked algorithm). | |
| subroutine | chegst (itype, uplo, n, a, lda, b, ldb, info) |
| CHEGST | |
| subroutine | cherfs (uplo, n, nrhs, a, lda, af, ldaf, ipiv, b, ldb, x, ldx, ferr, berr, work, rwork, info) |
| CHERFS | |
| subroutine | cherfsx (uplo, equed, n, nrhs, a, lda, af, ldaf, ipiv, s, b, ldb, x, ldx, rcond, berr, n_err_bnds, err_bnds_norm, err_bnds_comp, nparams, params, work, rwork, info) |
| CHERFSX | |
| subroutine | chetd2 (uplo, n, a, lda, d, e, tau, info) |
| CHETD2 reduces a Hermitian matrix to real symmetric tridiagonal form by an unitary similarity transformation (unblocked algorithm). | |
| subroutine | chetf2 (uplo, n, a, lda, ipiv, info) |
| CHETF2 computes the factorization of a complex Hermitian matrix, using the diagonal pivoting method (unblocked algorithm calling Level 2 BLAS). | |
| subroutine | chetf2_rk (uplo, n, a, lda, e, ipiv, info) |
| CHETF2_RK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman (rook) diagonal pivoting method (BLAS2 unblocked algorithm). | |
| subroutine | chetf2_rook (uplo, n, a, lda, ipiv, info) |
| CHETF2_ROOK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman ("rook") diagonal pivoting method (unblocked algorithm). | |
| subroutine | chetrd (uplo, n, a, lda, d, e, tau, work, lwork, info) |
| CHETRD | |
| subroutine | chetrd_2stage (vect, uplo, n, a, lda, d, e, tau, hous2, lhous2, work, lwork, info) |
| CHETRD_2STAGE | |
| subroutine | chetrd_he2hb (uplo, n, kd, a, lda, ab, ldab, tau, work, lwork, info) |
| CHETRD_HE2HB | |
| subroutine | chetrf (uplo, n, a, lda, ipiv, work, lwork, info) |
| CHETRF | |
| subroutine | chetrf_aa (uplo, n, a, lda, ipiv, work, lwork, info) |
| CHETRF_AA | |
| subroutine | chetrf_rk (uplo, n, a, lda, e, ipiv, work, lwork, info) |
| CHETRF_RK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman (rook) diagonal pivoting method (BLAS3 blocked algorithm). | |
| subroutine | chetrf_rook (uplo, n, a, lda, ipiv, work, lwork, info) |
| CHETRF_ROOK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman ("rook") diagonal pivoting method (blocked algorithm, calling Level 3 BLAS). | |
| subroutine | chetri (uplo, n, a, lda, ipiv, work, info) |
| CHETRI | |
| subroutine | chetri2 (uplo, n, a, lda, ipiv, work, lwork, info) |
| CHETRI2 | |
| subroutine | chetri2x (uplo, n, a, lda, ipiv, work, nb, info) |
| CHETRI2X | |
| subroutine | chetri_3 (uplo, n, a, lda, e, ipiv, work, lwork, info) |
| CHETRI_3 | |
| subroutine | chetri_3x (uplo, n, a, lda, e, ipiv, work, nb, info) |
| CHETRI_3X | |
| subroutine | chetri_rook (uplo, n, a, lda, ipiv, work, info) |
| CHETRI_ROOK computes the inverse of HE matrix using the factorization obtained with the bounded Bunch-Kaufman ("rook") diagonal pivoting method. | |
| subroutine | chetrs (uplo, n, nrhs, a, lda, ipiv, b, ldb, info) |
| CHETRS | |
| subroutine | chetrs2 (uplo, n, nrhs, a, lda, ipiv, b, ldb, work, info) |
| CHETRS2 | |
| subroutine | chetrs_3 (uplo, n, nrhs, a, lda, e, ipiv, b, ldb, info) |
| CHETRS_3 | |
| subroutine | chetrs_aa (uplo, n, nrhs, a, lda, ipiv, b, ldb, work, lwork, info) |
| CHETRS_AA | |
| subroutine | chetrs_rook (uplo, n, nrhs, a, lda, ipiv, b, ldb, info) |
| CHETRS_ROOK computes the solution to a system of linear equations A * X = B for HE matrices using factorization obtained with one of the bounded diagonal pivoting methods (max 2 interchanges) | |
| subroutine | cla_heamv (uplo, n, alpha, a, lda, x, incx, beta, y, incy) |
| CLA_HEAMV computes a matrix-vector product using a Hermitian indefinite matrix to calculate error bounds. | |
| real function | cla_hercond_c (uplo, n, a, lda, af, ldaf, ipiv, c, capply, info, work, rwork) |
| CLA_HERCOND_C computes the infinity norm condition number of op(A)*inv(diag(c)) for Hermitian indefinite matrices. | |
| real function | cla_hercond_x (uplo, n, a, lda, af, ldaf, ipiv, x, info, work, rwork) |
| CLA_HERCOND_X computes the infinity norm condition number of op(A)*diag(x) for Hermitian indefinite matrices. | |
| subroutine | cla_herfsx_extended (prec_type, uplo, n, nrhs, a, lda, af, ldaf, ipiv, colequ, c, b, ldb, y, ldy, berr_out, n_norms, err_bnds_norm, err_bnds_comp, res, ayb, dy, y_tail, rcond, ithresh, rthresh, dz_ub, ignore_cwise, info) |
| CLA_HERFSX_EXTENDED improves the computed solution to a system of linear equations for Hermitian indefinite matrices by performing extra-precise iterative refinement and provides error bounds and backward error estimates for the solution. | |
| real function | cla_herpvgrw (uplo, n, info, a, lda, af, ldaf, ipiv, work) |
| CLA_HERPVGRW | |
| subroutine | clahef (uplo, n, nb, kb, a, lda, ipiv, w, ldw, info) |
| CLAHEF computes a partial factorization of a complex Hermitian indefinite matrix using the Bunch-Kaufman diagonal pivoting method (blocked algorithm, calling Level 3 BLAS). | |
| subroutine | clahef_rk (uplo, n, nb, kb, a, lda, e, ipiv, w, ldw, info) |
| CLAHEF_RK computes a partial factorization of a complex Hermitian indefinite matrix using bounded Bunch-Kaufman (rook) diagonal pivoting method. | |
| subroutine | clahef_rook (uplo, n, nb, kb, a, lda, ipiv, w, ldw, info) |
|
Download CLAHEF_ROOK + dependencies
[TGZ]
[ZIP]
[TXT]
| |
This is the group of complex computational functions for HE matrices
| subroutine checon | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| real | anorm, | ||
| real | rcond, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHECON
Download CHECON + dependencies [TGZ] [ZIP] [TXT]
!> !> CHECON estimates the reciprocal of the condition number of a complex !> Hermitian matrix A using the factorization A = U*D*U**H or !> A = L*D*L**H computed by CHETRF. !> !> An estimate is obtained for norm(inv(A)), and the reciprocal of the !> condition number is computed as RCOND = 1 / (ANORM * norm(inv(A))). !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in] | ANORM | !> ANORM is REAL !> The 1-norm of the original matrix A. !> |
| [out] | RCOND | !> RCOND is REAL !> The reciprocal of the condition number of the matrix A, !> computed as RCOND = 1/(ANORM * AINVNM), where AINVNM is an !> estimate of the 1-norm of inv(A) computed in this routine. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
Definition at line 123 of file checon.f.
| subroutine checon_3 | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| real | anorm, | ||
| real | rcond, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHECON_3
Download CHECON_3 + dependencies [TGZ] [ZIP] [TXT]
!> CHECON_3 estimates the reciprocal of the condition number (in the !> 1-norm) of a complex Hermitian matrix A using the factorization !> computed by CHETRF_RK or CHETRF_BK: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> An estimate is obtained for norm(inv(A)), and the reciprocal of the !> condition number is computed as RCOND = 1 / (ANORM * norm(inv(A))). !> This routine uses BLAS3 solver CHETRS_3. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are !> stored as an upper or lower triangular matrix: !> = 'U': Upper triangular, form is A = P*U*D*(U**H)*(P**T); !> = 'L': Lower triangular, form is A = P*L*D*(L**H)*(P**T). !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> Diagonal of the block diagonal matrix D and factors U or L !> as computed by CHETRF_RK and CHETRF_BK: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> should be provided on entry in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | E | !> E is COMPLEX array, dimension (N) !> On entry, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i),i=2:N, E(1) not referenced; !> If UPLO = 'L': E(i) = D(i+1,i),i=1:N-1, E(N) not referenced. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is not referenced in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_RK or CHETRF_BK. !> |
| [in] | ANORM | !> ANORM is REAL !> The 1-norm of the original matrix A. !> |
| [out] | RCOND | !> RCOND is REAL !> The reciprocal of the condition number of the matrix A, !> computed as RCOND = 1/(ANORM * AINVNM), where AINVNM is an !> estimate of the 1-norm of inv(A) computed in this routine. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> June 2017, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 164 of file checon_3.f.
| subroutine checon_rook | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| real | anorm, | ||
| real | rcond, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHECON_ROOK estimates the reciprocal of the condition number fort HE matrices using factorization obtained with one of the bounded diagonal pivoting methods (max 2 interchanges)
Download CHECON_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CHECON_ROOK estimates the reciprocal of the condition number of a complex !> Hermitian matrix A using the factorization A = U*D*U**H or !> A = L*D*L**H computed by CHETRF_ROOK. !> !> An estimate is obtained for norm(inv(A)), and the reciprocal of the !> condition number is computed as RCOND = 1 / (ANORM * norm(inv(A))). !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF_ROOK. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_ROOK. !> |
| [in] | ANORM | !> ANORM is REAL !> The 1-norm of the original matrix A. !> |
| [out] | RCOND | !> RCOND is REAL !> The reciprocal of the condition number of the matrix A, !> computed as RCOND = 1/(ANORM * AINVNM), where AINVNM is an !> estimate of the 1-norm of inv(A) computed in this routine. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> December 2016, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 137 of file checon_rook.f.
| subroutine cheequb | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| real, dimension( * ) | s, | ||
| real | scond, | ||
| real | amax, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHEEQUB
Download CHEEQUB + dependencies [TGZ] [ZIP] [TXT]
!> !> CHEEQUB computes row and column scalings intended to equilibrate a !> Hermitian matrix A (with respect to the Euclidean norm) and reduce !> its condition number. The scale factors S are computed by the BIN !> algorithm (see references) so that the scaled matrix B with elements !> B(i,j) = S(i)*A(i,j)*S(j) has a condition number within a factor N of !> the smallest possible condition number over all possible diagonal !> scalings. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The N-by-N Hermitian matrix whose scaling factors are to be !> computed. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | S | !> S is REAL array, dimension (N) !> If INFO = 0, S contains the scale factors for A. !> |
| [out] | SCOND | !> SCOND is REAL !> If INFO = 0, S contains the ratio of the smallest S(i) to !> the largest S(i). If SCOND >= 0.1 and AMAX is neither too !> large nor too small, it is not worth scaling by S. !> |
| [out] | AMAX | !> AMAX is REAL !> Largest absolute value of any matrix element. If AMAX is !> very close to overflow or very close to underflow, the !> matrix should be scaled. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, the i-th diagonal element is nonpositive. !> |
Definition at line 131 of file cheequb.f.
| subroutine chegs2 | ( | integer | itype, |
| character | uplo, | ||
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| integer | info ) |
CHEGS2 reduces a Hermitian definite generalized eigenproblem to standard form, using the factorization results obtained from cpotrf (unblocked algorithm).
Download CHEGS2 + dependencies [TGZ] [ZIP] [TXT]
!> !> CHEGS2 reduces a complex Hermitian-definite generalized !> eigenproblem to standard form. !> !> If ITYPE = 1, the problem is A*x = lambda*B*x, !> and A is overwritten by inv(U**H)*A*inv(U) or inv(L)*A*inv(L**H) !> !> If ITYPE = 2 or 3, the problem is A*B*x = lambda*x or !> B*A*x = lambda*x, and A is overwritten by U*A*U**H or L**H *A*L. !> !> B must have been previously factorized as U**H *U or L*L**H by ZPOTRF. !>
| [in] | ITYPE | !> ITYPE is INTEGER !> = 1: compute inv(U**H)*A*inv(U) or inv(L)*A*inv(L**H); !> = 2 or 3: compute U*A*U**H or L**H *A*L. !> |
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored, and how B has been factorized. !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrices A and B. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n by n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n by n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, if INFO = 0, the transformed matrix, stored in the !> same format as A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,N) !> The triangular factor from the Cholesky factorization of B, !> as returned by CPOTRF. !> B is modified by the routine but restored on exit. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit. !> < 0: if INFO = -i, the i-th argument had an illegal value. !> |
Definition at line 127 of file chegs2.f.
| subroutine chegst | ( | integer | itype, |
| character | uplo, | ||
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| integer | info ) |
CHEGST
Download CHEGST + dependencies [TGZ] [ZIP] [TXT]
!> !> CHEGST reduces a complex Hermitian-definite generalized !> eigenproblem to standard form. !> !> If ITYPE = 1, the problem is A*x = lambda*B*x, !> and A is overwritten by inv(U**H)*A*inv(U) or inv(L)*A*inv(L**H) !> !> If ITYPE = 2 or 3, the problem is A*B*x = lambda*x or !> B*A*x = lambda*x, and A is overwritten by U*A*U**H or L**H*A*L. !> !> B must have been previously factorized as U**H*U or L*L**H by CPOTRF. !>
| [in] | ITYPE | !> ITYPE is INTEGER !> = 1: compute inv(U**H)*A*inv(U) or inv(L)*A*inv(L**H); !> = 2 or 3: compute U*A*U**H or L**H*A*L. !> |
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored and B is factored as !> U**H*U; !> = 'L': Lower triangle of A is stored and B is factored as !> L*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrices A and B. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, if INFO = 0, the transformed matrix, stored in the !> same format as A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,N) !> The triangular factor from the Cholesky factorization of B, !> as returned by CPOTRF. !> B is modified by the routine but restored on exit. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
Definition at line 127 of file chegst.f.
| subroutine cherfs | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| complex, dimension( ldx, * ) | x, | ||
| integer | ldx, | ||
| real, dimension( * ) | ferr, | ||
| real, dimension( * ) | berr, | ||
| complex, dimension( * ) | work, | ||
| real, dimension( * ) | rwork, | ||
| integer | info ) |
CHERFS
Download CHERFS + dependencies [TGZ] [ZIP] [TXT]
!> !> CHERFS improves the computed solution to a system of linear !> equations when the coefficient matrix is Hermitian indefinite, and !> provides error bounds and backward error estimates for the solution. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrices B and X. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The Hermitian matrix A. If UPLO = 'U', the leading N-by-N !> upper triangular part of A contains the upper triangular part !> of the matrix A, and the strictly lower triangular part of A !> is not referenced. If UPLO = 'L', the leading N-by-N lower !> triangular part of A contains the lower triangular part of !> the matrix A, and the strictly upper triangular part of A is !> not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The factored form of the matrix A. AF contains the block !> diagonal matrix D and the multipliers used to obtain the !> factor U or L from the factorization A = U*D*U**H or !> A = L*D*L**H as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> The right hand side matrix B. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [in,out] | X | !> X is COMPLEX array, dimension (LDX,NRHS) !> On entry, the solution matrix X, as computed by CHETRS. !> On exit, the improved solution matrix X. !> |
| [in] | LDX | !> LDX is INTEGER !> The leading dimension of the array X. LDX >= max(1,N). !> |
| [out] | FERR | !> FERR is REAL array, dimension (NRHS) !> The estimated forward error bound for each solution vector !> X(j) (the j-th column of the solution matrix X). !> If XTRUE is the true solution corresponding to X(j), FERR(j) !> is an estimated upper bound for the magnitude of the largest !> element in (X(j) - XTRUE) divided by the magnitude of the !> largest element in X(j). The estimate is as reliable as !> the estimate for RCOND, and is almost always a slight !> overestimate of the true error. !> |
| [out] | BERR | !> BERR is REAL array, dimension (NRHS) !> The componentwise relative backward error of each solution !> vector X(j) (i.e., the smallest relative change in !> any element of A or B that makes X(j) an exact solution). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | RWORK | !> RWORK is REAL array, dimension (N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> ITMAX is the maximum number of steps of iterative refinement. !>
Definition at line 190 of file cherfs.f.
| subroutine cherfsx | ( | character | uplo, |
| character | equed, | ||
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| real, dimension( * ) | s, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| complex, dimension( ldx, * ) | x, | ||
| integer | ldx, | ||
| real | rcond, | ||
| real, dimension( * ) | berr, | ||
| integer | n_err_bnds, | ||
| real, dimension( nrhs, * ) | err_bnds_norm, | ||
| real, dimension( nrhs, * ) | err_bnds_comp, | ||
| integer | nparams, | ||
| real, dimension( * ) | params, | ||
| complex, dimension( * ) | work, | ||
| real, dimension( * ) | rwork, | ||
| integer | info ) |
CHERFSX
Download CHERFSX + dependencies [TGZ] [ZIP] [TXT]
!> !> CHERFSX improves the computed solution to a system of linear !> equations when the coefficient matrix is Hermitian indefinite, and !> provides error bounds and backward error estimates for the !> solution. In addition to normwise error bound, the code provides !> maximum componentwise error bound if possible. See comments for !> ERR_BNDS_NORM and ERR_BNDS_COMP for details of the error bounds. !> !> The original system of linear equations may have been equilibrated !> before calling this routine, as described by arguments EQUED and S !> below. In this case, the solution and error bounds returned are !> for the original unequilibrated system. !>
!> Some optional parameters are bundled in the PARAMS array. These !> settings determine how refinement is performed, but often the !> defaults are acceptable. If the defaults are acceptable, users !> can pass NPARAMS = 0 which prevents the source code from accessing !> the PARAMS argument. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | EQUED | !> EQUED is CHARACTER*1 !> Specifies the form of equilibration that was done to A !> before calling this routine. This is needed to compute !> the solution and error bounds correctly. !> = 'N': No equilibration !> = 'Y': Both row and column equilibration, i.e., A has been !> replaced by diag(S) * A * diag(S). !> The right hand side B has been changed accordingly. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrices B and X. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The Hermitian matrix A. If UPLO = 'U', the leading N-by-N !> upper triangular part of A contains the upper triangular !> part of the matrix A, and the strictly lower triangular !> part of A is not referenced. If UPLO = 'L', the leading !> N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The factored form of the matrix A. AF contains the block !> diagonal matrix D and the multipliers used to obtain the !> factor U or L from the factorization A = U*D*U**H or A = !> L*D*L**H as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in,out] | S | !> S is REAL array, dimension (N) !> The scale factors for A. If EQUED = 'Y', A is multiplied on !> the left and right by diag(S). S is an input argument if FACT = !> 'F'; otherwise, S is an output argument. If FACT = 'F' and EQUED !> = 'Y', each element of S must be positive. If S is output, each !> element of S is a power of the radix. If S is input, each element !> of S should be a power of the radix to ensure a reliable solution !> and error estimates. Scaling by powers of the radix does not cause !> rounding errors unless the result underflows or overflows. !> Rounding errors during scaling lead to refining with a matrix that !> is not equivalent to the input matrix, producing error estimates !> that may not be reliable. !> |
| [in] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> The right hand side matrix B. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [in,out] | X | !> X is COMPLEX array, dimension (LDX,NRHS) !> On entry, the solution matrix X, as computed by CHETRS. !> On exit, the improved solution matrix X. !> |
| [in] | LDX | !> LDX is INTEGER !> The leading dimension of the array X. LDX >= max(1,N). !> |
| [out] | RCOND | !> RCOND is REAL !> Reciprocal scaled condition number. This is an estimate of the !> reciprocal Skeel condition number of the matrix A after !> equilibration (if done). If this is less than the machine !> precision (in particular, if it is zero), the matrix is singular !> to working precision. Note that the error may still be small even !> if this number is very small and the matrix appears ill- !> conditioned. !> |
| [out] | BERR | !> BERR is REAL array, dimension (NRHS) !> Componentwise relative backward error. This is the !> componentwise relative backward error of each solution vector X(j) !> (i.e., the smallest relative change in any element of A or B that !> makes X(j) an exact solution). !> |
| [in] | N_ERR_BNDS | !> N_ERR_BNDS is INTEGER !> Number of error bounds to return for each right hand side !> and each type (normwise or componentwise). See ERR_BNDS_NORM and !> ERR_BNDS_COMP below. !> |
| [out] | ERR_BNDS_NORM | !> ERR_BNDS_NORM is REAL array, dimension (NRHS, N_ERR_BNDS)
!> For each right-hand side, this array contains information about
!> various error bounds and condition numbers corresponding to the
!> normwise relative error, which is defined as follows:
!>
!> Normwise relative error in the ith solution vector:
!> max_j (abs(XTRUE(j,i) - X(j,i)))
!> ------------------------------
!> max_j abs(X(j,i))
!>
!> The array is indexed by the type of error information as described
!> below. There currently are up to three pieces of information
!> returned.
!>
!> The first index in ERR_BNDS_NORM(i,:) corresponds to the ith
!> right-hand side.
!>
!> The second index in ERR_BNDS_NORM(:,err) contains the following
!> three fields:
!> err = 1 boolean. Trust the answer if the
!> reciprocal condition number is less than the threshold
!> sqrt(n) * slamch('Epsilon').
!>
!> err = 2 error bound: The estimated forward error,
!> almost certainly within a factor of 10 of the true error
!> so long as the next entry is greater than the threshold
!> sqrt(n) * slamch('Epsilon'). This error bound should only
!> be trusted if the previous boolean is true.
!>
!> err = 3 Reciprocal condition number: Estimated normwise
!> reciprocal condition number. Compared with the threshold
!> sqrt(n) * slamch('Epsilon') to determine if the error
!> estimate is . These reciprocal condition
!> numbers are 1 / (norm(Z^{-1},inf) * norm(Z,inf)) for some
!> appropriately scaled matrix Z.
!> Let Z = S*A, where S scales each row by a power of the
!> radix so all absolute row sums of Z are approximately 1.
!>
!> See Lapack Working Note 165 for further details and extra
!> cautions.
!> |
| [out] | ERR_BNDS_COMP | !> ERR_BNDS_COMP is REAL array, dimension (NRHS, N_ERR_BNDS)
!> For each right-hand side, this array contains information about
!> various error bounds and condition numbers corresponding to the
!> componentwise relative error, which is defined as follows:
!>
!> Componentwise relative error in the ith solution vector:
!> abs(XTRUE(j,i) - X(j,i))
!> max_j ----------------------
!> abs(X(j,i))
!>
!> The array is indexed by the right-hand side i (on which the
!> componentwise relative error depends), and the type of error
!> information as described below. There currently are up to three
!> pieces of information returned for each right-hand side. If
!> componentwise accuracy is not requested (PARAMS(3) = 0.0), then
!> ERR_BNDS_COMP is not accessed. If N_ERR_BNDS < 3, then at most
!> the first (:,N_ERR_BNDS) entries are returned.
!>
!> The first index in ERR_BNDS_COMP(i,:) corresponds to the ith
!> right-hand side.
!>
!> The second index in ERR_BNDS_COMP(:,err) contains the following
!> three fields:
!> err = 1 boolean. Trust the answer if the
!> reciprocal condition number is less than the threshold
!> sqrt(n) * slamch('Epsilon').
!>
!> err = 2 error bound: The estimated forward error,
!> almost certainly within a factor of 10 of the true error
!> so long as the next entry is greater than the threshold
!> sqrt(n) * slamch('Epsilon'). This error bound should only
!> be trusted if the previous boolean is true.
!>
!> err = 3 Reciprocal condition number: Estimated componentwise
!> reciprocal condition number. Compared with the threshold
!> sqrt(n) * slamch('Epsilon') to determine if the error
!> estimate is . These reciprocal condition
!> numbers are 1 / (norm(Z^{-1},inf) * norm(Z,inf)) for some
!> appropriately scaled matrix Z.
!> Let Z = S*(A*diag(x)), where x is the solution for the
!> current right-hand side and S scales each row of
!> A*diag(x) by a power of the radix so all absolute row
!> sums of Z are approximately 1.
!>
!> See Lapack Working Note 165 for further details and extra
!> cautions.
!> |
| [in] | NPARAMS | !> NPARAMS is INTEGER !> Specifies the number of parameters set in PARAMS. If <= 0, the !> PARAMS array is never referenced and default values are used. !> |
| [in,out] | PARAMS | !> PARAMS is REAL array, dimension NPARAMS !> Specifies algorithm parameters. If an entry is < 0.0, then !> that entry will be filled with default value used for that !> parameter. Only positions up to NPARAMS are accessed; defaults !> are used for higher-numbered parameters. !> !> PARAMS(LA_LINRX_ITREF_I = 1) : Whether to perform iterative !> refinement or not. !> Default: 1.0 !> = 0.0: No refinement is performed, and no error bounds are !> computed. !> = 1.0: Use the double-precision refinement algorithm, !> possibly with doubled-single computations if the !> compilation environment does not support DOUBLE !> PRECISION. !> (other values are reserved for future use) !> !> PARAMS(LA_LINRX_ITHRESH_I = 2) : Maximum number of residual !> computations allowed for refinement. !> Default: 10 !> Aggressive: Set to 100 to permit convergence using approximate !> factorizations or factorizations other than LU. If !> the factorization uses a technique other than !> Gaussian elimination, the guarantees in !> err_bnds_norm and err_bnds_comp may no longer be !> trustworthy. !> !> PARAMS(LA_LINRX_CWISE_I = 3) : Flag determining if the code !> will attempt to find a solution with small componentwise !> relative error in the double-precision algorithm. Positive !> is true, 0.0 is false. !> Default: 1.0 (attempt componentwise convergence) !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N) !> |
| [out] | RWORK | !> RWORK is REAL array, dimension (2*N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: Successful exit. The solution to every right-hand side is !> guaranteed. !> < 0: If INFO = -i, the i-th argument had an illegal value !> > 0 and <= N: U(INFO,INFO) is exactly zero. The factorization !> has been completed, but the factor U is exactly singular, so !> the solution and error bounds could not be computed. RCOND = 0 !> is returned. !> = N+J: The solution corresponding to the Jth right-hand side is !> not guaranteed. The solutions corresponding to other right- !> hand sides K with K > J may not be guaranteed as well, but !> only the first such right-hand side is reported. If a small !> componentwise error is not requested (PARAMS(3) = 0.0) then !> the Jth right-hand side is the first with a normwise error !> bound that is not guaranteed (the smallest J such !> that ERR_BNDS_NORM(J,1) = 0.0). By default (PARAMS(3) = 1.0) !> the Jth right-hand side is the first with either a normwise or !> componentwise error bound that is not guaranteed (the smallest !> J such that either ERR_BNDS_NORM(J,1) = 0.0 or !> ERR_BNDS_COMP(J,1) = 0.0). See the definition of !> ERR_BNDS_NORM(:,1) and ERR_BNDS_COMP(:,1). To get information !> about all of the right-hand sides check ERR_BNDS_NORM or !> ERR_BNDS_COMP. !> |
Definition at line 397 of file cherfsx.f.
| subroutine chetd2 | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| real, dimension( * ) | d, | ||
| real, dimension( * ) | e, | ||
| complex, dimension( * ) | tau, | ||
| integer | info ) |
CHETD2 reduces a Hermitian matrix to real symmetric tridiagonal form by an unitary similarity transformation (unblocked algorithm).
Download CHETD2 + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETD2 reduces a complex Hermitian matrix A to real symmetric !> tridiagonal form T by a unitary similarity transformation: !> Q**H * A * Q = T. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n-by-n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n-by-n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, if UPLO = 'U', the diagonal and first superdiagonal !> of A are overwritten by the corresponding elements of the !> tridiagonal matrix T, and the elements above the first !> superdiagonal, with the array TAU, represent the unitary !> matrix Q as a product of elementary reflectors; if UPLO !> = 'L', the diagonal and first subdiagonal of A are over- !> written by the corresponding elements of the tridiagonal !> matrix T, and the elements below the first subdiagonal, with !> the array TAU, represent the unitary matrix Q as a product !> of elementary reflectors. See Further Details. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | D | !> D is REAL array, dimension (N) !> The diagonal elements of the tridiagonal matrix T: !> D(i) = A(i,i). !> |
| [out] | E | !> E is REAL array, dimension (N-1) !> The off-diagonal elements of the tridiagonal matrix T: !> E(i) = A(i,i+1) if UPLO = 'U', E(i) = A(i+1,i) if UPLO = 'L'. !> |
| [out] | TAU | !> TAU is COMPLEX array, dimension (N-1) !> The scalar factors of the elementary reflectors (see Further !> Details). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value. !> |
!> !> If UPLO = 'U', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(n-1) . . . H(2) H(1). !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(i+1:n) = 0 and v(i) = 1; v(1:i-1) is stored on exit in !> A(1:i-1,i+1), and tau in TAU(i). !> !> If UPLO = 'L', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(1) H(2) . . . H(n-1). !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(1:i) = 0 and v(i+1) = 1; v(i+2:n) is stored on exit in A(i+2:n,i), !> and tau in TAU(i). !> !> The contents of A on exit are illustrated by the following examples !> with n = 5: !> !> if UPLO = 'U': if UPLO = 'L': !> !> ( d e v2 v3 v4 ) ( d ) !> ( d e v3 v4 ) ( e d ) !> ( d e v4 ) ( v1 e d ) !> ( d e ) ( v1 v2 e d ) !> ( d ) ( v1 v2 v3 e d ) !> !> where d and e denote diagonal and off-diagonal elements of T, and vi !> denotes an element of the vector defining H(i). !>
Definition at line 174 of file chetd2.f.
| subroutine chetf2 | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| integer | info ) |
CHETF2 computes the factorization of a complex Hermitian matrix, using the diagonal pivoting method (unblocked algorithm calling Level 2 BLAS).
Download CHETF2 + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETF2 computes the factorization of a complex Hermitian matrix A !> using the Bunch-Kaufman diagonal pivoting method: !> !> A = U*D*U**H or A = L*D*L**H !> !> where U (or L) is a product of permutation and unit upper (lower) !> triangular matrices, U**H is the conjugate transpose of U, and D is !> Hermitian and block diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the unblocked version of the algorithm, calling Level 2 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n-by-n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n-by-n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, the block diagonal matrix D and the multipliers used !> to obtain the factor U or L (see below for further details). !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> !> If UPLO = 'U': !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) = IPIV(k-1) < 0, then rows and columns !> k-1 and -IPIV(k) were interchanged and D(k-1:k,k-1:k) !> is a 2-by-2 diagonal block. !> !> If UPLO = 'L': !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) = IPIV(k+1) < 0, then rows and columns !> k+1 and -IPIV(k) were interchanged and D(k:k+1,k:k+1) !> is a 2-by-2 diagonal block. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -k, the k-th argument had an illegal value !> > 0: if INFO = k, D(k,k) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if it !> is used to solve a system of equations. !> |
!> !> 09-29-06 - patch from !> Bobby Cheng, MathWorks !> !> Replace l.210 and l.392 !> IF( MAX( ABSAKK, COLMAX ).EQ.ZERO ) THEN !> by !> IF( (MAX( ABSAKK, COLMAX ).EQ.ZERO) .OR. SISNAN(ABSAKK) ) THEN !> !> 01-01-96 - Based on modifications by !> J. Lewis, Boeing Computer Services Company !> A. Petitet, Computer Science Dept., Univ. of Tenn., Knoxville, USA !> !> If UPLO = 'U', then A = U*D*U**H, where !> U = P(n)*U(n)* ... *P(k)U(k)* ..., !> i.e., U is a product of terms P(k)*U(k), where k decreases from n to !> 1 in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and U(k) is a unit upper triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I v 0 ) k-s !> U(k) = ( 0 I 0 ) s !> ( 0 0 I ) n-k !> k-s s n-k !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(1:k-1,k). !> If s = 2, the upper triangle of D(k) overwrites A(k-1,k-1), A(k-1,k), !> and A(k,k), and v overwrites A(1:k-2,k-1:k). !> !> If UPLO = 'L', then A = L*D*L**H, where !> L = P(1)*L(1)* ... *P(k)*L(k)* ..., !> i.e., L is a product of terms P(k)*L(k), where k increases from 1 to !> n in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and L(k) is a unit lower triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I 0 0 ) k-1 !> L(k) = ( 0 I 0 ) s !> ( 0 v I ) n-k-s+1 !> k-1 s n-k-s+1 !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(k+1:n,k). !> If s = 2, the lower triangle of D(k) overwrites A(k,k), A(k+1,k), !> and A(k+1,k+1), and v overwrites A(k+2:n,k:k+1). !>
Definition at line 185 of file chetf2.f.
| subroutine chetf2_rk | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| integer | info ) |
CHETF2_RK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman (rook) diagonal pivoting method (BLAS2 unblocked algorithm).
Download CHETF2_RK + dependencies [TGZ] [ZIP] [TXT]
!> CHETF2_RK computes the factorization of a complex Hermitian matrix A !> using the bounded Bunch-Kaufman (rook) diagonal pivoting method: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the unblocked version of the algorithm, calling Level 2 BLAS. !> For more information see Further Details section. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. !> If UPLO = 'U': the leading N-by-N upper triangular part !> of A contains the upper triangular part of the matrix A, !> and the strictly lower triangular part of A is not !> referenced. !> !> If UPLO = 'L': the leading N-by-N lower triangular part !> of A contains the lower triangular part of the matrix A, !> and the strictly upper triangular part of A is not !> referenced. !> !> On exit, contains: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> are stored on exit in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | E | !> E is COMPLEX array, dimension (N) !> On exit, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i), i=2:N, E(1) is set to 0; !> If UPLO = 'L': E(i) = D(i+1,i), i=1:N-1, E(N) is set to 0. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is set to 0 in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> IPIV describes the permutation matrix P in the factorization !> of matrix A as follows. The absolute value of IPIV(k) !> represents the index of row and column that were !> interchanged with the k-th row and column. The value of UPLO !> describes the order in which the interchanges were applied. !> Also, the sign of IPIV represents the block structure of !> the Hermitian block diagonal matrix D with 1-by-1 or 2-by-2 !> diagonal blocks which correspond to 1 or 2 interchanges !> at each factorization step. For more info see Further !> Details section. !> !> If UPLO = 'U', !> ( in factorization order, k decreases from N to 1 ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the matrix A(1:N,1:N); !> If IPIV(k) = k, no interchange occurred. !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k-1) < 0 means: !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k-1) != k-1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k-1) = k-1, no interchange occurred. !> !> c) In both cases a) and b), always ABS( IPIV(k) ) <= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> !> If UPLO = 'L', !> ( in factorization order, k increases from 1 to N ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the matrix A(1:N,1:N). !> If IPIV(k) = k, no interchange occurred. !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k+1) < 0 means: !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k+1) != k+1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k+1) = k+1, no interchange occurred. !> !> c) In both cases a) and b), always ABS( IPIV(k) ) >= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> !> < 0: If INFO = -k, the k-th argument had an illegal value !> !> > 0: If INFO = k, the matrix A is singular, because: !> If UPLO = 'U': column k in the upper !> triangular part of A contains all zeros. !> If UPLO = 'L': column k in the lower !> triangular part of A contains all zeros. !> !> Therefore D(k,k) is exactly zero, and superdiagonal !> elements of column k of U (or subdiagonal elements of !> column k of L ) are all zeros. The factorization has !> been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if !> it is used to solve a system of equations. !> !> NOTE: INFO only stores the first occurrence of !> a singularity, any subsequent occurrence of singularity !> is not stored in INFO even though the factorization !> always completes. !> |
!> TODO: put further details !>
!> !> December 2016, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !> 01-01-96 - Based on modifications by !> J. Lewis, Boeing Computer Services Company !> A. Petitet, Computer Science Dept., !> Univ. of Tenn., Knoxville abd , USA !>
Definition at line 240 of file chetf2_rk.f.
| subroutine chetf2_rook | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| integer | info ) |
CHETF2_ROOK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman ("rook") diagonal pivoting method (unblocked algorithm).
Download CHETF2_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETF2_ROOK computes the factorization of a complex Hermitian matrix A !> using the bounded Bunch-Kaufman () diagonal pivoting method: !> !> A = U*D*U**H or A = L*D*L**H !> !> where U (or L) is a product of permutation and unit upper (lower) !> triangular matrices, U**H is the conjugate transpose of U, and D is !> Hermitian and block diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the unblocked version of the algorithm, calling Level 2 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n-by-n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n-by-n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, the block diagonal matrix D and the multipliers used !> to obtain the factor U or L (see below for further details). !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> !> If UPLO = 'U': !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k-1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k-1 and -IPIV(k-1) were inerchaged, !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> !> If UPLO = 'L': !> If IPIV(k) > 0, then rows and columns k and IPIV(k) !> were interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k+1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k+1 and -IPIV(k+1) were inerchaged, !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -k, the k-th argument had an illegal value !> > 0: if INFO = k, D(k,k) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if it !> is used to solve a system of equations. !> |
!> !> If UPLO = 'U', then A = U*D*U**H, where !> U = P(n)*U(n)* ... *P(k)U(k)* ..., !> i.e., U is a product of terms P(k)*U(k), where k decreases from n to !> 1 in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and U(k) is a unit upper triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I v 0 ) k-s !> U(k) = ( 0 I 0 ) s !> ( 0 0 I ) n-k !> k-s s n-k !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(1:k-1,k). !> If s = 2, the upper triangle of D(k) overwrites A(k-1,k-1), A(k-1,k), !> and A(k,k), and v overwrites A(1:k-2,k-1:k). !> !> If UPLO = 'L', then A = L*D*L**H, where !> L = P(1)*L(1)* ... *P(k)*L(k)* ..., !> i.e., L is a product of terms P(k)*L(k), where k increases from 1 to !> n in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and L(k) is a unit lower triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I 0 0 ) k-1 !> L(k) = ( 0 I 0 ) s !> ( 0 v I ) n-k-s+1 !> k-1 s n-k-s+1 !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(k+1:n,k). !> If s = 2, the lower triangle of D(k) overwrites A(k,k), A(k+1,k), !> and A(k+1,k+1), and v overwrites A(k+2:n,k:k+1). !>
!> !> November 2013, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !> 01-01-96 - Based on modifications by !> J. Lewis, Boeing Computer Services Company !> A. Petitet, Computer Science Dept., Univ. of Tenn., Knoxville, USA !>
Definition at line 193 of file chetf2_rook.f.
| subroutine chetrd | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| real, dimension( * ) | d, | ||
| real, dimension( * ) | e, | ||
| complex, dimension( * ) | tau, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRD
Download CHETRD + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRD reduces a complex Hermitian matrix A to real symmetric !> tridiagonal form T by a unitary similarity transformation: !> Q**H * A * Q = T. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, if UPLO = 'U', the diagonal and first superdiagonal !> of A are overwritten by the corresponding elements of the !> tridiagonal matrix T, and the elements above the first !> superdiagonal, with the array TAU, represent the unitary !> matrix Q as a product of elementary reflectors; if UPLO !> = 'L', the diagonal and first subdiagonal of A are over- !> written by the corresponding elements of the tridiagonal !> matrix T, and the elements below the first subdiagonal, with !> the array TAU, represent the unitary matrix Q as a product !> of elementary reflectors. See Further Details. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | D | !> D is REAL array, dimension (N) !> The diagonal elements of the tridiagonal matrix T: !> D(i) = A(i,i). !> |
| [out] | E | !> E is REAL array, dimension (N-1) !> The off-diagonal elements of the tridiagonal matrix T: !> E(i) = A(i,i+1) if UPLO = 'U', E(i) = A(i+1,i) if UPLO = 'L'. !> |
| [out] | TAU | !> TAU is COMPLEX array, dimension (N-1) !> The scalar factors of the elementary reflectors (see Further !> Details). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (MAX(1,LWORK)) !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The dimension of the array WORK. LWORK >= 1. !> For optimum performance LWORK >= N*NB, where NB is the !> optimal blocksize. !> !> If LWORK = -1, then a workspace query is assumed; the routine !> only calculates the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, and no error !> message related to LWORK is issued by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> If UPLO = 'U', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(n-1) . . . H(2) H(1). !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(i+1:n) = 0 and v(i) = 1; v(1:i-1) is stored on exit in !> A(1:i-1,i+1), and tau in TAU(i). !> !> If UPLO = 'L', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(1) H(2) . . . H(n-1). !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(1:i) = 0 and v(i+1) = 1; v(i+2:n) is stored on exit in A(i+2:n,i), !> and tau in TAU(i). !> !> The contents of A on exit are illustrated by the following examples !> with n = 5: !> !> if UPLO = 'U': if UPLO = 'L': !> !> ( d e v2 v3 v4 ) ( d ) !> ( d e v3 v4 ) ( e d ) !> ( d e v4 ) ( v1 e d ) !> ( d e ) ( v1 v2 e d ) !> ( d ) ( v1 v2 v3 e d ) !> !> where d and e denote diagonal and off-diagonal elements of T, and vi !> denotes an element of the vector defining H(i). !>
Definition at line 191 of file chetrd.f.
| subroutine chetrd_2stage | ( | character | vect, |
| character | uplo, | ||
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| real, dimension( * ) | d, | ||
| real, dimension( * ) | e, | ||
| complex, dimension( * ) | tau, | ||
| complex, dimension( * ) | hous2, | ||
| integer | lhous2, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRD_2STAGE
Download CHETRD_2STAGE + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRD_2STAGE reduces a complex Hermitian matrix A to real symmetric !> tridiagonal form T by a unitary similarity transformation: !> Q1**H Q2**H* A * Q2 * Q1 = T. !>
| [in] | VECT | !> VECT is CHARACTER*1 !> = 'N': No need for the Housholder representation, !> in particular for the second stage (Band to !> tridiagonal) and thus LHOUS2 is of size max(1, 4*N); !> = 'V': the Householder representation is needed to !> either generate Q1 Q2 or to apply Q1 Q2, !> then LHOUS2 is to be queried and computed. !> (NOT AVAILABLE IN THIS RELEASE). !> |
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, if UPLO = 'U', the band superdiagonal !> of A are overwritten by the corresponding elements of the !> internal band-diagonal matrix AB, and the elements above !> the KD superdiagonal, with the array TAU, represent the unitary !> matrix Q1 as a product of elementary reflectors; if UPLO !> = 'L', the diagonal and band subdiagonal of A are over- !> written by the corresponding elements of the internal band-diagonal !> matrix AB, and the elements below the KD subdiagonal, with !> the array TAU, represent the unitary matrix Q1 as a product !> of elementary reflectors. See Further Details. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | D | !> D is REAL array, dimension (N) !> The diagonal elements of the tridiagonal matrix T. !> |
| [out] | E | !> E is REAL array, dimension (N-1) !> The off-diagonal elements of the tridiagonal matrix T. !> |
| [out] | TAU | !> TAU is COMPLEX array, dimension (N-KD) !> The scalar factors of the elementary reflectors of !> the first stage (see Further Details). !> |
| [out] | HOUS2 | !> HOUS2 is COMPLEX array, dimension (LHOUS2) !> Stores the Householder representation of the stage2 !> band to tridiagonal. !> |
| [in] | LHOUS2 | !> LHOUS2 is INTEGER !> The dimension of the array HOUS2. !> If LWORK = -1, or LHOUS2=-1, !> then a query is assumed; the routine !> only calculates the optimal size of the HOUS2 array, returns !> this value as the first entry of the HOUS2 array, and no error !> message related to LHOUS2 is issued by XERBLA. !> If VECT='N', LHOUS2 = max(1, 4*n); !> if VECT='V', option not yet available. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (LWORK) !> |
| [in] | LWORK | !> LWORK is INTEGER !> The dimension of the array WORK. LWORK = MAX(1, dimension) !> If LWORK = -1, or LHOUS2 = -1, !> then a workspace query is assumed; the routine !> only calculates the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, and no error !> message related to LWORK is issued by XERBLA. !> LWORK = MAX(1, dimension) where !> dimension = max(stage1,stage2) + (KD+1)*N !> = N*KD + N*max(KD+1,FACTOPTNB) !> + max(2*KD*KD, KD*NTHREADS) !> + (KD+1)*N !> where KD is the blocking size of the reduction, !> FACTOPTNB is the blocking used by the QR or LQ !> algorithm, usually FACTOPTNB=128 is a good choice !> NTHREADS is the number of threads used when !> openMP compilation is enabled, otherwise =1. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> Implemented by Azzam Haidar. !> !> All details are available on technical report, SC11, SC13 papers. !> !> Azzam Haidar, Hatem Ltaief, and Jack Dongarra. !> Parallel reduction to condensed forms for symmetric eigenvalue problems !> using aggregated fine-grained and memory-aware kernels. In Proceedings !> of 2011 International Conference for High Performance Computing, !> Networking, Storage and Analysis (SC '11), New York, NY, USA, !> Article 8 , 11 pages. !> http://doi.acm.org/10.1145/2063384.2063394 !> !> A. Haidar, J. Kurzak, P. Luszczek, 2013. !> An improved parallel singular value algorithm and its implementation !> for multicore hardware, In Proceedings of 2013 International Conference !> for High Performance Computing, Networking, Storage and Analysis (SC '13). !> Denver, Colorado, USA, 2013. !> Article 90, 12 pages. !> http://doi.acm.org/10.1145/2503210.2503292 !> !> A. Haidar, R. Solca, S. Tomov, T. Schulthess and J. Dongarra. !> A novel hybrid CPU-GPU generalized eigensolver for electronic structure !> calculations based on fine-grained memory aware tasks. !> International Journal of High Performance Computing Applications. !> Volume 28 Issue 2, Pages 196-209, May 2014. !> http://hpc.sagepub.com/content/28/2/196 !> !>
Definition at line 222 of file chetrd_2stage.f.
| subroutine chetrd_he2hb | ( | character | uplo, |
| integer | n, | ||
| integer | kd, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldab, * ) | ab, | ||
| integer | ldab, | ||
| complex, dimension( * ) | tau, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRD_HE2HB
Download CHETRD_HE2HB + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRD_HE2HB reduces a complex Hermitian matrix A to complex Hermitian !> band-diagonal form AB by a unitary similarity transformation: !> Q**H * A * Q = AB. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | KD | !> KD is INTEGER !> The number of superdiagonals of the reduced matrix if UPLO = 'U', !> or the number of subdiagonals if UPLO = 'L'. KD >= 0. !> The reduced matrix is stored in the array AB. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, if UPLO = 'U', the diagonal and first superdiagonal !> of A are overwritten by the corresponding elements of the !> tridiagonal matrix T, and the elements above the first !> superdiagonal, with the array TAU, represent the unitary !> matrix Q as a product of elementary reflectors; if UPLO !> = 'L', the diagonal and first subdiagonal of A are over- !> written by the corresponding elements of the tridiagonal !> matrix T, and the elements below the first subdiagonal, with !> the array TAU, represent the unitary matrix Q as a product !> of elementary reflectors. See Further Details. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | AB | !> AB is COMPLEX array, dimension (LDAB,N) !> On exit, the upper or lower triangle of the Hermitian band !> matrix A, stored in the first KD+1 rows of the array. The !> j-th column of A is stored in the j-th column of the array AB !> as follows: !> if UPLO = 'U', AB(kd+1+i-j,j) = A(i,j) for max(1,j-kd)<=i<=j; !> if UPLO = 'L', AB(1+i-j,j) = A(i,j) for j<=i<=min(n,j+kd). !> |
| [in] | LDAB | !> LDAB is INTEGER !> The leading dimension of the array AB. LDAB >= KD+1. !> |
| [out] | TAU | !> TAU is COMPLEX array, dimension (N-KD) !> The scalar factors of the elementary reflectors (see Further !> Details). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (LWORK) !> On exit, if INFO = 0, or if LWORK=-1, !> WORK(1) returns the size of LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The dimension of the array WORK which should be calculated !> by a workspace query. LWORK = MAX(1, LWORK_QUERY) !> If LWORK = -1, then a workspace query is assumed; the routine !> only calculates the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, and no error !> message related to LWORK is issued by XERBLA. !> LWORK_QUERY = N*KD + N*max(KD,FACTOPTNB) + 2*KD*KD !> where FACTOPTNB is the blocking used by the QR or LQ !> algorithm, usually FACTOPTNB=128 is a good choice otherwise !> putting LWORK=-1 will provide the size of WORK. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> Implemented by Azzam Haidar. !> !> All details are available on technical report, SC11, SC13 papers. !> !> Azzam Haidar, Hatem Ltaief, and Jack Dongarra. !> Parallel reduction to condensed forms for symmetric eigenvalue problems !> using aggregated fine-grained and memory-aware kernels. In Proceedings !> of 2011 International Conference for High Performance Computing, !> Networking, Storage and Analysis (SC '11), New York, NY, USA, !> Article 8 , 11 pages. !> http://doi.acm.org/10.1145/2063384.2063394 !> !> A. Haidar, J. Kurzak, P. Luszczek, 2013. !> An improved parallel singular value algorithm and its implementation !> for multicore hardware, In Proceedings of 2013 International Conference !> for High Performance Computing, Networking, Storage and Analysis (SC '13). !> Denver, Colorado, USA, 2013. !> Article 90, 12 pages. !> http://doi.acm.org/10.1145/2503210.2503292 !> !> A. Haidar, R. Solca, S. Tomov, T. Schulthess and J. Dongarra. !> A novel hybrid CPU-GPU generalized eigensolver for electronic structure !> calculations based on fine-grained memory aware tasks. !> International Journal of High Performance Computing Applications. !> Volume 28 Issue 2, Pages 196-209, May 2014. !> http://hpc.sagepub.com/content/28/2/196 !> !>
!> !> If UPLO = 'U', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(k)**H . . . H(2)**H H(1)**H, where k = n-kd. !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(1:i+kd-1) = 0 and v(i+kd) = 1; conjg(v(i+kd+1:n)) is stored on exit in !> A(i,i+kd+1:n), and tau in TAU(i). !> !> If UPLO = 'L', the matrix Q is represented as a product of elementary !> reflectors !> !> Q = H(1) H(2) . . . H(k), where k = n-kd. !> !> Each H(i) has the form !> !> H(i) = I - tau * v * v**H !> !> where tau is a complex scalar, and v is a complex vector with !> v(kd+1:i) = 0 and v(i+kd+1) = 1; v(i+kd+2:n) is stored on exit in !> A(i+kd+2:n,i), and tau in TAU(i). !> !> The contents of A on exit are illustrated by the following examples !> with n = 5: !> !> if UPLO = 'U': if UPLO = 'L': !> !> ( ab ab/v1 v1 v1 v1 ) ( ab ) !> ( ab ab/v2 v2 v2 ) ( ab/v1 ab ) !> ( ab ab/v3 v3 ) ( v1 ab/v2 ab ) !> ( ab ab/v4 ) ( v1 v2 ab/v3 ab ) !> ( ab ) ( v1 v2 v3 ab/v4 ab ) !> !> where d and e denote diagonal and off-diagonal elements of T, and vi !> denotes an element of the vector defining H(i). !>
Definition at line 241 of file chetrd_he2hb.f.
| subroutine chetrf | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRF
Download CHETRF + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRF computes the factorization of a complex Hermitian matrix A !> using the Bunch-Kaufman diagonal pivoting method. The form of the !> factorization is !> !> A = U*D*U**H or A = L*D*L**H !> !> where U (or L) is a product of permutation and unit upper (lower) !> triangular matrices, and D is Hermitian and block diagonal with !> 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the blocked version of the algorithm, calling Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, the block diagonal matrix D and the multipliers used !> to obtain the factor U or L (see below for further details). !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> If UPLO = 'U' and IPIV(k) = IPIV(k-1) < 0, then rows and !> columns k-1 and -IPIV(k) were interchanged and D(k-1:k,k-1:k) !> is a 2-by-2 diagonal block. If UPLO = 'L' and IPIV(k) = !> IPIV(k+1) < 0, then rows and columns k+1 and -IPIV(k) were !> interchanged and D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (MAX(1,LWORK)) !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The length of WORK. LWORK >=1. For best performance !> LWORK >= N*NB, where NB is the block size returned by ILAENV. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if it !> is used to solve a system of equations. !> |
!> !> If UPLO = 'U', then A = U*D*U**H, where !> U = P(n)*U(n)* ... *P(k)U(k)* ..., !> i.e., U is a product of terms P(k)*U(k), where k decreases from n to !> 1 in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and U(k) is a unit upper triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I v 0 ) k-s !> U(k) = ( 0 I 0 ) s !> ( 0 0 I ) n-k !> k-s s n-k !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(1:k-1,k). !> If s = 2, the upper triangle of D(k) overwrites A(k-1,k-1), A(k-1,k), !> and A(k,k), and v overwrites A(1:k-2,k-1:k). !> !> If UPLO = 'L', then A = L*D*L**H, where !> L = P(1)*L(1)* ... *P(k)*L(k)* ..., !> i.e., L is a product of terms P(k)*L(k), where k increases from 1 to !> n in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and L(k) is a unit lower triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I 0 0 ) k-1 !> L(k) = ( 0 I 0 ) s !> ( 0 v I ) n-k-s+1 !> k-1 s n-k-s+1 !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(k+1:n,k). !> If s = 2, the lower triangle of D(k) overwrites A(k,k), A(k+1,k), !> and A(k+1,k+1), and v overwrites A(k+2:n,k:k+1). !>
Definition at line 176 of file chetrf.f.
| subroutine chetrf_aa | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRF_AA
Download CHETRF_AA + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRF_AA computes the factorization of a complex hermitian matrix A !> using the Aasen's algorithm. The form of the factorization is !> !> A = U**H*T*U or A = L*T*L**H !> !> where U (or L) is a product of permutation and unit upper (lower) !> triangular matrices, and T is a hermitian tridiagonal matrix. !> !> This is the blocked version of the algorithm, calling Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, the tridiagonal matrix is stored in the diagonals !> and the subdiagonals of A just below (or above) the diagonals, !> and L is stored below (or above) the subdiaonals, when UPLO !> is 'L' (or 'U'). !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> On exit, it contains the details of the interchanges, i.e., !> the row and column k of A were interchanged with the !> row and column IPIV(k). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (MAX(1,LWORK)) !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The length of WORK. LWORK >= 2*N. For optimum performance !> LWORK >= N*(1+NB), where NB is the optimal blocksize. !> !> If LWORK = -1, then a workspace query is assumed; the routine !> only calculates the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, and no error !> message related to LWORK is issued by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value. !> |
Definition at line 131 of file chetrf_aa.f.
| subroutine chetrf_rk | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRF_RK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman (rook) diagonal pivoting method (BLAS3 blocked algorithm).
Download CHETRF_RK + dependencies [TGZ] [ZIP] [TXT]
!> CHETRF_RK computes the factorization of a complex Hermitian matrix A !> using the bounded Bunch-Kaufman (rook) diagonal pivoting method: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the blocked version of the algorithm, calling Level 3 BLAS. !> For more information see Further Details section. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. !> If UPLO = 'U': the leading N-by-N upper triangular part !> of A contains the upper triangular part of the matrix A, !> and the strictly lower triangular part of A is not !> referenced. !> !> If UPLO = 'L': the leading N-by-N lower triangular part !> of A contains the lower triangular part of the matrix A, !> and the strictly upper triangular part of A is not !> referenced. !> !> On exit, contains: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> are stored on exit in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | E | !> E is COMPLEX array, dimension (N) !> On exit, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i), i=2:N, E(1) is set to 0; !> If UPLO = 'L': E(i) = D(i+1,i), i=1:N-1, E(N) is set to 0. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is set to 0 in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> IPIV describes the permutation matrix P in the factorization !> of matrix A as follows. The absolute value of IPIV(k) !> represents the index of row and column that were !> interchanged with the k-th row and column. The value of UPLO !> describes the order in which the interchanges were applied. !> Also, the sign of IPIV represents the block structure of !> the Hermitian block diagonal matrix D with 1-by-1 or 2-by-2 !> diagonal blocks which correspond to 1 or 2 interchanges !> at each factorization step. For more info see Further !> Details section. !> !> If UPLO = 'U', !> ( in factorization order, k decreases from N to 1 ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the matrix A(1:N,1:N); !> If IPIV(k) = k, no interchange occurred. !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k-1) < 0 means: !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k-1) != k-1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k-1) = k-1, no interchange occurred. !> !> c) In both cases a) and b), always ABS( IPIV(k) ) <= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> !> If UPLO = 'L', !> ( in factorization order, k increases from 1 to N ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the matrix A(1:N,1:N). !> If IPIV(k) = k, no interchange occurred. !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k+1) < 0 means: !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k+1) != k+1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the matrix A(1:N,1:N). !> If -IPIV(k+1) = k+1, no interchange occurred. !> !> c) In both cases a) and b), always ABS( IPIV(k) ) >= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension ( MAX(1,LWORK) ). !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The length of WORK. LWORK >=1. For best performance !> LWORK >= N*NB, where NB is the block size returned !> by ILAENV. !> !> If LWORK = -1, then a workspace query is assumed; !> the routine only calculates the optimal size of the WORK !> array, returns this value as the first entry of the WORK !> array, and no error message related to LWORK is issued !> by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> !> < 0: If INFO = -k, the k-th argument had an illegal value !> !> > 0: If INFO = k, the matrix A is singular, because: !> If UPLO = 'U': column k in the upper !> triangular part of A contains all zeros. !> If UPLO = 'L': column k in the lower !> triangular part of A contains all zeros. !> !> Therefore D(k,k) is exactly zero, and superdiagonal !> elements of column k of U (or subdiagonal elements of !> column k of L ) are all zeros. The factorization has !> been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if !> it is used to solve a system of equations. !> !> NOTE: INFO only stores the first occurrence of !> a singularity, any subsequent occurrence of singularity !> is not stored in INFO even though the factorization !> always completes. !> |
!> TODO: put correct description !>
!> !> December 2016, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 257 of file chetrf_rk.f.
| subroutine chetrf_rook | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRF_ROOK computes the factorization of a complex Hermitian indefinite matrix using the bounded Bunch-Kaufman ("rook") diagonal pivoting method (blocked algorithm, calling Level 3 BLAS).
Download CHETRF_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRF_ROOK computes the factorization of a complex Hermitian matrix A !> using the bounded Bunch-Kaufman () diagonal pivoting method. !> The form of the factorization is !> !> A = U*D*U**T or A = L*D*L**T !> !> where U (or L) is a product of permutation and unit upper (lower) !> triangular matrices, and D is Hermitian and block diagonal with !> 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the blocked version of the algorithm, calling Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> N-by-N upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading N-by-N lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> !> On exit, the block diagonal matrix D and the multipliers used !> to obtain the factor U or L (see below for further details). !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> !> If UPLO = 'U': !> Only the last KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k-1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k-1 and -IPIV(k-1) were inerchaged, !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> !> If UPLO = 'L': !> Only the first KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) !> were interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k+1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k+1 and -IPIV(k+1) were inerchaged, !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (MAX(1,LWORK)). !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The length of WORK. LWORK >=1. For best performance !> LWORK >= N*NB, where NB is the block size returned by ILAENV. !> !> If LWORK = -1, then a workspace query is assumed; the routine !> only calculates the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, and no error !> message related to LWORK is issued by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if it !> is used to solve a system of equations. !> |
!> !> If UPLO = 'U', then A = U*D*U**T, where !> U = P(n)*U(n)* ... *P(k)U(k)* ..., !> i.e., U is a product of terms P(k)*U(k), where k decreases from n to !> 1 in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and U(k) is a unit upper triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I v 0 ) k-s !> U(k) = ( 0 I 0 ) s !> ( 0 0 I ) n-k !> k-s s n-k !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(1:k-1,k). !> If s = 2, the upper triangle of D(k) overwrites A(k-1,k-1), A(k-1,k), !> and A(k,k), and v overwrites A(1:k-2,k-1:k). !> !> If UPLO = 'L', then A = L*D*L**T, where !> L = P(1)*L(1)* ... *P(k)*L(k)* ..., !> i.e., L is a product of terms P(k)*L(k), where k increases from 1 to !> n in steps of 1 or 2, and D is a block diagonal matrix with 1-by-1 !> and 2-by-2 diagonal blocks D(k). P(k) is a permutation matrix as !> defined by IPIV(k), and L(k) is a unit lower triangular matrix, such !> that if the diagonal block D(k) is of order s (s = 1 or 2), then !> !> ( I 0 0 ) k-1 !> L(k) = ( 0 I 0 ) s !> ( 0 v I ) n-k-s+1 !> k-1 s n-k-s+1 !> !> If s = 1, D(k) overwrites A(k,k), and v overwrites A(k+1:n,k). !> If s = 2, the lower triangle of D(k) overwrites A(k,k), A(k+1,k), !> and A(k+1,k+1), and v overwrites A(k+2:n,k:k+1). !>
!> !> June 2016, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 211 of file chetrf_rook.f.
| subroutine chetri | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHETRI
Download CHETRI + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRI computes the inverse of a complex Hermitian indefinite matrix !> A using the factorization A = U*D*U**H or A = L*D*L**H computed by !> CHETRF. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the block diagonal matrix D and the multipliers !> used to obtain the factor U or L as computed by CHETRF. !> !> On exit, if INFO = 0, the (Hermitian) inverse of the original !> matrix. If UPLO = 'U', the upper triangular part of the !> inverse is formed and the part of A below the diagonal is not !> referenced; if UPLO = 'L' the lower triangular part of the !> inverse is formed and the part of A above the diagonal is !> not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
Definition at line 113 of file chetri.f.
| subroutine chetri2 | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRI2
Download CHETRI2 + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRI2 computes the inverse of a COMPLEX hermitian indefinite matrix !> A using the factorization A = U*D*U**T or A = L*D*L**T computed by !> CHETRF. CHETRI2 set the LEADING DIMENSION of the workspace !> before calling CHETRI2X that actually computes the inverse. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**T; !> = 'L': Lower triangular, form is A = L*D*L**T. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the block diagonal matrix D and the multipliers !> used to obtain the factor U or L as computed by CHETRF. !> !> On exit, if INFO = 0, the (symmetric) inverse of the original !> matrix. If UPLO = 'U', the upper triangular part of the !> inverse is formed and the part of A below the diagonal is not !> referenced; if UPLO = 'L' the lower triangular part of the !> inverse is formed and the part of A above the diagonal is !> not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N+NB+1)*(NB+3) !> |
| [in] | LWORK | !> LWORK is INTEGER !> The dimension of the array WORK. !> WORK is size >= (N+NB+1)*(NB+3) !> If LWORK = -1, then a workspace query is assumed; the routine !> calculates: !> - the optimal size of the WORK array, returns !> this value as the first entry of the WORK array, !> - and no error message related to LWORK is issued by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
Definition at line 126 of file chetri2.f.
| subroutine chetri2x | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( n+nb+1,* ) | work, | ||
| integer | nb, | ||
| integer | info ) |
CHETRI2X
Download CHETRI2X + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRI2X computes the inverse of a complex Hermitian indefinite matrix !> A using the factorization A = U*D*U**H or A = L*D*L**H computed by !> CHETRF. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the NNB diagonal matrix D and the multipliers !> used to obtain the factor U or L as computed by CHETRF. !> !> On exit, if INFO = 0, the (symmetric) inverse of the original !> matrix. If UPLO = 'U', the upper triangular part of the !> inverse is formed and the part of A below the diagonal is not !> referenced; if UPLO = 'L' the lower triangular part of the !> inverse is formed and the part of A above the diagonal is !> not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the NNB structure of D !> as determined by CHETRF. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N+NB+1,NB+3) !> |
| [in] | NB | !> NB is INTEGER !> Block size !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
Definition at line 119 of file chetri2x.f.
| subroutine chetri_3 | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRI_3
Download CHETRI_3 + dependencies [TGZ] [ZIP] [TXT]
!> CHETRI_3 computes the inverse of a complex Hermitian indefinite !> matrix A using the factorization computed by CHETRF_RK or CHETRF_BK: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> CHETRI_3 sets the leading dimension of the workspace before calling !> CHETRI_3X that actually computes the inverse. This is the blocked !> version of the algorithm, calling Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are !> stored as an upper or lower triangular matrix. !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, diagonal of the block diagonal matrix D and !> factors U or L as computed by CHETRF_RK and CHETRF_BK: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> should be provided on entry in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> !> On exit, if INFO = 0, the Hermitian inverse of the original !> matrix. !> If UPLO = 'U': the upper triangular part of the inverse !> is formed and the part of A below the diagonal is not !> referenced; !> If UPLO = 'L': the lower triangular part of the inverse !> is formed and the part of A above the diagonal is not !> referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | E | !> E is COMPLEX array, dimension (N) !> On entry, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i),i=2:N, E(1) not referenced; !> If UPLO = 'L': E(i) = D(i+1,i),i=1:N-1, E(N) not referenced. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is not referenced in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_RK or CHETRF_BK. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N+NB+1)*(NB+3). !> On exit, if INFO = 0, WORK(1) returns the optimal LWORK. !> |
| [in] | LWORK | !> LWORK is INTEGER !> The length of WORK. LWORK >= (N+NB+1)*(NB+3). !> !> If LDWORK = -1, then a workspace query is assumed; !> the routine only calculates the optimal size of the optimal !> size of the WORK array, returns this value as the first !> entry of the WORK array, and no error message related to !> LWORK is issued by XERBLA. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
!> !> November 2017, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !>
Definition at line 168 of file chetri_3.f.
| subroutine chetri_3x | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( n+nb+1, * ) | work, | ||
| integer | nb, | ||
| integer | info ) |
CHETRI_3X
Download CHETRI_3X + dependencies [TGZ] [ZIP] [TXT]
!> CHETRI_3X computes the inverse of a complex Hermitian indefinite !> matrix A using the factorization computed by CHETRF_RK or CHETRF_BK: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This is the blocked version of the algorithm, calling Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are !> stored as an upper or lower triangular matrix. !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, diagonal of the block diagonal matrix D and !> factors U or L as computed by CHETRF_RK and CHETRF_BK: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> should be provided on entry in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> !> On exit, if INFO = 0, the Hermitian inverse of the original !> matrix. !> If UPLO = 'U': the upper triangular part of the inverse !> is formed and the part of A below the diagonal is not !> referenced; !> If UPLO = 'L': the lower triangular part of the inverse !> is formed and the part of A above the diagonal is not !> referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | E | !> E is COMPLEX array, dimension (N) !> On entry, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i), i=2:N, E(1) not referenced; !> If UPLO = 'L': E(i) = D(i+1,i), i=1:N-1, E(N) not referenced. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is not referenced in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_RK or CHETRF_BK. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N+NB+1,NB+3). !> |
| [in] | NB | !> NB is INTEGER !> Block size. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
!> !> June 2017, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !>
Definition at line 158 of file chetri_3x.f.
| subroutine chetri_rook | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHETRI_ROOK computes the inverse of HE matrix using the factorization obtained with the bounded Bunch-Kaufman ("rook") diagonal pivoting method.
Download CHETRI_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRI_ROOK computes the inverse of a complex Hermitian indefinite matrix !> A using the factorization A = U*D*U**H or A = L*D*L**H computed by !> CHETRF_ROOK. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the block diagonal matrix D and the multipliers !> used to obtain the factor U or L as computed by CHETRF_ROOK. !> !> On exit, if INFO = 0, the (Hermitian) inverse of the original !> matrix. If UPLO = 'U', the upper triangular part of the !> inverse is formed and the part of A below the diagonal is not !> referenced; if UPLO = 'L' the lower triangular part of the !> inverse is formed and the part of A above the diagonal is !> not referenced. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_ROOK. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its !> inverse could not be computed. !> |
!> !> November 2013, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !>
Definition at line 127 of file chetri_rook.f.
| subroutine chetrs | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| integer | info ) |
CHETRS
Download CHETRS + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRS solves a system of linear equations A*X = B with a complex !> Hermitian matrix A using the factorization A = U*D*U**H or !> A = L*D*L**H computed by CHETRF. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrix B. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> On entry, the right hand side matrix B. !> On exit, the solution matrix X. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
Definition at line 119 of file chetrs.f.
| subroutine chetrs2 | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| complex, dimension( * ) | work, | ||
| integer | info ) |
CHETRS2
Download CHETRS2 + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRS2 solves a system of linear equations A*X = B with a complex !> Hermitian matrix A using the factorization A = U*D*U**H or !> A = L*D*L**H computed by CHETRF and converted by CSYCONV. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrix B. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> On entry, the right hand side matrix B. !> On exit, the solution matrix X. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (N) !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
Definition at line 125 of file chetrs2.f.
| subroutine chetrs_3 | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| integer | info ) |
CHETRS_3
Download CHETRS_3 + dependencies [TGZ] [ZIP] [TXT]
!> CHETRS_3 solves a system of linear equations A * X = B with a complex !> Hermitian matrix A using the factorization computed !> by CHETRF_RK or CHETRF_BK: !> !> A = P*U*D*(U**H)*(P**T) or A = P*L*D*(L**H)*(P**T), !> !> where U (or L) is unit upper (or lower) triangular matrix, !> U**H (or L**H) is the conjugate of U (or L), P is a permutation !> matrix, P**T is the transpose of P, and D is Hermitian and block !> diagonal with 1-by-1 and 2-by-2 diagonal blocks. !> !> This algorithm is using Level 3 BLAS. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are !> stored as an upper or lower triangular matrix: !> = 'U': Upper triangular, form is A = P*U*D*(U**H)*(P**T); !> = 'L': Lower triangular, form is A = P*L*D*(L**H)*(P**T). !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrix B. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> Diagonal of the block diagonal matrix D and factors U or L !> as computed by CHETRF_RK and CHETRF_BK: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> should be provided on entry in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | E | !> E is COMPLEX array, dimension (N) !> On entry, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i),i=2:N, E(1) not referenced; !> If UPLO = 'L': E(i) = D(i+1,i),i=1:N-1, E(N) not referenced. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is not referenced in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_RK or CHETRF_BK. !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> On entry, the right hand side matrix B. !> On exit, the solution matrix X. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> June 2017, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 163 of file chetrs_3.f.
| subroutine chetrs_aa | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| complex, dimension( * ) | work, | ||
| integer | lwork, | ||
| integer | info ) |
CHETRS_AA
Download CHETRS_AA + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRS_AA solves a system of linear equations A*X = B with a complex !> hermitian matrix A using the factorization A = U**H*T*U or !> A = L*T*L**H computed by CHETRF_AA. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U**H*T*U; !> = 'L': Lower triangular, form is A = L*T*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrix B. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> Details of factors computed by CHETRF_AA. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges as computed by CHETRF_AA. !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> On entry, the right hand side matrix B. !> On exit, the solution matrix X. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (MAX(1,LWORK)) !> |
| [in] | LWORK | !> LWORK is INTEGER !> The dimension of the array WORK. LWORK >= max(1,3*N-2). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
Definition at line 129 of file chetrs_aa.f.
| subroutine chetrs_rook | ( | character | uplo, |
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| integer | info ) |
CHETRS_ROOK computes the solution to a system of linear equations A * X = B for HE matrices using factorization obtained with one of the bounded diagonal pivoting methods (max 2 interchanges)
Download CHETRS_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CHETRS_ROOK solves a system of linear equations A*X = B with a complex !> Hermitian matrix A using the factorization A = U*D*U**H or !> A = L*D*L**H computed by CHETRF_ROOK. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the details of the factorization are stored !> as an upper or lower triangular matrix. !> = 'U': Upper triangular, form is A = U*D*U**H; !> = 'L': Lower triangular, form is A = L*D*L**H. !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right hand sides, i.e., the number of columns !> of the matrix B. NRHS >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF_ROOK. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF_ROOK. !> |
| [in,out] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> On entry, the right hand side matrix B. !> On exit, the solution matrix X. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> < 0: if INFO = -i, the i-th argument had an illegal value !> |
!> !> November 2013, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 134 of file chetrs_rook.f.
| subroutine cla_heamv | ( | integer | uplo, |
| integer | n, | ||
| real | alpha, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | x, | ||
| integer | incx, | ||
| real | beta, | ||
| real, dimension( * ) | y, | ||
| integer | incy ) |
CLA_HEAMV computes a matrix-vector product using a Hermitian indefinite matrix to calculate error bounds.
Download CLA_HEAMV + dependencies [TGZ] [ZIP] [TXT]
!> !> CLA_SYAMV performs the matrix-vector operation !> !> y := alpha*abs(A)*abs(x) + beta*abs(y), !> !> where alpha and beta are scalars, x and y are vectors and A is an !> n by n symmetric matrix. !> !> This function is primarily used in calculating error bounds. !> To protect against underflow during evaluation, components in !> the resulting vector are perturbed away from zero by (N+1) !> times the underflow threshold. To prevent unnecessarily large !> errors for block-structure embedded in general matrices, !> zero components are not perturbed. A zero !> entry is considered if all multiplications involved !> in computing that entry have at least one zero multiplicand. !>
| [in] | UPLO | !> UPLO is INTEGER !> On entry, UPLO specifies whether the upper or lower !> triangular part of the array A is to be referenced as !> follows: !> !> UPLO = BLAS_UPPER Only the upper triangular part of A !> is to be referenced. !> !> UPLO = BLAS_LOWER Only the lower triangular part of A !> is to be referenced. !> !> Unchanged on exit. !> |
| [in] | N | !> N is INTEGER !> On entry, N specifies the number of columns of the matrix A. !> N must be at least zero. !> Unchanged on exit. !> |
| [in] | ALPHA | !> ALPHA is REAL . !> On entry, ALPHA specifies the scalar alpha. !> Unchanged on exit. !> |
| [in] | A | !> A is COMPLEX array, dimension ( LDA, n ). !> Before entry, the leading m by n part of the array A must !> contain the matrix of coefficients. !> Unchanged on exit. !> |
| [in] | LDA | !> LDA is INTEGER !> On entry, LDA specifies the first dimension of A as declared !> in the calling (sub) program. LDA must be at least !> max( 1, n ). !> Unchanged on exit. !> |
| [in] | X | !> X is COMPLEX array, dimension !> ( 1 + ( n - 1 )*abs( INCX ) ) !> Before entry, the incremented array X must contain the !> vector x. !> Unchanged on exit. !> |
| [in] | INCX | !> INCX is INTEGER !> On entry, INCX specifies the increment for the elements of !> X. INCX must not be zero. !> Unchanged on exit. !> |
| [in] | BETA | !> BETA is REAL . !> On entry, BETA specifies the scalar beta. When BETA is !> supplied as zero then Y need not be set on input. !> Unchanged on exit. !> |
| [in,out] | Y | !> Y is REAL array, dimension !> ( 1 + ( n - 1 )*abs( INCY ) ) !> Before entry with BETA non-zero, the incremented array Y !> must contain the vector y. On exit, Y is overwritten by the !> updated vector y. !> |
| [in] | INCY | !> INCY is INTEGER !> On entry, INCY specifies the increment for the elements of !> Y. INCY must not be zero. !> Unchanged on exit. !> |
!> !> Level 2 Blas routine. !> !> -- Written on 22-October-1986. !> Jack Dongarra, Argonne National Lab. !> Jeremy Du Croz, Nag Central Office. !> Sven Hammarling, Nag Central Office. !> Richard Hanson, Sandia National Labs. !> -- Modified for the absolute-value product, April 2006 !> Jason Riedy, UC Berkeley !>
Definition at line 176 of file cla_heamv.f.
| real function cla_hercond_c | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| real, dimension ( * ) | c, | ||
| logical | capply, | ||
| integer | info, | ||
| complex, dimension( * ) | work, | ||
| real, dimension( * ) | rwork ) |
CLA_HERCOND_C computes the infinity norm condition number of op(A)*inv(diag(c)) for Hermitian indefinite matrices.
Download CLA_HERCOND_C + dependencies [TGZ] [ZIP] [TXT]
!> !> CLA_HERCOND_C computes the infinity norm condition number of !> op(A) * inv(diag(C)) where C is a REAL vector. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The number of linear equations, i.e., the order of the !> matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the N-by-N matrix A !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in] | C | !> C is REAL array, dimension (N) !> The vector C in the formula op(A) * inv(diag(C)). !> |
| [in] | CAPPLY | !> CAPPLY is LOGICAL !> If .TRUE. then access the vector C in the formula above. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: Successful exit. !> i > 0: The ith argument is invalid. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N). !> Workspace. !> |
| [out] | RWORK | !> RWORK is REAL array, dimension (N). !> Workspace. !> |
Definition at line 136 of file cla_hercond_c.f.
| real function cla_hercond_x | ( | character | uplo, |
| integer | n, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( * ) | x, | ||
| integer | info, | ||
| complex, dimension( * ) | work, | ||
| real, dimension( * ) | rwork ) |
CLA_HERCOND_X computes the infinity norm condition number of op(A)*diag(x) for Hermitian indefinite matrices.
Download CLA_HERCOND_X + dependencies [TGZ] [ZIP] [TXT]
!> !> CLA_HERCOND_X computes the infinity norm condition number of !> op(A) * diag(X) where X is a COMPLEX vector. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The number of linear equations, i.e., the order of the !> matrix A. N >= 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the N-by-N matrix A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in] | X | !> X is COMPLEX array, dimension (N) !> The vector X in the formula op(A) * diag(X). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: Successful exit. !> i > 0: The ith argument is invalid. !> |
| [out] | WORK | !> WORK is COMPLEX array, dimension (2*N). !> Workspace. !> |
| [out] | RWORK | !> RWORK is REAL array, dimension (N). !> Workspace. !> |
Definition at line 129 of file cla_hercond_x.f.
| subroutine cla_herfsx_extended | ( | integer | prec_type, |
| character | uplo, | ||
| integer | n, | ||
| integer | nrhs, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| logical | colequ, | ||
| real, dimension( * ) | c, | ||
| complex, dimension( ldb, * ) | b, | ||
| integer | ldb, | ||
| complex, dimension( ldy, * ) | y, | ||
| integer | ldy, | ||
| real, dimension( * ) | berr_out, | ||
| integer | n_norms, | ||
| real, dimension( nrhs, * ) | err_bnds_norm, | ||
| real, dimension( nrhs, * ) | err_bnds_comp, | ||
| complex, dimension( * ) | res, | ||
| real, dimension( * ) | ayb, | ||
| complex, dimension( * ) | dy, | ||
| complex, dimension( * ) | y_tail, | ||
| real | rcond, | ||
| integer | ithresh, | ||
| real | rthresh, | ||
| real | dz_ub, | ||
| logical | ignore_cwise, | ||
| integer | info ) |
CLA_HERFSX_EXTENDED improves the computed solution to a system of linear equations for Hermitian indefinite matrices by performing extra-precise iterative refinement and provides error bounds and backward error estimates for the solution.
Download CLA_HERFSX_EXTENDED + dependencies [TGZ] [ZIP] [TXT]
!> !> CLA_HERFSX_EXTENDED improves the computed solution to a system of !> linear equations by performing extra-precise iterative refinement !> and provides error bounds and backward error estimates for the solution. !> This subroutine is called by CHERFSX to perform iterative refinement. !> In addition to normwise error bound, the code provides maximum !> componentwise error bound if possible. See comments for ERR_BNDS_NORM !> and ERR_BNDS_COMP for details of the error bounds. Note that this !> subroutine is only responsible for setting the second fields of !> ERR_BNDS_NORM and ERR_BNDS_COMP. !>
| [in] | PREC_TYPE | !> PREC_TYPE is INTEGER !> Specifies the intermediate precision to be used in refinement. !> The value is defined by ILAPREC(P) where P is a CHARACTER and P !> = 'S': Single !> = 'D': Double !> = 'I': Indigenous !> = 'X' or 'E': Extra !> |
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The number of linear equations, i.e., the order of the !> matrix A. N >= 0. !> |
| [in] | NRHS | !> NRHS is INTEGER !> The number of right-hand-sides, i.e., the number of columns of the !> matrix B. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the N-by-N matrix A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [in] | COLEQU | !> COLEQU is LOGICAL !> If .TRUE. then column equilibration was done to A before calling !> this routine. This is needed to compute the solution and error !> bounds correctly. !> |
| [in] | C | !> C is REAL array, dimension (N) !> The column scale factors for A. If COLEQU = .FALSE., C !> is not accessed. If C is input, each element of C should be a power !> of the radix to ensure a reliable solution and error estimates. !> Scaling by powers of the radix does not cause rounding errors unless !> the result underflows or overflows. Rounding errors during scaling !> lead to refining with a matrix that is not equivalent to the !> input matrix, producing error estimates that may not be !> reliable. !> |
| [in] | B | !> B is COMPLEX array, dimension (LDB,NRHS) !> The right-hand-side matrix B. !> |
| [in] | LDB | !> LDB is INTEGER !> The leading dimension of the array B. LDB >= max(1,N). !> |
| [in,out] | Y | !> Y is COMPLEX array, dimension (LDY,NRHS) !> On entry, the solution matrix X, as computed by CHETRS. !> On exit, the improved solution matrix Y. !> |
| [in] | LDY | !> LDY is INTEGER !> The leading dimension of the array Y. LDY >= max(1,N). !> |
| [out] | BERR_OUT | !> BERR_OUT is REAL array, dimension (NRHS) !> On exit, BERR_OUT(j) contains the componentwise relative backward !> error for right-hand-side j from the formula !> max(i) ( abs(RES(i)) / ( abs(op(A_s))*abs(Y) + abs(B_s) )(i) ) !> where abs(Z) is the componentwise absolute value of the matrix !> or vector Z. This is computed by CLA_LIN_BERR. !> |
| [in] | N_NORMS | !> N_NORMS is INTEGER !> Determines which error bounds to return (see ERR_BNDS_NORM !> and ERR_BNDS_COMP). !> If N_NORMS >= 1 return normwise error bounds. !> If N_NORMS >= 2 return componentwise error bounds. !> |
| [in,out] | ERR_BNDS_NORM | !> ERR_BNDS_NORM is REAL array, dimension (NRHS, N_ERR_BNDS)
!> For each right-hand side, this array contains information about
!> various error bounds and condition numbers corresponding to the
!> normwise relative error, which is defined as follows:
!>
!> Normwise relative error in the ith solution vector:
!> max_j (abs(XTRUE(j,i) - X(j,i)))
!> ------------------------------
!> max_j abs(X(j,i))
!>
!> The array is indexed by the type of error information as described
!> below. There currently are up to three pieces of information
!> returned.
!>
!> The first index in ERR_BNDS_NORM(i,:) corresponds to the ith
!> right-hand side.
!>
!> The second index in ERR_BNDS_NORM(:,err) contains the following
!> three fields:
!> err = 1 boolean. Trust the answer if the
!> reciprocal condition number is less than the threshold
!> sqrt(n) * slamch('Epsilon').
!>
!> err = 2 error bound: The estimated forward error,
!> almost certainly within a factor of 10 of the true error
!> so long as the next entry is greater than the threshold
!> sqrt(n) * slamch('Epsilon'). This error bound should only
!> be trusted if the previous boolean is true.
!>
!> err = 3 Reciprocal condition number: Estimated normwise
!> reciprocal condition number. Compared with the threshold
!> sqrt(n) * slamch('Epsilon') to determine if the error
!> estimate is . These reciprocal condition
!> numbers are 1 / (norm(Z^{-1},inf) * norm(Z,inf)) for some
!> appropriately scaled matrix Z.
!> Let Z = S*A, where S scales each row by a power of the
!> radix so all absolute row sums of Z are approximately 1.
!>
!> This subroutine is only responsible for setting the second field
!> above.
!> See Lapack Working Note 165 for further details and extra
!> cautions.
!> |
| [in,out] | ERR_BNDS_COMP | !> ERR_BNDS_COMP is REAL array, dimension (NRHS, N_ERR_BNDS)
!> For each right-hand side, this array contains information about
!> various error bounds and condition numbers corresponding to the
!> componentwise relative error, which is defined as follows:
!>
!> Componentwise relative error in the ith solution vector:
!> abs(XTRUE(j,i) - X(j,i))
!> max_j ----------------------
!> abs(X(j,i))
!>
!> The array is indexed by the right-hand side i (on which the
!> componentwise relative error depends), and the type of error
!> information as described below. There currently are up to three
!> pieces of information returned for each right-hand side. If
!> componentwise accuracy is not requested (PARAMS(3) = 0.0), then
!> ERR_BNDS_COMP is not accessed. If N_ERR_BNDS < 3, then at most
!> the first (:,N_ERR_BNDS) entries are returned.
!>
!> The first index in ERR_BNDS_COMP(i,:) corresponds to the ith
!> right-hand side.
!>
!> The second index in ERR_BNDS_COMP(:,err) contains the following
!> three fields:
!> err = 1 boolean. Trust the answer if the
!> reciprocal condition number is less than the threshold
!> sqrt(n) * slamch('Epsilon').
!>
!> err = 2 error bound: The estimated forward error,
!> almost certainly within a factor of 10 of the true error
!> so long as the next entry is greater than the threshold
!> sqrt(n) * slamch('Epsilon'). This error bound should only
!> be trusted if the previous boolean is true.
!>
!> err = 3 Reciprocal condition number: Estimated componentwise
!> reciprocal condition number. Compared with the threshold
!> sqrt(n) * slamch('Epsilon') to determine if the error
!> estimate is . These reciprocal condition
!> numbers are 1 / (norm(Z^{-1},inf) * norm(Z,inf)) for some
!> appropriately scaled matrix Z.
!> Let Z = S*(A*diag(x)), where x is the solution for the
!> current right-hand side and S scales each row of
!> A*diag(x) by a power of the radix so all absolute row
!> sums of Z are approximately 1.
!>
!> This subroutine is only responsible for setting the second field
!> above.
!> See Lapack Working Note 165 for further details and extra
!> cautions.
!> |
| [in] | RES | !> RES is COMPLEX array, dimension (N) !> Workspace to hold the intermediate residual. !> |
| [in] | AYB | !> AYB is REAL array, dimension (N) !> Workspace. !> |
| [in] | DY | !> DY is COMPLEX array, dimension (N) !> Workspace to hold the intermediate solution. !> |
| [in] | Y_TAIL | !> Y_TAIL is COMPLEX array, dimension (N) !> Workspace to hold the trailing bits of the intermediate solution. !> |
| [in] | RCOND | !> RCOND is REAL !> Reciprocal scaled condition number. This is an estimate of the !> reciprocal Skeel condition number of the matrix A after !> equilibration (if done). If this is less than the machine !> precision (in particular, if it is zero), the matrix is singular !> to working precision. Note that the error may still be small even !> if this number is very small and the matrix appears ill- !> conditioned. !> |
| [in] | ITHRESH | !> ITHRESH is INTEGER !> The maximum number of residual computations allowed for !> refinement. The default is 10. For 'aggressive' set to 100 to !> permit convergence using approximate factorizations or !> factorizations other than LU. If the factorization uses a !> technique other than Gaussian elimination, the guarantees in !> ERR_BNDS_NORM and ERR_BNDS_COMP may no longer be trustworthy. !> |
| [in] | RTHRESH | !> RTHRESH is REAL
!> Determines when to stop refinement if the error estimate stops
!> decreasing. Refinement will stop when the next solution no longer
!> satisfies norm(dx_{i+1}) < RTHRESH * norm(dx_i) where norm(Z) is
!> the infinity norm of Z. RTHRESH satisfies 0 < RTHRESH <= 1. The
!> default value is 0.5. For 'aggressive' set to 0.9 to permit
!> convergence on extremely ill-conditioned matrices. See LAWN 165
!> for more details.
!> |
| [in] | DZ_UB | !> DZ_UB is REAL !> Determines when to start considering componentwise convergence. !> Componentwise convergence is only considered after each component !> of the solution Y is stable, which we define as the relative !> change in each component being less than DZ_UB. The default value !> is 0.25, requiring the first bit to be stable. See LAWN 165 for !> more details. !> |
| [in] | IGNORE_CWISE | !> IGNORE_CWISE is LOGICAL !> If .TRUE. then ignore componentwise convergence. Default value !> is .FALSE.. !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: Successful exit. !> < 0: if INFO = -i, the ith argument to CLA_HERFSX_EXTENDED had an illegal !> value !> |
Definition at line 388 of file cla_herfsx_extended.f.
| real function cla_herpvgrw | ( | character*1 | uplo, |
| integer | n, | ||
| integer | info, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( ldaf, * ) | af, | ||
| integer | ldaf, | ||
| integer, dimension( * ) | ipiv, | ||
| real, dimension( * ) | work ) |
CLA_HERPVGRW
Download CLA_HERPVGRW + dependencies [TGZ] [ZIP] [TXT]
!> !> !> CLA_HERPVGRW computes the reciprocal pivot growth factor !> norm(A)/norm(U). The norm is used. If this is !> much less than 1, the stability of the LU factorization of the !> (equilibrated) matrix A could be poor. This also means that the !> solution X, estimated condition numbers, and error bounds could be !> unreliable. !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> = 'U': Upper triangle of A is stored; !> = 'L': Lower triangle of A is stored. !> |
| [in] | N | !> N is INTEGER !> The number of linear equations, i.e., the order of the !> matrix A. N >= 0. !> |
| [in] | INFO | !> INFO is INTEGER !> The value of INFO returned from SSYTRF, .i.e., the pivot in !> column INFO is exactly 0. !> |
| [in] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the N-by-N matrix A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [in] | AF | !> AF is COMPLEX array, dimension (LDAF,N) !> The block diagonal matrix D and the multipliers used to !> obtain the factor U or L as computed by CHETRF. !> |
| [in] | LDAF | !> LDAF is INTEGER !> The leading dimension of the array AF. LDAF >= max(1,N). !> |
| [in] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D !> as determined by CHETRF. !> |
| [out] | WORK | !> WORK is REAL array, dimension (2*N) !> |
Definition at line 121 of file cla_herpvgrw.f.
| subroutine clahef | ( | character | uplo, |
| integer | n, | ||
| integer | nb, | ||
| integer | kb, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldw, * ) | w, | ||
| integer | ldw, | ||
| integer | info ) |
CLAHEF computes a partial factorization of a complex Hermitian indefinite matrix using the Bunch-Kaufman diagonal pivoting method (blocked algorithm, calling Level 3 BLAS).
Download CLAHEF + dependencies [TGZ] [ZIP] [TXT]
!> !> CLAHEF computes a partial factorization of a complex Hermitian !> matrix A using the Bunch-Kaufman diagonal pivoting method. The !> partial factorization has the form: !> !> A = ( I U12 ) ( A11 0 ) ( I 0 ) if UPLO = 'U', or: !> ( 0 U22 ) ( 0 D ) ( U12**H U22**H ) !> !> A = ( L11 0 ) ( D 0 ) ( L11**H L21**H ) if UPLO = 'L' !> ( L21 I ) ( 0 A22 ) ( 0 I ) !> !> where the order of D is at most NB. The actual order is returned in !> the argument KB, and is either NB or NB-1, or N if N <= NB. !> Note that U**H denotes the conjugate transpose of U. !> !> CLAHEF is an auxiliary routine called by CHETRF. It uses blocked code !> (calling Level 3 BLAS) to update the submatrix A11 (if UPLO = 'U') or !> A22 (if UPLO = 'L'). !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NB | !> NB is INTEGER !> The maximum number of columns of the matrix A that should be !> factored. NB should be at least 2 to allow for 2-by-2 pivot !> blocks. !> |
| [out] | KB | !> KB is INTEGER !> The number of columns of A that were actually factored. !> KB is either NB-1 or NB, or N if N <= NB. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n-by-n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n-by-n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, A contains details of the partial factorization. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> !> If UPLO = 'U': !> Only the last KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) = IPIV(k-1) < 0, then rows and columns !> k-1 and -IPIV(k) were interchanged and D(k-1:k,k-1:k) !> is a 2-by-2 diagonal block. !> !> If UPLO = 'L': !> Only the first KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) = IPIV(k+1) < 0, then rows and columns !> k+1 and -IPIV(k) were interchanged and D(k:k+1,k:k+1) !> is a 2-by-2 diagonal block. !> |
| [out] | W | !> W is COMPLEX array, dimension (LDW,NB) !> |
| [in] | LDW | !> LDW is INTEGER !> The leading dimension of the array W. LDW >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> > 0: if INFO = k, D(k,k) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular. !> |
!> !> November 2013, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !>
Definition at line 176 of file clahef.f.
| subroutine clahef_rk | ( | character | uplo, |
| integer | n, | ||
| integer | nb, | ||
| integer | kb, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| complex, dimension( * ) | e, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldw, * ) | w, | ||
| integer | ldw, | ||
| integer | info ) |
CLAHEF_RK computes a partial factorization of a complex Hermitian indefinite matrix using bounded Bunch-Kaufman (rook) diagonal pivoting method.
Download CLAHEF_RK + dependencies [TGZ] [ZIP] [TXT]
!> CLAHEF_RK computes a partial factorization of a complex Hermitian !> matrix A using the bounded Bunch-Kaufman (rook) diagonal !> pivoting method. The partial factorization has the form: !> !> A = ( I U12 ) ( A11 0 ) ( I 0 ) if UPLO = 'U', or: !> ( 0 U22 ) ( 0 D ) ( U12**H U22**H ) !> !> A = ( L11 0 ) ( D 0 ) ( L11**H L21**H ) if UPLO = 'L', !> ( L21 I ) ( 0 A22 ) ( 0 I ) !> !> where the order of D is at most NB. The actual order is returned in !> the argument KB, and is either NB or NB-1, or N if N <= NB. !> !> CLAHEF_RK is an auxiliary routine called by CHETRF_RK. It uses !> blocked code (calling Level 3 BLAS) to update the submatrix !> A11 (if UPLO = 'U') or A22 (if UPLO = 'L'). !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NB | !> NB is INTEGER !> The maximum number of columns of the matrix A that should be !> factored. NB should be at least 2 to allow for 2-by-2 pivot !> blocks. !> |
| [out] | KB | !> KB is INTEGER !> The number of columns of A that were actually factored. !> KB is either NB-1 or NB, or N if N <= NB. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. !> If UPLO = 'U': the leading N-by-N upper triangular part !> of A contains the upper triangular part of the matrix A, !> and the strictly lower triangular part of A is not !> referenced. !> !> If UPLO = 'L': the leading N-by-N lower triangular part !> of A contains the lower triangular part of the matrix A, !> and the strictly upper triangular part of A is not !> referenced. !> !> On exit, contains: !> a) ONLY diagonal elements of the Hermitian block diagonal !> matrix D on the diagonal of A, i.e. D(k,k) = A(k,k); !> (superdiagonal (or subdiagonal) elements of D !> are stored on exit in array E), and !> b) If UPLO = 'U': factor U in the superdiagonal part of A. !> If UPLO = 'L': factor L in the subdiagonal part of A. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | E | !> E is COMPLEX array, dimension (N) !> On exit, contains the superdiagonal (or subdiagonal) !> elements of the Hermitian block diagonal matrix D !> with 1-by-1 or 2-by-2 diagonal blocks, where !> If UPLO = 'U': E(i) = D(i-1,i), i=2:N, E(1) is set to 0; !> If UPLO = 'L': E(i) = D(i+1,i), i=1:N-1, E(N) is set to 0. !> !> NOTE: For 1-by-1 diagonal block D(k), where !> 1 <= k <= N, the element E(k) is set to 0 in both !> UPLO = 'U' or UPLO = 'L' cases. !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> IPIV describes the permutation matrix P in the factorization !> of matrix A as follows. The absolute value of IPIV(k) !> represents the index of row and column that were !> interchanged with the k-th row and column. The value of UPLO !> describes the order in which the interchanges were applied. !> Also, the sign of IPIV represents the block structure of !> the Hermitian block diagonal matrix D with 1-by-1 or 2-by-2 !> diagonal blocks which correspond to 1 or 2 interchanges !> at each factorization step. !> !> If UPLO = 'U', !> ( in factorization order, k decreases from N to 1 ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the submatrix A(1:N,N-KB+1:N); !> If IPIV(k) = k, no interchange occurred. !> !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k-1) < 0 means: !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the matrix A(1:N,N-KB+1:N). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k-1) != k-1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the submatrix A(1:N,N-KB+1:N). !> If -IPIV(k-1) = k-1, no interchange occurred. !> !> c) In both cases a) and b) is always ABS( IPIV(k) ) <= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> !> If UPLO = 'L', !> ( in factorization order, k increases from 1 to N ): !> a) A single positive entry IPIV(k) > 0 means: !> D(k,k) is a 1-by-1 diagonal block. !> If IPIV(k) != k, rows and columns k and IPIV(k) were !> interchanged in the submatrix A(1:N,1:KB). !> If IPIV(k) = k, no interchange occurred. !> !> b) A pair of consecutive negative entries !> IPIV(k) < 0 and IPIV(k+1) < 0 means: !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> (NOTE: negative entries in IPIV appear ONLY in pairs). !> 1) If -IPIV(k) != k, rows and columns !> k and -IPIV(k) were interchanged !> in the submatrix A(1:N,1:KB). !> If -IPIV(k) = k, no interchange occurred. !> 2) If -IPIV(k+1) != k+1, rows and columns !> k-1 and -IPIV(k-1) were interchanged !> in the submatrix A(1:N,1:KB). !> If -IPIV(k+1) = k+1, no interchange occurred. !> !> c) In both cases a) and b) is always ABS( IPIV(k) ) >= k. !> !> d) NOTE: Any entry IPIV(k) is always NONZERO on output. !> |
| [out] | W | !> W is COMPLEX array, dimension (LDW,NB) !> |
| [in] | LDW | !> LDW is INTEGER !> The leading dimension of the array W. LDW >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> !> < 0: If INFO = -k, the k-th argument had an illegal value !> !> > 0: If INFO = k, the matrix A is singular, because: !> If UPLO = 'U': column k in the upper !> triangular part of A contains all zeros. !> If UPLO = 'L': column k in the lower !> triangular part of A contains all zeros. !> !> Therefore D(k,k) is exactly zero, and superdiagonal !> elements of column k of U (or subdiagonal elements of !> column k of L ) are all zeros. The factorization has !> been completed, but the block diagonal matrix D is !> exactly singular, and division by zero will occur if !> it is used to solve a system of equations. !> !> NOTE: INFO only stores the first occurrence of !> a singularity, any subsequent occurrence of singularity !> is not stored in INFO even though the factorization !> always completes. !> |
!> !> December 2016, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !> !>
Definition at line 260 of file clahef_rk.f.
| subroutine clahef_rook | ( | character | uplo, |
| integer | n, | ||
| integer | nb, | ||
| integer | kb, | ||
| complex, dimension( lda, * ) | a, | ||
| integer | lda, | ||
| integer, dimension( * ) | ipiv, | ||
| complex, dimension( ldw, * ) | w, | ||
| integer | ldw, | ||
| integer | info ) |
Download CLAHEF_ROOK + dependencies [TGZ] [ZIP] [TXT]
!> !> CLAHEF_ROOK computes a partial factorization of a complex Hermitian !> matrix A using the bounded Bunch-Kaufman () diagonal pivoting !> method. The partial factorization has the form: !> !> A = ( I U12 ) ( A11 0 ) ( I 0 ) if UPLO = 'U', or: !> ( 0 U22 ) ( 0 D ) ( U12**H U22**H ) !> !> A = ( L11 0 ) ( D 0 ) ( L11**H L21**H ) if UPLO = 'L' !> ( L21 I ) ( 0 A22 ) ( 0 I ) !> !> where the order of D is at most NB. The actual order is returned in !> the argument KB, and is either NB or NB-1, or N if N <= NB. !> Note that U**H denotes the conjugate transpose of U. !> !> CLAHEF_ROOK is an auxiliary routine called by CHETRF_ROOK. It uses !> blocked code (calling Level 3 BLAS) to update the submatrix !> A11 (if UPLO = 'U') or A22 (if UPLO = 'L'). !>
| [in] | UPLO | !> UPLO is CHARACTER*1 !> Specifies whether the upper or lower triangular part of the !> Hermitian matrix A is stored: !> = 'U': Upper triangular !> = 'L': Lower triangular !> |
| [in] | N | !> N is INTEGER !> The order of the matrix A. N >= 0. !> |
| [in] | NB | !> NB is INTEGER !> The maximum number of columns of the matrix A that should be !> factored. NB should be at least 2 to allow for 2-by-2 pivot !> blocks. !> |
| [out] | KB | !> KB is INTEGER !> The number of columns of A that were actually factored. !> KB is either NB-1 or NB, or N if N <= NB. !> |
| [in,out] | A | !> A is COMPLEX array, dimension (LDA,N) !> On entry, the Hermitian matrix A. If UPLO = 'U', the leading !> n-by-n upper triangular part of A contains the upper !> triangular part of the matrix A, and the strictly lower !> triangular part of A is not referenced. If UPLO = 'L', the !> leading n-by-n lower triangular part of A contains the lower !> triangular part of the matrix A, and the strictly upper !> triangular part of A is not referenced. !> On exit, A contains details of the partial factorization. !> |
| [in] | LDA | !> LDA is INTEGER !> The leading dimension of the array A. LDA >= max(1,N). !> |
| [out] | IPIV | !> IPIV is INTEGER array, dimension (N) !> Details of the interchanges and the block structure of D. !> !> If UPLO = 'U': !> Only the last KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) were !> interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k-1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k-1 and -IPIV(k-1) were inerchaged, !> D(k-1:k,k-1:k) is a 2-by-2 diagonal block. !> !> If UPLO = 'L': !> Only the first KB elements of IPIV are set. !> !> If IPIV(k) > 0, then rows and columns k and IPIV(k) !> were interchanged and D(k,k) is a 1-by-1 diagonal block. !> !> If IPIV(k) < 0 and IPIV(k+1) < 0, then rows and !> columns k and -IPIV(k) were interchanged and rows and !> columns k+1 and -IPIV(k+1) were inerchaged, !> D(k:k+1,k:k+1) is a 2-by-2 diagonal block. !> |
| [out] | W | !> W is COMPLEX array, dimension (LDW,NB) !> |
| [in] | LDW | !> LDW is INTEGER !> The leading dimension of the array W. LDW >= max(1,N). !> |
| [out] | INFO | !> INFO is INTEGER !> = 0: successful exit !> > 0: if INFO = k, D(k,k) is exactly zero. The factorization !> has been completed, but the block diagonal matrix D is !> exactly singular. !> |
!> !> November 2013, Igor Kozachenko, !> Computer Science Division, !> University of California, Berkeley !> !> September 2007, Sven Hammarling, Nicholas J. Higham, Craig Lucas, !> School of Mathematics, !> University of Manchester !>
Definition at line 182 of file clahef_rook.f.