SRC/dgglse.f(3)
π§ SRC/dgglse.f π§
okay bestie, welcome to the Library Functions Manual page for SRC/dgglse.f β yes it's a .f file, yes it's iconic, and yes we're getting into it π
. This is the dgglse subroutine documentation, and I promise we're keeping every single detail. No cap.
πΈ NAME πΈ
SRC/dgglse.f
β¨ SYNOPSIS β¨
π Functions/Subroutines π
subroutine dgglse (m, n, p, a, lda, b, ldb, c, d, x, work, lwork, info)β DGGLSE solves overdetermined or underdetermined systems for OTHER matrices π«Ά
π¦ Function/Subroutine Documentation π¦
subroutine dgglse (integer m, integer n, integer p, double precision,
dimension( lda, * ) a, integer lda, double precision, dimension( ldb, *
) b, integer ldb, double precision, dimension( * ) c, double precision,
dimension( * ) d, double precision, dimension( * ) x, double precision,
dimension( * ) work, integer lwork, integer info)
DGGLSE solves overdetermined or underdetermined systems for OTHER matrices β yes, "OTHER" is doing a lot of work here, but it's exactly what the page says, so we're keeping it.
π Purpose π
ok so DGGLSE solves the linear equality-constrained least squares (LSE) problem:
minimize || c - A*x ||_2 subject to B*x = d
where A is an M-by-N matrix, B is a P-by-N matrix, c is a given M-vector, and d is a given P-vector. It is assumed that P <= N <= M+P, and
rank(B) = P and rank( (A) ) = N.
( (B) )
These conditions ensure that the LSE problem has a unique solution, which is obtained using a generalized RQ factorization of the matrices (B, A) given by
B = (0 R)*Q, A = Z*T*Q.
Callers of this subroutine should note that the singularity/rank-deficiency checks implemented in this subroutine are rudimentary. The DTRTRS subroutine called by this subroutine only signals a failure due to singularity if the problem is exactly singular.
It is conceivable for one (or more) of the factors involved in the generalized RQ factorization of the pair (B, A) to be subnormally close to singularity without this subroutine signalling an error. The solutions computed for such almost-rank-deficient problems may be less accurate due to a loss of numerical precision. π this is important, bestie.
π Parameters π
MβM is INTEGER. The number of rows of the matrixA.M >= 0.NβN is INTEGER. The number of columns of the matricesAandB.N >= 0.PβP is INTEGER. The number of rows of the matrixB.0 <= P <= N <= M+P.AβA is DOUBLE PRECISION array, dimension (LDA,N). On entry, theM-by-NmatrixA. On exit, the elements on and above the diagonal of the array contain themin(M,N)-by-Nupper trapezoidal matrixT.LDAβLDA is INTEGER. The leading dimension of the arrayA.LDA >= max(1,M).BβB is DOUBLE PRECISION array, dimension (LDB,N). On entry, theP-by-NmatrixB. On exit, the upper triangle of the subarrayB(1:P,N-P+1:N)contains theP-by-Pupper triangular matrixR.LDBβLDB is INTEGER. The leading dimension of the arrayB.LDB >= max(1,P).CβC is DOUBLE PRECISION array, dimension (M). On entry,Ccontains the right hand side vector for the least squares part of the LSE problem. On exit, the residual sum of squares for the solution is given by the sum of squares of elementsN-P+1toMof vectorC.DβD is DOUBLE PRECISION array, dimension (P). On entry,Dcontains the right hand side vector for the constrained equation. On exit,Dis destroyed. πXβX is DOUBLE PRECISION array, dimension (N). On exit,Xis the solution of the LSE problem. slay.WORKβWORK is DOUBLE PRECISION array, dimension (MAX(1,LWORK)). On exit, ifINFO = 0,WORK(1)returns the optimalLWORK.LWORKβLWORK is INTEGER. The dimension of the arrayWORK.LWORK >= max(1,M+N+P). For optimum performanceLWORK >= P+min(M,N)+max(M,N)*NB, whereNBis an upper bound for the optimal blocksizes forDGEQRF,SGERQF,DORMQRandSORMRQ. 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 theWORKarray, and no error message related toLWORKis issued byXERBLA.INFOβINFO is INTEGER.= 0: successful exit.< 0: ifINFO = -i, thei-th argument had an illegal value.= 1: the upper triangular factorRassociated withBin the generalized RQ factorization of the pair(B, A)is exactly singular, so thatrank(B) < P; the least squares solution could not be computed.= 2: the(N-P)by(N-P)part of the upper trapezoidal factorTassociated withAin the generalized RQ factorization of the pair(B, A)is exactly singular, so that
rank( (A) ) < N
( (B) )
the least squares solution could not be computed.
π Author π
- Univ. of Tennessee
- Univ. of California Berkeley
- Univ. of Colorado Denver
- NAG Ltd.
Definition at line 188 of file dgglse.f.
π Author π
Generated automatically by Doxygen for LAPACK from the source code.
that's the whole page, bestie π«Ά no details left behind, periodt. kisses from your Unix group chat π β LAPACK, Version 3.12.0, SRC/dgglse.f(3).
π¦ 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