la_lin_berr#

Functions

void cla_lin_berr(
    const INT           n,
    const INT           nz,
    const INT           nrhs,
    const c64* restrict RES,
    const f32* restrict AYB,
          f32* restrict BERR
);
void cla_lin_berr(const INT n, const INT nz, const INT nrhs, const c64 *restrict RES, const f32 *restrict AYB, f32 *restrict BERR)#

CLA_LIN_BERR computes componentwise relative backward error from the formula max(i) ( abs(R(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.

Parameters

in
n

The number of linear equations, i.e., the order of the matrix A. n >= 0.

in
nz

We add (NZ+1)*SLAMCH( ‘Safe minimum’ ) to R(i) in the numerator to guard against spuriously zero residuals. Default value is N.

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices AYB, RES, and BERR. nrhs >= 0.

in
RES

Complex array, dimension (n, nrhs). The residual matrix, i.e., the matrix R in the relative backward error formula above.

in
AYB

Single precision array, dimension (n, nrhs). The denominator in the relative backward error formula above, i.e., the matrix abs(op(A_s))*abs(Y) + abs(B_s).

out
BERR

Single precision array, dimension (nrhs). The componentwise relative backward error from the formula above.

Functions

void zla_lin_berr(
    const INT            n,
    const INT            nz,
    const INT            nrhs,
    const c128* restrict RES,
    const f64*  restrict AYB,
          f64*  restrict BERR
);
void zla_lin_berr(const INT n, const INT nz, const INT nrhs, const c128 *restrict RES, const f64 *restrict AYB, f64 *restrict BERR)#

ZLA_LIN_BERR computes componentwise relative backward error from the formula max(i) ( abs(R(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.

Parameters

in
n

The number of linear equations, i.e., the order of the matrix A. n >= 0.

in
nz

We add (NZ+1)*SLAMCH( ‘Safe minimum’ ) to R(i) in the numerator to guard against spuriously zero residuals. Default value is N.

in
nrhs

The number of right hand sides, i.e., the number of columns of the matrices AYB, RES, and BERR. nrhs >= 0.

in
RES

Complex array, dimension (n, nrhs). The residual matrix, i.e., the matrix R in the relative backward error formula above.

in
AYB

Double precision array, dimension (n, nrhs). The denominator in the relative backward error formula above, i.e., the matrix abs(op(A_s))*abs(Y) + abs(B_s).

out
BERR

Double precision array, dimension (nrhs). The componentwise relative backward error from the formula above.