gemqr(3)
π gemqr β gemqr: multiply by Q from geqr π
okay bestie, welcome to gemqr(3) β yes that's the manual section three, we're in library functions territory, put your hair up π
β¨ NAME β¨
gemqr β gemqr: multiply by Q from geqr
like, that's the whole name. short. iconic. it multiplies stuff by Q. slay.
πΈ SYNOPSIS πΈ
π«Ά Functions
subroutine cgemqrβCGEMQR, the complex one π
subroutine cgemqr (side, trans, m, n, k, a, lda, t, tsize, c, ldc, work,
lwork, info)
subroutine dgemqrβDGEMQR, the double precision one πΈ
subroutine dgemqr (side, trans, m, n, k, a, lda, t, tsize, c, ldc, work,
lwork, info)
subroutine sgemqrβSGEMQR, the single precision one π
subroutine sgemqr (side, trans, m, n, k, a, lda, t, tsize, c, ldc, work,
lwork, info)
subroutine zgemqrβZGEMQR, the double complex one π¦
subroutine zgemqr (side, trans, m, n, k, a, lda, t, tsize, c, ldc, work,
lwork, info)
four routines, one vibe. precision queens, all of them π
π Detailed Description π
bestie this section is genuinely just vibes and a doorway β it says Function Documentation and then we go straight into the goods. no preamble. respect.
π₯ Function Documentation π₯
π
subroutine cgemqr
subroutine cgemqr (character side, character trans, integer m, integer n,
integer k, complex, dimension( lda, * ) a, integer lda, complex,
dimension( * ) t, integer tsize, complex, dimension( ldc, * ) c, integer
ldc, complex, dimension( * ) work, integer lwork, integer info)
CGEMQR
β Purpose
so what it does: CGEMQR overwrites the general real M-by-N matrix C with π
SIDE = 'L' SIDE = 'R'
TRANS = 'N': Q * C C * Q
TRANS = 'T': Q**H * C C * Q**H
(yes it says "real M-by-N matrix" in the complex routine, that's literally what the source says, I'm just the messenger π«Ά)
where Q is a complex unitary matrix defined as the product of blocked elementary reflectors computed by tall skinny QR factorization (CGEQR). tall skinny. main character energy. β¨
π Parameters
SIDEβCHARACTER*1.= 'L': apply Q or QH from the Left;= 'R': apply Q or QH from the Right. pick a side, bestie πTRANSβCHARACTER*1.= 'N': No transpose, apply Q;= 'C': Conjugate transpose, apply Q**H. π¦MβINTEGER. The number of rows of the matrix A.M >=0.NβINTEGER. The number of columns of the matrix C.N >= 0.KβINTEGER. The number of elementary reflectors whose product defines the matrix Q. IfSIDE = 'L',M >= K >= 0; ifSIDE = 'R',N >= K >= 0. π«ΆAβCOMPLEXarray, dimension(LDA,K). Part of the data structure to represent Q as returned byCGEQR. it's not just a matrix, it's a whole data structure, respect the lore πLDAβINTEGER. The leading dimension of the array A. IfSIDE = 'L',LDA >= max(1,M); ifSIDE = 'R',LDA >= max(1,N).TβCOMPLEXarray, dimension(MAX(5,TSIZE)). Part of the data structure to represent Q as returned byCGEQR. πTSIZEβINTEGER. The dimension of the array T.TSIZE >= 5.CβCOMPLEXarray, dimension(LDC,N). On entry, the M-by-N matrix C. On exit, C is overwritten byQ*CorQ**H*CorC*Q**HorC*Q. she gets overwritten, no cap πLDCβINTEGER. The leading dimension of the array C.LDC >= max(1,M).WORKβ (workspace)COMPLEXarray, dimension(MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the minimalLWORK. β¨LWORKβINTEGER. The dimension of the arrayWORK.LWORK >= 1. IfLWORK = -1, then a workspace query is assumed. The routine only calculates the size of theWORKarray, returns this value asWORK(1), and no error message related toWORKis issued byXERBLA. the sneaky little size-check trick, obsessed πINFOβINTEGER.= 0: successful exit.< 0: ifINFO = -i, the i-th argument had an illegal value. π
π Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
π§ Further Details
These details are particular for this LAPACK implementation. Users should not take them for granted. These details may change in the future, and are not likely true for another LAPACK implementation. These details are relevant if one wants to try to understand the code. They are not part of the interface.
read that again bestie β not part of the interface. it's lore, not contract π₯
In this version:
T(2): row block size (MB)T(3): column block size (NB)T(6:TSIZE): data structure needed for Q, computed byCLATSQRorCGEQRT
Depending on the matrix dimensions M and N, and row and column block sizes MB and NB returned by ILAENV, CGEQR will use either CLATSQR (if the matrix is tall-and-skinny) or CGEQRT to compute the QR factorization. This version of CGEMQR will use either CLAMTSQR or CGEMQRT to multiply matrix Q by another matrix. Further Details in CLAMTSQR or CGEMQRT. π
Definition at line 173 of file cgemqr.f.
π subroutine dgemqr
subroutine dgemqr (character side, character trans, integer m, integer n,
integer k, double precision, dimension( lda, * ) a, integer lda, double
precision, dimension( * ) t, integer tsize, double precision, dimension(
ldc, * ) c, integer ldc, double precision, dimension( * ) work, integer
lwork, integer info)
DGEMQR
β Purpose
DGEMQR overwrites the general real M-by-N matrix C with π
SIDE = 'L' SIDE = 'R'
TRANS = 'N': Q * C C * Q
TRANS = 'T': Q**T * C C * Q**T
where Q is a real orthogonal matrix defined as the product of blocked elementary reflectors computed by tall skinny QR factorization (DGEQR). note the glow-up: no H here, it's a plain **T because we're in real land, we love a consistent queen π
π Parameters
SIDEβCHARACTER*1.= 'L': apply Q or QT from the Left;= 'R': apply Q or QT from the Right. π«ΆTRANSβCHARACTER*1.= 'N': No transpose, apply Q;= 'T': Transpose, apply Q**T. πΈMβINTEGER. The number of rows of the matrix A.M >=0.NβINTEGER. The number of columns of the matrix C.N >= 0.KβINTEGER. The number of elementary reflectors whose product defines the matrix Q. IfSIDE = 'L',M >= K >= 0; ifSIDE = 'R',N >= K >= 0. β¨AβDOUBLE PRECISIONarray, dimension(LDA,K). Part of the data structure to represent Q as returned byDGEQR. πLDAβINTEGER. The leading dimension of the array A. IfSIDE = 'L',LDA >= max(1,M); ifSIDE = 'R',LDA >= max(1,N).TβDOUBLE PRECISIONarray, dimension(MAX(5,TSIZE)). Part of the data structure to represent Q as returned byDGEQR. πTSIZEβINTEGER. The dimension of the array T.TSIZE >= 5.CβDOUBLE PRECISIONarray, dimension(LDC,N). On entry, the M-by-N matrix C. On exit, C is overwritten byQ*CorQ**T*CorC*Q**TorC*Q. πLDCβINTEGER. The leading dimension of the array C.LDC >= max(1,M).WORKβ (workspace)DOUBLE PRECISIONarray, dimension(MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the minimalLWORK. βLWORKβINTEGER. The dimension of the arrayWORK.LWORK >= 1. IfLWORK = -1, then a workspace query is assumed. The routine only calculates the size of theWORKarray, returns this value asWORK(1), and no error message related toWORKis issued byXERBLA. π¦INFOβINTEGER.= 0: successful exit.< 0: ifINFO = -i, the i-th argument had an illegal value. π
π Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
π§ Further Details
These details are particular for this LAPACK implementation. Users should not take them for granted. These details may change in the future, and are not likely true for another LAPACK implementation. These details are relevant if one wants to try to understand the code. They are not part of the interface.
In this version:
T(2): row block size (MB)T(3): column block size (NB)T(6:TSIZE): data structure needed for Q, computed byDLATSQRorDGEQRT
Depending on the matrix dimensions M and N, and row and column block sizes MB and NB returned by ILAENV, DGEQR will use either DLATSQR (if the matrix is tall-and-skinny) or DGEQRT to compute the QR factorization. This version of DGEMQR will use either DLAMTSQR or DGEMQRT to multiply matrix Q by another matrix. Further Details in DLATMSQR or DGEMQRT. π
ngl that last reference says DLATMSQR in the original and I am not touching it, character for character, we do not edit the lore π
Definition at line 173 of file dgemqr.f.
π subroutine sgemqr
subroutine sgemqr (character side, character trans, integer m, integer n,
integer k, real, dimension( lda, * ) a, integer lda, real, dimension( *
) t, integer tsize, real, dimension( ldc, * ) c, integer ldc, real,
dimension( * ) work, integer lwork, integer info)
SGEMQR
β Purpose
SGEMQR overwrites the general real M-by-N matrix C with π
SIDE = 'L' SIDE = 'R'
TRANS = 'N': Q * C C * Q
TRANS = 'T': Q**T * C C * Q**T
where Q is a real orthogonal matrix defined as the product of blocked elementary reflectors computed by tall skinny QR factorization (SGEQR). π
π Parameters
SIDEβ¦
okay that's where part 1 wraps, bestie β sgemqr's parameters and the whole zgemqr situation are rolling in next, don't go anywhere π
SIDEβ it's aCHARACTER*1, bestie.'L'means applyQorQ**Tfrom the Left;'R'means applyQorQ**Tfrom the Right. Pick a side πTRANSβ alsoCHARACTER*1.'N'= no transpose, applyQ;'T'= transpose, applyQ**T. That's the whole vibe check β¨MβINTEGER, the number of rows of matrixA. Constraint:M >=0.NβINTEGER, the number of columns of matrixC. Constraint:N >= 0.KβINTEGER, the number of elementary reflectors whose product defines the matrixQ. IfSIDE = 'L', thenM >= K >= 0; ifSIDE = 'R', thenN >= K >= 0.AβREAL array, dimension(LDA,K). Part of the data structure to representQas returned bySGEQR.LDAβINTEGER, the leading dimension of the arrayA. IfSIDE = 'L',LDA >= max(1,M); ifSIDE = 'R',LDA >= max(1,N).TβREAL array, dimension(MAX(5,TSIZE)). Part of the data structure to representQas returned bySGEQR.TSIZEβINTEGER, the dimension of the arrayT. Constraint:TSIZE >= 5.CβREAL array, dimension(LDC,N). On entry, theM-by-NmatrixC. On exit,Cis overwritten byQ*CorQ**T*CorC*Q**TorC*Q.LDCβINTEGER, the leading dimension of the arrayC. Constraint:LDC >= max(1,M).WORKβ(workspace) REAL array, dimension(MAX(1,LWORK)).LWORKβINTEGER, the dimension of the arrayWORK. IfLWORK = -1, then a workspace query is assumed. The routine only calculates the size of theWORKarray, returns this value asWORK(1), and no error message related toWORKis issued byXERBLA.INFOβINTEGER.= 0: successful exit.< 0: ifINFO = -i, thei-th argument had an illegal value.
π Author
Shoutout to the legends who wrote this:
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
π§ Further Details
β οΈ Okay, tea time: these details are particular for this LAPACK implementation. Users should not take them for granted. These details may change in the future, and they are not likely true for another LAPACK implementation. These details are relevant if one wants to try to understand the code. They are not part of the interface.
In this version:
T(2): row block size (MB)T(3): column block size (NB)T(6:TSIZE): data structure needed forQ, computed bySLATSQRorSGEQRT
Depending on the matrix dimensions M and N, and row and column block sizes MB and NB returned by ILAENV, SGEQR will use either SLATSQR (if the matrix is tall-and-skinny) or SGEQRT to compute the QR factorization. This version of SGEMQR will use either SLAMTSQR or SGEMQRT to multiply matrix Q by another matrix. Further Details in SLAMTSQR or SGEMQRT.
Definition at line 172 of file sgemqr.f.
π¦ zgemqr β ZGEMQR, the complex*16 edition
subroutine zgemqr (character side, character trans, integer m, integer n,
integer k, complex*16, dimension( lda, * ) a, integer lda, complex*16,
dimension( * ) t, integer tsize, complex*16, dimension( ldc, * ) c,
integer ldc, complex*16, dimension( * ) work, integer lwork, integer
info)
πΈ Purpose
ZGEMQR overwrites the general real M-by-N matrix C with:
SIDE = 'L' SIDE = 'R'
TRANS = 'N': Q * C C * Q
TRANS = 'T': Q**H * C C * Q**H
where Q is a complex unitary matrix defined as the product of blocked elementary reflectors computed by tall skinny QR factorization (ZGEQR).
π Parameters
SIDEβCHARACTER*1.'L': applyQorQ**Hfrom the Left;'R': applyQorQ**Hfrom the Right.TRANSβCHARACTER*1.'N': no transpose, applyQ;'C': conjugate transpose, applyQ**H.MβINTEGER, the number of rows of the matrixA. Constraint:M >=0.NβINTEGER, the number of columns of the matrixC. Constraint:N >= 0.KβINTEGER, the number of elementary reflectors whose product defines the matrixQ. IfSIDE = 'L', thenM >= K >= 0; ifSIDE = 'R', thenN >= K >= 0.AβCOMPLEX*16 array, dimension(LDA,K). Part of the data structure to representQas returned byZGEQR.LDAβINTEGER, the leading dimension of the arrayA. IfSIDE = 'L',LDA >= max(1,M); ifSIDE = 'R',LDA >= max(1,N).TβCOMPLEX*16 array, dimension(MAX(5,TSIZE)). Part of the data structure to representQas returned byZGEQR.TSIZEβINTEGER, the dimension of the arrayT. Constraint:TSIZE >= 5.CβCOMPLEX*16 array, dimension(LDC,N). On entry, theM-by-NmatrixC. On exit,Cis overwritten byQ*CorQ**H*CorC*Q**HorC*Q.LDCβINTEGER, the leading dimension of the arrayC. Constraint:LDC >= max(1,M).WORKβ(workspace) COMPLEX*16 array, dimension(MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the minimalLWORK.LWORKβINTEGER, the dimension of the arrayWORK. Constraint:LWORK >= 1. IfLWORK = -1, then a workspace query is assumed. The routine only calculates the size of theWORKarray, returns this value asWORK(1), and no error message related toWORKis issued byXERBLA.INFOβINTEGER.= 0: successful exit.< 0: ifINFO = -i, thei-th argument had an illegal value.
β¨ Author
Same absolute icons:
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
π₯ Further Details
β οΈ Again for the people in the back: these details are particular for this LAPACK implementation. Users should not take them for granted. These details may change in the future, and they are not likely true for another LAPACK implementation. These details are relevant if one wants to try to understand the code. They are not part of the interface.
In this version:
T(2): row block size (MB)T(3): column block size (NB)T(6:TSIZE): data structure needed forQ, computed byZLATSQRorZGEQRT
Depending on the matrix dimensions M and N, and row and column block sizes MB and NB returned by ILAENV, ZGEQR will use either ZLATSQR (if the matrix is tall-and-skinny) or ZGEQRT to compute the QR factorization. This version of ZGEMQR will use either ZLAMTSQR or ZGEMQRT to multiply matrix Q by another matrix. Further Details in ZLAMTSQR or ZGEMQRT.
Definition at line 173 of file zgemqr.f.
This whole page got generated automatically by Doxygen for LAPACK from the source code β iconic tooling behavior, no cap.
That's a wrap on gemqr(3), bestie! Straight from LAPACK Version 3.12.0, page gemqr(3) β mwah π
π¦ 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