sprfs#

Functions

void ssprfs(
    const char*          uplo,
    const INT            n,
    const INT            nrhs,
    const f32*  restrict AP,
    const f32*  restrict AFP,
    const INT*  restrict ipiv,
    const f32*  restrict B,
    const INT            ldb,
          f32*  restrict X,
    const INT            ldx,
          f32*  restrict ferr,
          f32*  restrict berr,
          f32*  restrict work,
          INT*  restrict iwork,
          INT*           info
);
void ssprfs(const char *uplo, const INT n, const INT nrhs, const f32 *restrict AP, const f32 *restrict AFP, const INT *restrict ipiv, const f32 *restrict B, const INT ldb, f32 *restrict X, const INT ldx, f32 *restrict ferr, f32 *restrict berr, f32 *restrict work, INT *restrict iwork, INT *info)#

SSPRFS improves the computed solution to a system of linear equations when the coefficient matrix is symmetric indefinite and packed, and provides error bounds and backward error estimates for the solution.

Parameters

in
uplo

  • 'U': Upper triangle of A is stored

  • 'L': Lower triangle of A is stored

in
n

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

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices B and X. nrhs>=0.

in
AP

Array of dimension n*(n+1)/2. The upper or lower triangle of the symmetric matrix A, packed columnwise in a linear array. The j-th column of A is stored in the array AP as follows: if uplo='U', AP[i + j*(j+1)/2] = A(i,j) for 0<=i<=j; if uplo='L', AP[i + j*(2*n-j-1)/2] = A(i,j) for j<=i<=n-1.

in
AFP

Array of dimension n*(n+1)/2. The factored form of the matrix A. AFP contains the block diagonal matrix D and the multipliers used to obtain the factor U or L from the factorization A = U*D*U**T or A = L*D*L**T as computed by ssptrf, stored as a packed triangular matrix.

in
ipiv

Array of dimension n. Details of the interchanges and the block structure of D as determined by ssptrf.

in
B

Array of dimension (ldb,nrhs). The right hand side matrix B.

in
ldb

The leading dimension of the array B. ldb>=max(1,n).

inout
X

Array of dimension (ldx,nrhs). On entry, the solution matrix X, as computed by ssptrs. On exit, the improved solution matrix X.

in
ldx

The leading dimension of the array X. ldx>=max(1,n).

out
ferr

Array of 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

Array of 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

Workspace array of dimension 3*n.

out
iwork

Integer workspace array of dimension n.

out
info

  • info=0: successful exit

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

Functions

void dsprfs(
    const char*          uplo,
    const INT            n,
    const INT            nrhs,
    const f64*  restrict AP,
    const f64*  restrict AFP,
    const INT*  restrict ipiv,
    const f64*  restrict B,
    const INT            ldb,
          f64*  restrict X,
    const INT            ldx,
          f64*  restrict ferr,
          f64*  restrict berr,
          f64*  restrict work,
          INT*  restrict iwork,
          INT*           info
);
void dsprfs(const char *uplo, const INT n, const INT nrhs, const f64 *restrict AP, const f64 *restrict AFP, const INT *restrict ipiv, const f64 *restrict B, const INT ldb, f64 *restrict X, const INT ldx, f64 *restrict ferr, f64 *restrict berr, f64 *restrict work, INT *restrict iwork, INT *info)#

DSPRFS improves the computed solution to a system of linear equations when the coefficient matrix is symmetric indefinite and packed, and provides error bounds and backward error estimates for the solution.

Parameters

in
uplo

  • 'U': Upper triangle of A is stored

  • 'L': Lower triangle of A is stored

in
n

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

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices B and X. nrhs>=0.

in
AP

Array of dimension n*(n+1)/2. The upper or lower triangle of the symmetric matrix A, packed columnwise in a linear array. The j-th column of A is stored in the array AP as follows: if uplo='U', AP[i + j*(j+1)/2] = A(i,j) for 0<=i<=j; if uplo='L', AP[i + j*(2*n-j-1)/2] = A(i,j) for j<=i<=n-1.

in
AFP

Array of dimension n*(n+1)/2. The factored form of the matrix A. AFP contains the block diagonal matrix D and the multipliers used to obtain the factor U or L from the factorization A = U*D*U**T or A = L*D*L**T as computed by dsptrf, stored as a packed triangular matrix.

in
ipiv

Array of dimension n. Details of the interchanges and the block structure of D as determined by dsptrf.

in
B

Array of dimension (ldb,nrhs). The right hand side matrix B.

in
ldb

The leading dimension of the array B. ldb>=max(1,n).

inout
X

Array of dimension (ldx,nrhs). On entry, the solution matrix X, as computed by dsptrs. On exit, the improved solution matrix X.

in
ldx

The leading dimension of the array X. ldx>=max(1,n).

out
ferr

Array of 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

Array of 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

Workspace array of dimension 3*n.

out
iwork

Integer workspace array of dimension n.

out
info

  • info=0: successful exit

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

