Computes the QR factorization of a general m-by-n matrix with non-negative diagonal elements.
The routine forms the
QRfactorization of a general
A(see Orthogonal Factorizations). No pivoting is performed. The diagonal entries of
Rare real and nonnegative.
The routine does not form the matrix
Qis represented as a product of min(
n) elementary reflectors. Routines are provided to work with
Qin this representation.
- The number of rows in the matrixINTEGER.A().m≥0
- The number of columns inINTEGER.A().n≥0
- REALforsgeqrfpDOUBLE PRECISIONfordgeqrfpCOMPLEXforcgeqrfpDOUBLE COMPLEXforzgeqrfp.Arrays:a(lda,*) contains the matrixA. The second dimension ofamust be at least max(1,n).workis a workspace array, its dimensionmax(1,.lwork)
- The leading dimension ofINTEGER.a; at least max(1,m).
- The size of theINTEGER.workarray ().lwork≥nIf, then a workspace query is assumed; the routine only calculates the optimal size of thelwork= -1workarray, returns this value as the first entry of theworkarray, and no error message related tolworkis issued by xerbla.See Application Notes for the suggested value oflwork.
- Overwritten by the factorization data as follows:The elements on and above the diagonal of the array contain the min(m,n)-by-nupper trapezoidal matrixR(Ris upper triangular ifm≥n); the elements below the diagonal, with the arraytau, present the orthogonal matrixQas a product of min(m,n) elementary reflectors (see Orthogonal Factorizations).