-
template<typename T>
void geqr2(integer *m, integer *n, T *a, integer *lda, T *tau, T *work, integer *info)# QR factorization of a real m-by-n matrix a.
Purpose:
QR factorization of a real m-by-n matrix a The factorization has the form A = Q * R
- Parameters:
m – [in]
m is integer*
The number of rows of the matrix a. m >= 0.
n – [in]
n is integer*
The number of columns of the matrix a. n >= 0.
a – [inout]
a is float/double/COMPLEX/COMPLEX*16 array, dimension (lda,n)
On entry, the m-by-n matrix to be factored.
On exit, the elements on and above the diagonal of the array contain the min(m,n)-by-n upper trapezoidal matrix R (R is upper triangular if m >= n); the elements below the diagonal, with the array tau, represent the orthogonal matrix Q as a product of elementary reflectors (see Further Details).lda – [in]
lda is integer*
The leading dimension of the matrix a, lda >= fla_max(1,m)
tau – [out]
tau is float/double/COMPLEX/COMPLEX*16 array, dimension (min(m,n))
The scalar factors of the elementary reflectors (see Further Details).
Further DetailsThe matrix Q is represented as a product of elementary reflectors Q = H(1) H(2) . . . H(k), where k = min(m,n). Each H(i) has the form H(i) = I - tau * V * V**T where, tau is a real scalar, and V is a real vector with V(1:i-1) = 0 and V(i) = 1; V(i+1:M) is stored on exit in A(i+1:M,i), and tau in tau(i).
WORK – [out] WORK is COMPLEX array, dimension (N)
INFO – [out]
INFO is INTEGER
= 0: successful exit
< 0: if INFO = -i, the i-th argument had an illegal value