DBBCSD(3)
๐ DBBCSD(3) โ like, the whole entire manual, bestie
okay so this is from the Library Functions Manual, and the file it lives in is literally /home/abuild/rpmbuild/BUILD/lapack-static-3.12.0-build/lapack-3.12.0/SRC/dbbcsd.f โ that's the name section, that's the vibe, we move. ๐
โจ SYNOPSIS โจ
Functions/Subroutines
subroutine DBBCSD (jobu1, jobu2, jobv1t, jobv2t, trans, m, p, q, theta,
phi, u1, ldu1, u2, ldu2, v1t, ldv1t, v2t, ldv2t, b11d, b11e, b12d,
b12e, b21d, b21e, b22d, b22e, work, lwork, info)
That's DBBCSD, bestie. Say it with me: DBBCSD. ๐ฆ
๐ธ Function/Subroutine Documentation ๐ธ
subroutine DBBCSD (character jobu1, character jobu2, character jobv1t,
character jobv2t, character trans, integer m, integer p, integer q,
double precision, dimension( * ) theta, double precision, dimension( * )
phi, double precision, dimension( ldu1, * ) u1, integer ldu1, double
precision, dimension( ldu2, * ) u2, integer ldu2, double precision,
dimension( ldv1t, * ) v1t, integer ldv1t, double precision, dimension(
ldv2t, * ) v2t, integer ldv2t, double precision, dimension( * ) b11d,
double precision, dimension( * ) b11e, double precision, dimension( * )
b12d, double precision, dimension( * ) b12e, double precision,
dimension( * ) b21d, double precision, dimension( * ) b21e, double
precision, dimension( * ) b22d, double precision, dimension( * ) b22e,
double precision, dimension( * ) work, integer lwork, integer info)
DBBCSD. yes, again. it's iconic like that. ๐
๐ซถ Purpose ๐ซถ
okay so listen โ DBBCSD computes the CS decomposition of an orthogonal matrix in bidiagonal-block form. and the form is giving:
[ B11 | B12 0 0 ]
[ 0 | 0 -I 0 ]
X = [----------------]
[ B21 | B22 0 0 ]
[ 0 | 0 0 I ]
and then, the glow-up:
[ C | -S 0 0 ]
[ U1 | ] [ 0 | 0 -I 0 ] [ V1 | ]**T
= [---------] [---------------] [---------] .
[ | U2 ] [ S | C 0 0 ] [ | V2 ]
[ 0 | 0 0 I ]
so X is M-by-M, its top-left block is P-by-Q, and Q must be no larger than P, M-P, or M-Q. and like โ if Q is not the smallest index, then X must be transposed and/or permuted. that's totally doable in constant time using the TRANS and SIGNS options. see DORCSD for the deets, iykyk. ๐ซ
the bidiagonal matrices B11, B12, B21, and B22 are represented implicitly by angles THETA(1:Q) and PHI(1:Q-1).
and the orthogonal matrices U1, U2, V1T, and V2T are input/output โ the input matrices are pre- or post-multiplied by the appropriate singular vector matrices. main character matrices, honestly. ๐
๐ Parameters ๐
JOBU1โJOBU1isCHARACTER.= 'Y':U1is updated; otherwise:U1is not updated. ๐JOBU2โJOBU2isCHARACTER.= 'Y':U2is updated; otherwise:U2is not updated. ๐JOBV1TโJOBV1TisCHARACTER.= 'Y':V1Tis updated; otherwise:V1Tis not updated. ๐JOBV2TโJOBV2TisCHARACTER.= 'Y':V2Tis updated; otherwise:V2Tis not updated. ๐TRANSโTRANSisCHARACTER.= 'T':X,U1,U2,V1T, andV2Tare stored in row-major order; otherwise:X,U1,U2,V1T, andV2Tare stored in column-major order. ๐MโMisINTEGER. the number of rows and columns inX, the orthogonal matrix in bidiagonal-block form. ๐PโPisINTEGER. the number of rows in the top-left block ofX.0 <= P <= M. ๐QโQisINTEGER. the number of columns in the top-left block ofX.0 <= Q <= MIN(P,M-P,M-Q). ๐ฏTHETAโTHETAisDOUBLE PRECISIONarray, dimension(Q). on entry, the anglesTHETA(1),...,THETA(Q)that, along withPHI(1), ...,PHI(Q-1), define the matrix in bidiagonal-block form. on exit, the angles whose cosines and sines define the diagonal blocks in the CS decomposition. angles ate and left no crumbs. ๐PHIโPHIisDOUBLE PRECISIONarray, dimension(Q-1). the anglesPHI(1),...,PHI(Q-1)that, along withTHETA(1),...,THETA(Q), define the matrix in bidiagonal-block form. ๐U1โU1isDOUBLE PRECISIONarray, dimension(LDU1,P). on entry, a P-by-P matrix. on exit,U1is postmultiplied by the left singular vector matrix common to[ B11 ; 0 ]and[ B12 0 0 ; 0 -I 0 0 ]. ๐LDU1โLDU1isINTEGER. the leading dimension of the arrayU1,LDU1 >= MAX(1,P). โจU2โU2isDOUBLE PRECISIONarray, dimension(LDU2,M-P). on entry, an (M-P)-by-(M-P) matrix. on exit,U2is postmultiplied by the left singular vector matrix common to[ B21 ; 0 ]and[ B22 0 0 ; 0 0 I ]. ๐LDU2โLDU2isINTEGER. the leading dimension of the arrayU2,LDU2 >= MAX(1,M-P). โจV1TโV1TisDOUBLE PRECISIONarray, dimension(LDV1T,Q). on entry, a Q-by-Q matrix. on exit,V1Tis premultiplied by the transpose of the right singular vector matrix common to[ B11 ; 0 ]and[ B21 ; 0 ]. ๐ฆLDV1TโLDV1TisINTEGER. the leading dimension of the arrayV1T,LDV1T >= MAX(1,Q). โจV2TโV2TisDOUBLE PRECISIONarray, dimension(LDV2T,M-Q). on entry, an (M-Q)-by-(M-Q) matrix. on exit,V2Tis premultiplied by the transpose of the right singular vector matrix common to[ B12 0 0 ; 0 -I 0 ]and[ B22 0 0 ; 0 0 I ]. ๐ฆLDV2TโLDV2TisINTEGER. the leading dimension of the arrayV2T,LDV2T >= MAX(1,M-Q). โจB11DโB11DisDOUBLE PRECISIONarray, dimension(Q). whenDBBCSDconverges,B11Dcontains the cosines ofTHETA(1), ..., THETA(Q). ifDBBCSDfails to converge, thenB11Dcontains the diagonal of the partially reduced top-left block. ๐ญ (we believe in convergence in this house)B11EโB11EisDOUBLE PRECISIONarray, dimension(Q-1). whenDBBCSDconverges,B11Econtains zeros. ifDBBCSDfails to converge, thenB11Econtains the superdiagonal of the partially reduced top-left block. ๐ญB12DโB12DisDOUBLE PRECISIONarray, dimension(Q). whenDBBCSDconverges,B12Dcontains the negative sines ofTHETA(1), ..., THETA(Q). ifDBBCSDfails to converge, thenB12Dcontains the diagonal of the partially reduced top-right block. ๐ญB12EโB12EisDOUBLE PRECISIONarray, dimension(Q-1). whenDBBCSDconverges,B12Econtains zeros. ifDBBCSDfails to converge, thenB12Econtains the subdiagonal of the partially reduced top-right block. ๐ญB21DโB21DisDOUBLE PRECISIONarray, dimension(Q). whenDBBCSDconverges,B21Dcontains the negative sines ofTHETA(1), ..., THETA(Q). ifDBBCSDfails to converge, thenB21Dcontains the diagonal of the partially reduced bottom-left block. ๐ญB21EโB21EisDOUBLE PRECISIONarray, dimension(Q-1). whenDBBCSDconverges,B21Econtains zeros. ifDBBCSDfails to converge, thenB21Econtains the subdiagonal of the partially reduced bottom-left block. ๐ญB22DโB22DisDOUBLE PRECISIONarray, dimension(Q). whenDBBCSDconverges,B22Dcontains the negative sines ofTHETA(1), ..., THETA(Q). ifDBBCSDfails to converge, thenB22Dcontains the diagonal of the partially reduced bottom-right block. ๐ญB22EโB22EisDOUBLE PRECISIONarray, dimension(Q-1). whenDBBCSDconverges,B22Econtains zeros. ifDBBCSDfails to converge, thenB22Econtains the subdiagonal of the partially reduced bottom-right block. ๐ญWORKโWORKisDOUBLE PRECISIONarray, dimension(MAX(1,LWORK)). on exit, ifINFO = 0,WORK(1)returns the optimalLWORK. ๐ธLWORKโLWORKisINTEGER. the dimension of the arrayWORK.LWORK >= MAX(1,8*Q).
and listen: ifLWORK = -1, then a workspace query is assumed โ the routine only calculates the optimal size of theWORKarray, returns this value as the first entry of the work array, and no error message related toLWORKis issued byXERBLA. so don't come forXERBLA, it's literally minding its business. ๐
INFOโINFOisINTEGER.= 0: successful exit. slay. ๐< 0: ifINFO = -i, the i-th argument had an illegal value. ๐> 0: ifDBBCSDdid not converge,INFOspecifies the number of nonzero entries inPHI, andB11D,B11E, etc., contain the partially reduced matrix. ๐ญ
๐ฎ Internal Parameters ๐ฎ
TOLMULโDOUBLE PRECISION, default= MAX(10,MIN(100,EPS**(-1/8))).TOLMULcontrols the convergence criterion of the QR loop. anglesTHETA(i),PHI(i)are rounded to0orPI/2when they are withinTOLMUL*EPSof either bound. lowkey the vibe check of the whole algorithm, ngl. ๐ง
๐ References ๐
- Brian D. Sutton. Computing the complete CS decomposition. Numer. Algorithms, 50(1):33-65, 2009. (bestie wrote a paper, we stan an academic icon ๐)
๐บ Author ๐บ
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 328 of file dbbcsd.f. ๐
๐ฆ Author (again, yes) ๐ฆ
Generated automatically by Doxygen for LAPACK from the source code. not a human, just vibes and a parser. ๐คโจ
so yeah, that's the whole page, nothing skipped, every flag and array and INFO code accounted for, fr fr. this came to you from LAPACK, Version 3.12.0, living at /home/abui...RC/dbbcsd.f(3) โ mwah, bye bestie, go decompose something orthogonally ๐
๐๐
๐ฆ 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