1DGGLSE(1)             LAPACK driver routine (version 3.2)            DGGLSE(1)
2
3
4

NAME

6       DGGLSE  -  solves  the  linear equality-constrained least squares (LSE)
7       problem
8

SYNOPSIS

10       SUBROUTINE DGGLSE( M, N, P, A, LDA, B, LDB, C, D, X, WORK, LWORK,  INFO
11                          )
12
13           INTEGER        INFO, LDA, LDB, LWORK, M, N, P
14
15           DOUBLE         PRECISION  A( LDA, * ), B( LDB, * ), C( * ), D( * ),
16                          WORK( * ), X( * )
17

PURPOSE

19       DGGLSE solves the linear equality-constrained least squares (LSE) prob‐
20       lem:
21               minimize || c - A*x ||_2   subject to   B*x = d
22       where  A is an M-by-N matrix, B is a P-by-N matrix, c is a given M-vec‐
23       tor, and d is a given P-vector. It is assumed that
24       P <= N <= M+P, and
25                rank(B) = P and  rank( (A) ) = N.
26                                     ( (B) )
27       These conditions ensure that the LSE problem  has  a  unique  solution,
28       which  is obtained using a generalized RQ factorization of the matrices
29       (B, A) given by
30          B = (0 R)*Q,   A = Z*T*Q.
31

ARGUMENTS

33       M       (input) INTEGER
34               The number of rows of the matrix A.  M >= 0.
35
36       N       (input) INTEGER
37               The number of columns of the matrices A and B. N >= 0.
38
39       P       (input) INTEGER
40               The number of rows of the matrix B. 0 <= P <= N <= M+P.
41
42       A       (input/output) DOUBLE PRECISION array, dimension (LDA,N)
43               On entry, the M-by-N matrix A.  On exit, the  elements  on  and
44               above the diagonal of the array contain the min(M,N)-by-N upper
45               trapezoidal matrix T.
46
47       LDA     (input) INTEGER
48               The leading dimension of the array A. LDA >= max(1,M).
49
50       B       (input/output) DOUBLE PRECISION array, dimension (LDB,N)
51               On entry, the P-by-N matrix B.  On exit, the upper triangle  of
52               the  subarray B(1:P,N-P+1:N) contains the P-by-P upper triangu‐
53               lar matrix R.
54
55       LDB     (input) INTEGER
56               The leading dimension of the array B. LDB >= max(1,P).
57
58       C       (input/output) DOUBLE PRECISION array, dimension (M)
59               On entry, C contains the right hand side vector for  the  least
60               squares  part of the LSE problem.  On exit, the residual sum of
61               squares for the solution is given by the sum of squares of ele‐
62               ments N-P+1 to M of vector C.
63
64       D       (input/output) DOUBLE PRECISION array, dimension (P)
65               On  entry,  D  contains the right hand side vector for the con‐
66               strained equation.  On exit, D is destroyed.
67
68       X       (output) DOUBLE PRECISION array, dimension (N)
69               On exit, X is the solution of the LSE problem.
70
71       WORK      (workspace/output)   DOUBLE   PRECISION   array,    dimension
72       (MAX(1,LWORK))
73               On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
74
75       LWORK   (input) INTEGER
76               The  dimension  of  the array WORK. LWORK >= max(1,M+N+P).  For
77               optimum performance LWORK >= P+min(M,N)+max(M,N)*NB,  where  NB
78               is  an  upper  bound  for  the  optimal  blocksizes for DGEQRF,
79               SGERQF, DORMQR and SORMRQ.  If LWORK =  -1,  then  a  workspace
80               query  is assumed; the routine only calculates the optimal size
81               of the WORK array, returns this value as the first entry of the
82               WORK  array, and no error message related to LWORK is issued by
83               XERBLA.
84
85       INFO    (output) INTEGER
86               = 0:  successful exit.
87               < 0:  if INFO = -i, the i-th argument had an illegal value.
88               = 1:  the upper triangular factor R associated with  B  in  the
89               generalized RQ factorization of the pair (B, A) is singular, so
90               that rank(B) < P; the least squares solution could not be  com‐
91               puted.   = 2:  the (N-P) by (N-P) part of the upper trapezoidal
92               factor T associated with A in the generalized RQ  factorization
93               of  the  pair  (B, A) is singular, so that rank( (A) ) < N; the
94               least squares solution could not ( (B) ) be computed.
95
96
97
98 LAPACK driver routine (version 3.N2o)vember 2008                       DGGLSE(1)
Impressum