pstrf#

Functions

void spstrf(
    const char*          uplo,
    const INT            n,
          f32*  restrict A,
    const INT            lda,
          INT*  restrict piv,
          INT*           rank,
    const f32            tol,
          f32*  restrict work,
          INT*           info
);
void spstrf(const char *uplo, const INT n, f32 *restrict A, const INT lda, INT *restrict piv, INT *rank, const f32 tol, f32 *restrict work, INT *info)#

SPSTRF computes the Cholesky factorization with complete pivoting of a real symmetric positive semidefinite matrix A.

The factorization has the form

P**T * A * P = U**T * U ,  if uplo = 'U',
P**T * A * P = L  * L**T,  if uplo = 'L',

where U is an upper triangular matrix and L is lower triangular, and P is stored as vector PIV.

This algorithm does not attempt to check that A is positive semidefinite. This version of the algorithm calls level 3 BLAS.

Parameters

in
uplo

  • 'U': Upper triangular part of A is stored

  • 'L': Lower triangular part of A is stored

in
n

The order of the matrix A. n>=0.

inout
A

Array of dimension (lda,n). On entry, the symmetric matrix A. On exit, if info=0, the factor U or L from the Cholesky factorization.

in
lda

The leading dimension of the array A. lda>=max(1,n).

out
piv

Array of dimension n. PIV is such that the nonzero entries are P(PIV(k), k) = 1. 0-based indexing.

out
rank

The rank of A given by the number of steps the algorithm completed.

in
tol

User defined tolerance. If tol<0, then n*eps*max(A(k,k)) will be used. The algorithm terminates at the (k-1)st step if the pivot <=tol.

out
work

Array of dimension 2*n. Work space.

out
info

  • info=0: successful exit

  • info<0: if info=-k, the k-th argument had an illegal value

  • info>0: the matrix A is either rank deficient with computed rank as returned in rank, or is not positive semidefinite.

Functions

void dpstrf(
    const char*          uplo,
    const INT            n,
          f64*  restrict A,
    const INT            lda,
          INT*  restrict piv,
          INT*           rank,
    const f64            tol,
          f64*  restrict work,
          INT*           info
);
void dpstrf(const char *uplo, const INT n, f64 *restrict A, const INT lda, INT *restrict piv, INT *rank, const f64 tol, f64 *restrict work, INT *info)#

DPSTRF computes the Cholesky factorization with complete pivoting of a real symmetric positive semidefinite matrix A.

The factorization has the form

P**T * A * P = U**T * U ,  if uplo = 'U',
P**T * A * P = L  * L**T,  if uplo = 'L',

where U is an upper triangular matrix and L is lower triangular, and P is stored as vector PIV.

This algorithm does not attempt to check that A is positive semidefinite. This version of the algorithm calls level 3 BLAS.

Parameters

in
uplo

  • 'U': Upper triangular part of A is stored

  • 'L': Lower triangular part of A is stored

in
n

The order of the matrix A. n>=0.

inout
A

Array of dimension (lda,n). On entry, the symmetric matrix A. On exit, if info=0, the factor U or L from the Cholesky factorization.

in
lda

The leading dimension of the array A. lda>=max(1,n).

out
piv

Array of dimension n. PIV is such that the nonzero entries are P(PIV(k), k) = 1. 0-based indexing.

out
rank

The rank of A given by the number of steps the algorithm completed.

in
tol

User defined tolerance. If tol<0, then n*eps*max(A(k,k)) will be used. The algorithm terminates at the (k-1)st step if the pivot <=tol.

out
work

Array of dimension 2*n. Work space.

out
info

  • info=0: successful exit

  • info<0: if info=-k, the k-th argument had an illegal value

  • info>0: the matrix A is either rank deficient with computed rank as returned in rank, or is not positive semidefinite.

Functions

void cpstrf(
    const char*          uplo,
    const INT            n,
          c64*  restrict A,
    const INT            lda,
          INT*  restrict piv,
          INT*           rank,
    const f32            tol,
          f32*  restrict work,
          INT*           info
);
void cpstrf(const char *uplo, const INT n, c64 *restrict A, const INT lda, INT *restrict piv, INT *rank, const f32 tol, f32 *restrict work, INT *info)#

CPSTRF computes the Cholesky factorization with complete pivoting of a complex Hermitian positive semidefinite matrix A.

The factorization has the form

P**T * A * P = U**H * U ,  if uplo = 'U',
P**T * A * P = L  * L**H,  if uplo = 'L',

where U is an upper triangular matrix and L is lower triangular, and P is stored as vector PIV.

This algorithm does not attempt to check that A is positive semidefinite. This version of the algorithm calls level 3 BLAS.

Parameters

in
uplo

  • 'U': Upper triangular part of A is stored

  • 'L': Lower triangular part of A is stored

in
n

The order of the matrix A. n>=0.

inout
A

Complex array of dimension (lda,n). On entry, the Hermitian matrix A. On exit, if info=0, the factor U or L from the Cholesky factorization.

in
lda

The leading dimension of the array A. lda>=max(1,n).

out
piv

Array of dimension n. PIV is such that the nonzero entries are P(PIV(k), k) = 1. 0-based indexing.

out
rank

The rank of A given by the number of steps the algorithm completed.

in
tol

User defined tolerance. If tol<0, then n*eps*max(A(k,k)) will be used. The algorithm terminates at the (k-1)st step if the pivot <=tol.

out
work

Array of dimension 2*n. Work space.

out
info

  • info=0: successful exit

  • info<0: if info=-k, the k-th argument had an illegal value

  • info>0: the matrix A is either rank deficient with computed rank as returned in rank, or is not positive semidefinite.

Functions

void zpstrf(
    const char*          uplo,
    const INT            n,
          c128* restrict A,
    const INT            lda,
          INT*  restrict piv,
          INT*           rank,
    const f64            tol,
          f64*  restrict work,
          INT*           info
);
void zpstrf(const char *uplo, const INT n, c128 *restrict A, const INT lda, INT *restrict piv, INT *rank, const f64 tol, f64 *restrict work, INT *info)#

ZPSTRF computes the Cholesky factorization with complete pivoting of a complex Hermitian positive semidefinite matrix A.

The factorization has the form

P**T * A * P = U**H * U ,  if uplo = 'U',
P**T * A * P = L  * L**H,  if uplo = 'L',

where U is an upper triangular matrix and L is lower triangular, and P is stored as vector PIV.

This algorithm does not attempt to check that A is positive semidefinite. This version of the algorithm calls level 3 BLAS.

Parameters

in
uplo

  • 'U': Upper triangular part of A is stored

  • 'L': Lower triangular part of A is stored

in
n

The order of the matrix A. n>=0.

inout
A

Complex array of dimension (lda,n). On entry, the Hermitian matrix A. On exit, if info=0, the factor U or L from the Cholesky factorization.

in
lda

The leading dimension of the array A. lda>=max(1,n).

out
piv

Array of dimension n. PIV is such that the nonzero entries are P(PIV(k), k) = 1. 0-based indexing.

out
rank

The rank of A given by the number of steps the algorithm completed.

in
tol

User defined tolerance. If tol<0, then n*eps*max(A(k,k)) will be used. The algorithm terminates at the (k-1)st step if the pivot <=tol.

out
work

Array of dimension 2*n. Work space.

out
info

  • info=0: successful exit

  • info<0: if info=-k, the k-th argument had an illegal value

  • info>0: the matrix A is either rank deficient with computed rank as returned in rank, or is not positive semidefinite.