SRC/slarrk.f(3)

πŸ’… SRC/slarrk.f β€” like, the whole manual, bestie

okay so this is the SRC/slarrk.f page from the LAPACK Library Functions Manual, and it's genuinely one of those little helper icons that does one job and does it beautifully. no notes. ✨


✨ SYNOPSIS ✨

Functions/Subroutines β€” here's the lineup:

  • subroutine slarrk (n, iw, gl, gu, d, e2, pivmin, reltol, w, werr, info) β€” SLARRK computes one eigenvalue of a symmetric tridiagonal matrix T to suitable accuracy. one eigenvalue! she's focused, she's got a niche, she's serving.

🫢 Function/Subroutine Documentation 🫢

slarrk

here's the full signature, character for character, don't @ me:

subroutine slarrk (integer n, integer iw, real gl, real gu, real, dimension(
* ) d, real, dimension( * ) e2, real pivmin, real reltol, real w, real
werr, integer info)

SLARRK computes one eigenvalue of a symmetric tridiagonal matrix T to suitable accuracy. that's the whole vibe. main character energy but make it numerical. πŸ’œ

🌸 Purpose 🌸

okay so, straight from the source:

SLARRK computes one eigenvalue of a symmetric tridiagonal matrix T to suitable accuracy. This is an auxiliary code to be called from SSTEMR.

she's an auxiliary code, meaning she's not out here doing solo shows β€” she's the support act for SSTEMR. respect the hustle. πŸ’…

and here's the part where you gotta listen, bestie, because this is a real caveat:

To avoid overflow, the matrix must be scaled so that its largest element is no greater than overflow(1/2) * underflow(1/4) in absolute value, and for greatest accuracy, it should not be much smaller than that.

so like β€” scale your matrix correctly or it's giving πŸ’€ overflow. no cap. and if you want greatest accuracy, don't make it much smaller than that bound either. the sweet spot is real.

also, credit where credit is due:

See W. Kahan , Report CS41, Computer Science Dept., Stanford University, July 21, 1966.

we stan a citation icon. πŸŽ€

πŸ¦‹ Parameters πŸ¦‹

  • N β€” N is INTEGER. the order of the tridiagonal matrix T. N >= 0. (zero is allowed, she's inclusive.)
  • IW β€” IW is INTEGER. the index of the eigenvalues to be returned. singular eigenvalue, one job, iconic.
  • GL β€” GL is REAL. that's it. that's the whole description. she said "I'm REAL" and left. πŸ™ˆ
  • GU β€” GU is REAL. an upper and a lower bound on the eigenvalue. (yes, GL and GU are the bound girlies β€” GU just happens to also carry the label text here.)
  • D β€” D is REAL array, dimension (N). the n diagonal elements of the tridiagonal matrix T. the main diagonal, literally.
  • E2 β€” E2 is REAL array, dimension (N-1). the (n-1) squared off-diagonal elements of the tridiagonal matrix T. note the squared β€” these are already squared, don't square them again, I'm begging. 😭
  • PIVMIN β€” PIVMIN is REAL. the minimum pivot allowed in the Sturm sequence for T.
  • RELTOL β€” RELTOL is REAL. the minimum relative width of an interval. when an interval is narrower than RELTOL times the larger (in magnitude) endpoint, then it is considered to be sufficiently small, i.e., converged. πŸ“ Note: this should always be at least radix*machine epsilon. always. don't skip this. 🫢
  • W β€” W is REAL. also just... REAL. no further comment. short queen. ✨
  • WERR β€” WERR is REAL. the error bound on the corresponding eigenvalue approximation in W.
  • INFO β€” INFO is INTEGER. the vibe check, and it only has two moods:
    • = 0: eigenvalue converged πŸ‘‘
    • = -1: eigenvalue did NOT converge πŸ’€

🧚 Internal Parameters: 🧚

  • FUDGE β€” REAL, default = 2. a FUDGE to widen the Gershgorin intervals. yes it's literally called FUDGE, yes I'm obsessed, no we're not renaming it. πŸ“

πŸ‘‘ Author πŸ‘‘

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

the whole squad, fr fr. 🌈

Definition at line 143 of file slarrk.f.


⭐ Author (again, but meta) ⭐

Generated automatically by Doxygen for LAPACK from the source code. so nobody hand-wrote this page β€” the robots did it, and honestly? slay. πŸ€–πŸ’–


and that's the whole page, bestie β€” no skipped sections, no missing flags, nothing dropped. this file is from LAPACK, Version 3.12.0, and the page itself is SRC/slarrk.f(3). date-wise the manual doesn't stamp one on the footer, so we're just gonna say this one's timeless. πŸ’œβœ¨πŸŽ€

πŸ“¦ where this page comes from