SRC/sla_gercond.f(3)

🌸 NAME 🌸

Okay bestie, this is the SRC/sla_gercond.f page from the Library Functions Manual β€” and it's all about SLA_GERCOND, a real function that estimates the Skeel condition number for a general matrix. πŸ’…βœ¨


✨ SYNOPSIS ✨

πŸŽ€ Functions/Subroutines

  • real function sla_gercond (trans, n, a, lda, af, ldaf, ipiv, cmode, c, info, work, iwork) β€” SLA_GERCOND estimates the Skeel condition number for a general matrix. No cap, that's the whole gig. 🫢

πŸ“š Function/Subroutine Documentation πŸ“š

Here's the full signature, character-for-character, because we do not play fast and loose with Fortran around here:

       real function sla_gercond (character trans, integer n, real, dimension( lda,
       * ) a, integer lda, real, dimension( ldaf, * ) af, integer ldaf,
       integer, dimension( * ) ipiv, integer cmode, real, dimension( * ) c,
       integer info, real, dimension( * ) work, integer, dimension( * ) iwork)

SLA_GERCOND estimates the Skeel condition number for a general matrix. That's the main-character energy of this whole page. πŸ‘‘

πŸ¦‹ Purpose πŸ¦‹

So here's the vibe: SLA_GERCOND estimates the Skeel condition number of op(A) * op2(C), where op2 is chosen by CMODE, like this:

CMODE =  1    op2(C) = C
CMODE =  0    op2(C) = I
CMODE = -1    op2(C) = inv(C)

The Skeel condition number is:

cond(A) = norminf( |inv(A)||A| )

And it gets computed by finding scaling factors R such that diag(R)*A*op2(C) is row equilibrated, then computing the standard infinity-norm condition number. Literally the whole plot. πŸ’–

🌈 Parameters 🌈

TRANS

TRANS is CHARACTER*1. It specifies the form of the system of equations:

  • 'N': A * X = B β€” No transpose
  • 'T': A**T * X = B β€” Transpose
  • 'C': A**H * X = B β€” Conjugate Transpose = Transpose

N

N is INTEGER. It's the number of linear equations, i.e. the order of the matrix A. N >= 0. Periodt. πŸŽ€

A

A is REAL array, dimension (LDA,N). On entry, this is the N-by-N matrix A. Iconic input behavior. ✨

LDA

LDA is INTEGER. It's the leading dimension of the array A. LDA >= max(1,N). Respect the leading dimension, bestie. πŸ’…

AF

AF is REAL array, dimension (LDAF,N). These are the factors L and U from the factorization A = P*L*U as computed by SGETRF. 🧚

LDAF

LDAF is INTEGER. It's the leading dimension of the array AF. LDAF >= max(1,N). Yes, another leading dimension, and yes, it matters. πŸ¦‹

IPIV

IPIV is INTEGER array, dimension (N). These are the pivot indices from the factorization A = P*L*U as computed by SGETRF; row i of the matrix was interchanged with row IPIV(i). Not me explaining pivots in the group chat. 😭

CMODE

CMODE is INTEGER. It determines op2(C) in the formula op(A) * op2(C) as follows:

  • CMODE = 1 β€” op2(C) = C
  • CMODE = 0 β€” op2(C) = I
  • CMODE = -1 β€” op2(C) = inv(C)

C

C is REAL array, dimension (N). It's the vector C in the formula op(A) * op2(C). 🌸

INFO

INFO is INTEGER:

  • = 0: Successful exit.
  • i > 0: The ith argument is invalid.

That's it. That's the status report. πŸ”₯

WORK

WORK is REAL array, dimension (3*N). Workspace. The behind-the-scenes bestie. 🫢

IWORK

IWORK is INTEGER array, dimension (N). Workspace.2 β€” yes, that literal Workspace.2 is part of the original, and we are keeping it exactly. πŸ’€


πŸ‘‘ Author πŸ‘‘

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

Definition at line 148 of file sla_gercond.f. β€” noted, bookmarked, screenshotted. πŸ“Œ


🧚 Author 🧚

Generated automatically by Doxygen for LAPACK from the source code. The robots did their little documentation moment. πŸ€–βœ¨


That's the whole page, bestie β€” signing off from SRC/sla_gercond.f(3), LAPACK Version 3.12.0. Stay slaying, and may your condition numbers always be estimated πŸ’–πŸ’…πŸŒˆ

πŸ“¦ where this page comes from