Functions

void csprfs(
    const char*          uplo,
    const INT            n,
    const INT            nrhs,
    const c64*  restrict AP,
    const c64*  restrict AFP,
    const INT*  restrict ipiv,
    const c64*  restrict B,
    const INT            ldb,
          c64*  restrict X,
    const INT            ldx,
          f32*  restrict ferr,
          f32*  restrict berr,
          c64*  restrict work,
          f32*  restrict rwork,
          INT*           info
);
void csprfs(const char *uplo, const INT n, const INT nrhs, const c64 *restrict AP, const c64 *restrict AFP, const INT *restrict ipiv, const c64 *restrict B, const INT ldb, c64 *restrict X, const INT ldx, f32 *restrict ferr, f32 *restrict berr, c64 *restrict work, f32 *restrict rwork, INT *info)#

CSPRFS improves the computed solution to a system of linear equations when the coefficient matrix is symmetric indefinite and packed, and provides error bounds and backward error estimates for the solution.

Parameters

in
uplo

  • 'U': Upper triangle of A is stored

  • 'L': Lower triangle of A is stored

in
n

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

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices B and X. nrhs>=0.

in
AP

Complex array of dimension n*(n+1)/2. The upper or lower triangle of the symmetric matrix A, packed columnwise in a linear array. The j-th column of A is stored in the array AP as follows: if uplo='U', AP[i + j*(j+1)/2] = A(i,j) for 0<=i<=j; if uplo='L', AP[i + j*(2*n-j-1)/2] = A(i,j) for j<=i<=n-1.

in
AFP

Complex array of dimension n*(n+1)/2. The factored form of the matrix A. AFP contains the block diagonal matrix D and the multipliers used to obtain the factor U or L from the factorization A = U*D*U**T or A = L*D*L**T as computed by csptrf, stored as a packed triangular matrix.

in
ipiv

Array of dimension n. Details of the interchanges and the block structure of D as determined by csptrf.

in
B

Complex array of dimension (ldb,nrhs). The right hand side matrix B.

in
ldb

The leading dimension of the array B. ldb>=max(1,n).

inout
X

Complex array of dimension (ldx,nrhs). On entry, the solution matrix X, as computed by csptrs. On exit, the improved solution matrix X.

in
ldx

The leading dimension of the array X. ldx>=max(1,n).

out
ferr

Array of 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

Array of 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

Complex workspace array of dimension 2*n.

out
rwork

Real workspace array of dimension n.

out
info

  • info=0: successful exit

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

Functions

void zsprfs(
    const char*          uplo,
    const INT            n,
    const INT            nrhs,
    const c128* restrict AP,
    const c128* restrict AFP,
    const INT*  restrict ipiv,
    const c128* restrict B,
    const INT            ldb,
          c128* restrict X,
    const INT            ldx,
          f64*  restrict ferr,
          f64*  restrict berr,
          c128* restrict work,
          f64*  restrict rwork,
          INT*           info
);
void zsprfs(const char *uplo, const INT n, const INT nrhs, const c128 *restrict AP, const c128 *restrict AFP, const INT *restrict ipiv, const c128 *restrict B, const INT ldb, c128 *restrict X, const INT ldx, f64 *restrict ferr, f64 *restrict berr, c128 *restrict work, f64 *restrict rwork, INT *info)#

ZSPRFS improves the computed solution to a system of linear equations when the coefficient matrix is symmetric indefinite and packed, and provides error bounds and backward error estimates for the solution.

Parameters

in
uplo

  • 'U': Upper triangle of A is stored

  • 'L': Lower triangle of A is stored

in
n

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

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices B and X. nrhs>=0.

in
AP

Complex array of dimension n*(n+1)/2. The upper or lower triangle of the symmetric matrix A, packed columnwise in a linear array. The j-th column of A is stored in the array AP as follows: if uplo='U', AP[i + j*(j+1)/2] = A(i,j) for 0<=i<=j; if uplo='L', AP[i + j*(2*n-j-1)/2] = A(i,j) for j<=i<=n-1.

in
AFP

Complex array of dimension n*(n+1)/2. The factored form of the matrix A. AFP contains the block diagonal matrix D and the multipliers used to obtain the factor U or L from the factorization A = U*D*U**T or A = L*D*L**T as computed by zsptrf, stored as a packed triangular matrix.

in
ipiv

Array of dimension n. Details of the interchanges and the block structure of D as determined by zsptrf.

in
B

Complex array of dimension (ldb,nrhs). The right hand side matrix B.

in
ldb

The leading dimension of the array B. ldb>=max(1,n).

inout
X

Complex array of dimension (ldx,nrhs). On entry, the solution matrix X, as computed by zsptrs. On exit, the improved solution matrix X.

in
ldx

The leading dimension of the array X. ldx>=max(1,n).

out
ferr

Array of 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

Array of 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

Complex workspace array of dimension 2*n.

out
rwork

Real workspace array of dimension n.

out
info

  • info=0: successful exit

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