SGLMTS(3)
π SGLMTS π
ok so bestie, welcome to SGLMTS β she lives in the Library Functions Manual (that's the section-3 girlies, if you didn't know, now you know πββοΈ) and she has one job and she does it impeccably.
Her whole address, for the record, is:
/home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/TESTING/EIG/sglmts.f
like yes that's the whole NAME section, we're not doing a cute one-liner here, we're doing the full path, periodt. π
β¨ SYNOPSIS β¨
π¦ Functions/Subroutines
subroutine SGLMTS (n, m, p, a, af, lda, b, bf, ldb, d, df, x, u, work, lwork, rwork, result)β SGLMTS
that's it, that's the call. seventeen arguments. she's that girl. π
πΈ Function/Subroutine Documentation πΈ
okay so here's the full signature, verbatim, no cap:
subroutine SGLMTS (integer n, integer m, integer p, real, dimension( lda, * ) a, real, dimension( lda, * ) af, integer lda, real, dimension( ldb, * ) b, real, dimension( ldb, * ) bf, integer ldb, real, dimension( * ) d, real, dimension( * ) df, real, dimension( * ) x, real, dimension( * ) u, real, dimension( lwork ) work, integer lwork, real, dimension( * ) rwork, real result)
and the name again, for the vibes: SGLMTS
π Purpose π
!>!> SGLMTS tests SGGGLM - a subroutine for solving the generalized!> linear model problem.!>
so basically she's the quality-control bestie for SGGGLM β SGGGLM solves the generalized linear model problem, and SGLMTS is the one who shows up with a clipboard like "mmhmm, and did we verify that? we did π«Ά". icon behaviour honestly.
π Parameters π
grab a snack bestie, there are sixteen of them and every single one is getting her moment:
Nβ!>N is INTEGERβ!>The number of rows of the matrices A and B. N >= 0.β!>β the row count for bothAandB, and she must be>= 0or we're not doing this.Mβ!>M is INTEGERβ!>The number of columns of the matrix A. M >= 0.β!>β how many columnsAhas.M >= 0, respect it.Pβ!>P is INTEGERβ!>The number of columns of the matrix B. P >= 0.β!>β how many columnsBhas.P >= 0, same energy.Aβ!>A is REAL array, dimension (LDA,M)β!>The N-by-M matrix A.β!>β literally theN-by-MmatrixA, main character.AFβ!>AF is REAL array, dimension (LDA,M)β!>β aREALarray,dimension (LDA,M). no further notes, she said what she said.LDAβ!>LDA is INTEGERβ!>The leading dimension of the arrays A, AF. LDA >= max(M,N).β!>β leading dimension ofAandAF, and it's gotta beLDA >= max(M,N). the max is doing heavy lifting there, don't ignore it.Bβ!>B is REAL array, dimension (LDB,P)β!>The N-by-P matrix A.β!>β ok so the manpage says "The N-by-P matrix A" but we're all gonna pretend that saysBbecause that is what makes sense π keeping the original wording though, iykyk.BFβ!>BF is REAL array, dimension (LDB,P)β!>βREALarray,dimension (LDB,P), that's the whole note.LDBβ!>LDB is INTEGERβ!>The leading dimension of the arrays B, BF. LDB >= max(P,N).β!>β leading dimension forBandBF, constraint:LDB >= max(P,N).Dβ!>D is REAL array, dimension( N )β!>On input, the left hand side of the GLM.β!>β on input this is the left hand side of the GLM. important!DFβ!>DF is REAL array, dimension( N )β!>β array of dimension( N ), no extra comments, moving on.Xβ!>X is REAL array, dimension ( M )β!>solution vector X in the GLM problem.β!>β solution vectorXin the GLM problem. queen of the answer key.Uβ!>U is REAL array, dimension ( P )β!>solution vector U in the GLM problem.β!>β solution vectorU, also in the GLM problem. the other half of the answer.WORKβ!>WORK is REAL array, dimension (LWORK)β!>β workspace,REAL,dimension (LWORK).LWORKβ!>LWORK is INTEGERβ!>The dimension of the array WORK.β!>β literally just the dimension ofWORK. that's the note.RWORKβ!>RWORK is REAL array, dimension (M)β!>βREALarray,dimension (M).RESULTβ!>RESULT is REALβ!>The test ratio:β and then the formula, which we're preserving exactly because it's the whole point:
!> norm( d - A*x - B*u )
!> RESULT = -----------------------------------------
!> (norm(A)+norm(B))*(norm(x)+norm(u))*EPS
π bestie that's the whole verdict β residual on top, norms and EPS on the bottom. tiny number = slay, big number = something's wrong and we need to talk.
π Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
the whole squad really showed up for this one π«Ά
Definition at line 147 of file sglmts.f. β yes, line 147, go look, she's right there β¨
π Author π
Generated automatically by Doxygen for LAPACK from the source code. not a human, just a very thorough little robot doing her thing π€π
ok that's the whole page! this absolute icon is brought to you by LAPACK, Version 3.12.0 β and yeah, the footer keeps pointing back at /home/abui...IG/sglmts.f(3) because she's nothing if not consistent π
β¨ π
π¦ where this page comes from
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: lapack-man 3.12.0-160000.2.2 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms