pttrf#

Functions

void spttrf(
    const INT           n,
          f32* restrict D,
          f32* restrict E,
          INT*          info
);
void spttrf(const INT n, f32 *restrict D, f32 *restrict E, INT *info)#

SPTTRF computes the L*D*L**T factorization of a real symmetric positive definite tridiagonal matrix A.

The factorization may also be regarded as having the form A = U**T*D*U.

Parameters

in
n

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

inout
D

Double precision array, dimension (n). On entry, the n diagonal elements of the tridiagonal matrix A. On exit, the n diagonal elements of the diagonal matrix D from the L*D*L**T factorization of A.

inout
E

Double precision array, dimension (n-1). On entry, the (n-1) subdiagonal elements of the tridiagonal matrix A. On exit, the (n-1) subdiagonal elements of the unit bidiagonal factor L from the L*D*L**T factorization of A. E can also be regarded as the superdiagonal of the unit bidiagonal factor U from the U**T*D*U factorization of A.

out
info

  • = 0: successful exit

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

  • > 0: if info = k, the leading principal minor of order k is not positive; if k < n, the factorization could not be completed, while if k = n, the factorization was completed, but D(n-1) <= 0 (0-based).

Functions

void dpttrf(
    const INT           n,
          f64* restrict D,
          f64* restrict E,
          INT*          info
);
void dpttrf(const INT n, f64 *restrict D, f64 *restrict E, INT *info)#

DPTTRF computes the L*D*L**T factorization of a real symmetric positive definite tridiagonal matrix A.

The factorization may also be regarded as having the form A = U**T*D*U.

Parameters

in
n

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

inout
D

Double precision array, dimension (n). On entry, the n diagonal elements of the tridiagonal matrix A. On exit, the n diagonal elements of the diagonal matrix D from the L*D*L**T factorization of A.

inout
E

Double precision array, dimension (n-1). On entry, the (n-1) subdiagonal elements of the tridiagonal matrix A. On exit, the (n-1) subdiagonal elements of the unit bidiagonal factor L from the L*D*L**T factorization of A. E can also be regarded as the superdiagonal of the unit bidiagonal factor U from the U**T*D*U factorization of A.

out
info

  • = 0: successful exit

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

  • > 0: if info = k, the leading principal minor of order k is not positive; if k < n, the factorization could not be completed, while if k = n, the factorization was completed, but D(n-1) <= 0 (0-based).

Functions

void cpttrf(
    const INT           n,
          f32* restrict D,
          c64* restrict E,
          INT*          info
);
void cpttrf(const INT n, f32 *restrict D, c64 *restrict E, INT *info)#

CPTTRF computes the L*D*L**H factorization of a complex Hermitian positive definite tridiagonal matrix A.

The factorization may also be regarded as having the form A = U**H *D*U.

Parameters

in
n

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

inout
D

Single precision array, dimension (n). On entry, the n diagonal elements of the tridiagonal matrix A. On exit, the n diagonal elements of the diagonal matrix D from the L*D*L**H factorization of A.

inout
E

Complex*16 array, dimension (n-1). On entry, the (n-1) subdiagonal elements of the tridiagonal matrix A. On exit, the (n-1) subdiagonal elements of the unit bidiagonal factor L from the L*D*L**H factorization of A. E can also be regarded as the superdiagonal of the unit bidiagonal factor U from the U**H *D*U factorization of A.

out
info

  • = 0: successful exit

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

  • > 0: if info = k, the leading principal minor of order k is not positive; if k < n, the factorization could not be completed, while if k = n, the factorization was completed, but D(n-1) <= 0 (0-based).

Functions

void zpttrf(
    const INT            n,
          f64*  restrict D,
          c128* restrict E,
          INT*           info
);
void zpttrf(const INT n, f64 *restrict D, c128 *restrict E, INT *info)#

ZPTTRF computes the L*D*L**H factorization of a complex Hermitian positive definite tridiagonal matrix A.

The factorization may also be regarded as having the form A = U**H *D*U.

Parameters

in
n

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

inout
D

Double precision array, dimension (n). On entry, the n diagonal elements of the tridiagonal matrix A. On exit, the n diagonal elements of the diagonal matrix D from the L*D*L**H factorization of A.

inout
E

Complex*16 array, dimension (n-1). On entry, the (n-1) subdiagonal elements of the tridiagonal matrix A. On exit, the (n-1) subdiagonal elements of the unit bidiagonal factor L from the L*D*L**H factorization of A. E can also be regarded as the superdiagonal of the unit bidiagonal factor U from the U**H *D*U factorization of A.

out
info

  • = 0: successful exit

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

  • > 0: if info = k, the leading principal minor of order k is not positive; if k < n, the factorization could not be completed, while if k = n, the factorization was completed, but D(n-1) <= 0 (0-based).