SRC/dgtcon.f(3)

πŸ’… NAME

SRC/dgtcon.f β€” bestie, this is the Fortran file that gives you DGTCON, the routine that tells you how close your real tridiagonal matrix is to being a hot mess (numerically speaking). It's a library function page, so buckle up πŸŽ€


✨ SYNOPSIS

Functions/Subroutines

subroutine dgtcon (norm, n, dl, d, du, du2, ipiv, anorm, rcond, work,
    iwork, info)

DGTCON πŸ‘‘


πŸ¦‹ Function/Subroutine Documentation

subroutine dgtcon (character norm, integer n, double precision, dimension( * )
    dl, double precision, dimension( * ) d, double precision, dimension( * )
    du, double precision, dimension( * ) du2, integer, dimension( * )
    ipiv, double precision anorm, double precision rcond, double precision,
    dimension( * ) work, integer, dimension( * ) iwork, integer info)

DGTCON β€” yes, same name again, it's iconic like that ✨

🌸 Purpose

okay so straight from the source, bestie:

!>
!> DGTCON estimates the reciprocal of the condition number of a real
!> tridiagonal matrix A using the LU factorization as computed by
!> DGTTRF.
!>
!> An estimate is obtained for norm(inv(A)), and the reciprocal of the
!> condition number is computed as RCOND = 1 / (ANORM * norm(inv(A))).
!>

Translation: it takes the LU factorization that DGTTRF already did for you (no cap, that's a whole other routine) and uses it to vibe-check how ill-conditioned your matrix A is. It estimates norm(inv(A)), then does the math RCOND = 1 / (ANORM * norm(inv(A))). That's it, that's the whole personality πŸ’–

🌈 Parameters

  • NORM β€” CHARACTER*1 πŸ’… tells it which condition number flavor you want: = '1' or 'O' for the 1-norm; = 'I' for the Infinity-norm. Pick your fighter.
  • N β€” INTEGER, the order of the matrix A. Constraint: N >= 0. Zero-sized matrices are valid, she contains multitudes 🫢
  • DL β€” DOUBLE PRECISION array, dimension (N-1). The (n-1) multipliers that define the matrix L from the LU factorization of A as computed by DGTTRF.
  • D β€” DOUBLE PRECISION array, dimension (N). The n diagonal elements of the upper triangular matrix U, again from the LU factorization of A.
  • DU β€” DOUBLE PRECISION array, dimension (N-1). The (n-1) elements of the first superdiagonal of U. Yes, superdiagonal. She's above the diagonal, slay.
  • DU2 β€” DOUBLE PRECISION array, dimension (N-2). The (n-2) elements of the second superdiagonal of U. One more level up, main character energy πŸ‘‘
  • IPIV β€” INTEGER array, dimension (N). The pivot indices: for 1 <= i <= n, row i of the matrix was interchanged with row IPIV(i). IPIV(i) will always be either i or i+1; and IPIV(i) = i means no row interchange was required (she stayed put πŸ’€).
  • ANORM β€” DOUBLE PRECISION. If NORM = '1' or 'O', this is the 1-norm of the original matrix A. If NORM = 'I', it's the infinity-norm of the original matrix A. Context matters, bestie.
  • RCOND β€” DOUBLE PRECISION. The reciprocal of the condition number of the matrix A, computed as RCOND = 1/(ANORM * AINVNM), where AINVNM is an estimate of the 1-norm of inv(A) computed in this routine. That's the whole output, and she's lowkey the point of the entire function πŸ™ˆ
  • WORK β€” DOUBLE PRECISION array, dimension (2*N). Scratch space. Don't ask questions, just hand her 2*N doubles.
  • IWORK β€” INTEGER array, dimension (N). More scratch space, integer flavored this time.
  • INFO β€” INTEGER. The receipts:
    • = 0: successful exit πŸŽ‰
    • < 0: if INFO = -i, the i-th argument had an illegal value 😭
fr fr check INFO before you trust RCOND, okay? An INFO < 0 means somebody passed a bad argument and nothing is guaranteed. Not me being dramatic, that's just what it says.

🧚 Author

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

Definition at line 144 of file dgtcon.f.

Author: Generated automatically by Doxygen for LAPACK from the source code.


πŸ“ psst: this whole page was auto-generated by Doxygen for LAPACK from the source code, so if you see a typo, blame the machine, not me πŸ’œ

okay bye bestie, go forth and condition your numbers πŸ’–βœ¨πŸŽ€ This was SRC/dgtcon.f(3), tagged LAPACK Version 3.12.0 in the footer β€” no date on the tin, just the version, and honestly she ate πŸ¦‹

πŸ“¦ where this page comes from