SRC/sgeqrt3.f(3)
π SRC/sgeqrt3.f π
okay so bestie, welcome to the glow-up zone β¨ β this here's a page from the Library Functions Manual, all about a lil routine called sgeqrt3 that lives in SRC/sgeqrt3.f. she's recursive, she's real, she does QR factorization, and she's about to eat. π
β¨ SYNOPSIS β¨
π Functions/Subroutines
recursive subroutine sgeqrt3 (m, n, a, lda, t, ldt, info)β SGEQRT3 recursively computes a QR factorization of a general real or complex matrix using the compact WY representation of Q.
π Function/Subroutine Documentation π
πΈ recursive subroutine sgeqrt3
recursive subroutine sgeqrt3 (integer m, integer n, real, dimension( lda, * ) a, integer lda, real, dimension( ldt, * ) t, integer ldt, integer info)
SGEQRT3 recursively computes a QR factorization of a general real or complex matrix using the compact WY representation of Q. periodt. π
π Purpose:
!>
!> SGEQRT3 recursively computes a QR factorization of a real M-by-N
!> matrix A, using the compact WY representation of Q.
!>
!> Based on the algorithm of Elmroth and Gustavson,
!> IBM J. Res. Develop. Vol 44 No. 4 July 2000.
!>
so like, it takes a real M-by-N matrix A and does QR factorization on it, using the compact WY representation of Q. no big deal, just iconic behavior. and credit where it's due β this is based on the algorithm of Elmroth and Gustavson, published in IBM J. Res. Develop. Vol 44 No. 4 July 2000. π§
π¦ Parameters
- M β
MisINTEGER. it's the number of rows of the matrixA, and the vibe check saysM >= N. π₯
!> M is INTEGER
!> The number of rows of the matrix A. M >= N.
!>
- N β
NisINTEGER. the number of columns of the matrixA.N >= 0, no negativity allowed bestie. π
!> N is INTEGER
!> The number of columns of the matrix A. N >= 0.
!>
- A β
AisREAL array, dimension (LDA,N). on entry, it's the realM-by-NmatrixA. on exit, the elements on and above the diagonal contain theN-by-Nupper triangular matrixR; the elements below the diagonal are the columns ofV. see below for further details, iykyk. π
!> A is REAL array, dimension (LDA,N)
!> On entry, the real M-by-N matrix A. On exit, the elements on and
!> above the diagonal contain the N-by-N upper triangular matrix R; the
!> elements below the diagonal are the columns of V. See below for
!> further details.
!>
- LDA β
LDAisINTEGER. the leading dimension of the arrayA. needsLDA >= max(1,M). it's giving "respect the dimensions" energy. π
!> LDA is INTEGER
!> The leading dimension of the array A. LDA >= max(1,M).
!>
- T β
TisREAL array, dimension (LDT,N). theN-by-Nupper triangular factor of the block reflector. the elements on and above the diagonal contain the block reflectorT; the elements below the diagonal are not used (they're just there, living their truth, unbothered π). see below for further details.
!> T is REAL array, dimension (LDT,N)
!> The N-by-N upper triangular factor of the block reflector.
!> The elements on and above the diagonal contain the block
!> reflector T; the elements below the diagonal are not used.
!> See below for further details.
!>
- LDT β
LDTisINTEGER. the leading dimension of the arrayT. needsLDT >= max(1,N). π
!> LDT is INTEGER
!> The leading dimension of the array T. LDT >= max(1,N).
!>
- INFO β
INFOisINTEGER. the whole mood report:= 0: successful exit π< 0: ifINFO = -i, thei-th argument had an illegal value β not me getting called out by an index π
!> INFO is INTEGER
!> = 0: successful exit
!> < 0: if INFO = -i, the i-th argument had an illegal value
!>
πΊ Author
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
the whole squad collaborated, we love a group project that actually delivers π«Ά
β Further Details:
okay this is the good part, the lore drop:
!>
!> The matrix V stores the elementary reflectors H(i) in the i-th column
!> below the diagonal. For example, if M=5 and N=3, the matrix V is
!>
!> V = ( 1 )
!> ( v1 1 )
!> ( v1 v2 1 )
!> ( v1 v2 v3 )
!> ( v1 v2 v3 )
!>
!> where the vi's represent the vectors which define H(i), which are returned
!> in the matrix A. The 1's along the diagonal of V are not stored in A. The
!> block reflector H is then given by
!>
!> H = I - V * T * V**T
!>
!> where V**T is the transpose of V.
!>
!> For details of the algorithm, see Elmroth and Gustavson (cited above).
!>
so like β the matrix V stores the elementary reflectors H(i) in the i-th column, below the diagonal. for the example where M=5 and N=3, you get that whole triangle vibe up there π. the vi's are the vectors defining H(i), and they get returned in the matrix A. but heads up: the 1's along the diagonal of V are not stored in A β she's implied, she's mysterious, she doesn't need a storage slot. β¨
then the block reflector H is given by H = I - V * T * V**T, where V**T is the transpose of V. simple as that, no cap. π¦
and for the full algorithm tea, go read Elmroth and Gustavson (cited above, bestie, scroll up π).
π‘ also: Definition at line 131 of file sgeqrt3.f. β so if you're out here reading the actual source, that's where she lives.
π§ Author
Generated automatically by Doxygen for LAPACK from the source code. yes, a robot wrote this page, and honestly? she ate. π€π
and that's the whole page, bestie! π this was LAPACK, Version 3.12.0, for SRC/sgeqrt3.f(3) β slay responsibly, and remember: LDA >= max(1,M), always. ππΈ
π¦ where this page comes from
- arch rolling: lapack-doc 3.12.1-2 Β· custom
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms