getsls#
Functions
-
void sgetsls(const char *trans, const INT m, const INT n, const INT nrhs, f32 *restrict A, const INT lda, f32 *restrict B, const INT ldb, f32 *restrict work, const INT lwork, INT *info)#
SGETSLS solves overdetermined or underdetermined real linear systems involving an M-by-N matrix A, using a tall skinny QR or short wide LQ factorization of A.
It is assumed that A has full rank, and only a rudimentary protection against rank-deficient matrices is provided.
The following options are provided:
If TRANS = ‘N’ and m >= n: find the least squares solution of an overdetermined system, minimize || B - A*X ||.
If TRANS = ‘N’ and m < n: find the minimum norm solution of an underdetermined system A * X = B.
If TRANS = ‘T’ and m >= n: find the minimum norm solution of an undetermined system A**T * X = B.
If TRANS = ‘T’ and m < n: find the least squares solution of an overdetermined system, minimize || B - A**T * X ||.
Parameters
intrans= ‘N’: the linear system involves A; = ‘T’: the linear system involves A**T.
inmThe number of rows of the matrix A. m >= 0.
innThe number of columns of the matrix A. n >= 0.
innrhsThe number of right hand sides. nrhs >= 0.
inoutADouble precision array, dimension (lda, n). On entry, the M-by-N matrix A. On exit, A is overwritten by details of its QR or LQ factorization.
inldaThe leading dimension of the array A. lda >= max(1, m).
inoutBDouble precision array, dimension (ldb, nrhs). On entry, the right hand side matrix B. On exit, the solution vectors.
inldbThe leading dimension of the array B. ldb >= max(1, m, n).
outworkDouble precision array, dimension (max(1, lwork)). On exit, if info = 0, work[0] contains the optimal lwork.
inlworkThe dimension of the array work. If lwork = -1 or -2, a workspace query is assumed. If lwork = -1, returns optimal workspace size. If lwork = -2, returns minimal workspace size.
outinfo= 0: successful exit
< 0: if info = -i, the i-th argument had an illegal value
> 0: if info = i, the i-th diagonal element of the triangular factor of A is exactly zero.
void sgetsls(
const char* trans,
const INT m,
const INT n,
const INT nrhs,
f32* restrict A,
const INT lda,
f32* restrict B,
const INT ldb,
f32* restrict work,
const INT lwork,
INT* info
);
Functions
-
void dgetsls(const char *trans, const INT m, const INT n, const INT nrhs, f64 *restrict A, const INT lda, f64 *restrict B, const INT ldb, f64 *restrict work, const INT lwork, INT *info)#
DGETSLS solves overdetermined or underdetermined real linear systems involving an M-by-N matrix A, using a tall skinny QR or short wide LQ factorization of A.
It is assumed that A has full rank, and only a rudimentary protection against rank-deficient matrices is provided.
The following options are provided:
If TRANS = ‘N’ and m >= n: find the least squares solution of an overdetermined system, minimize || B - A*X ||.
If TRANS = ‘N’ and m < n: find the minimum norm solution of an underdetermined system A * X = B.
If TRANS = ‘T’ and m >= n: find the minimum norm solution of an undetermined system A**T * X = B.
If TRANS = ‘T’ and m < n: find the least squares solution of an overdetermined system, minimize || B - A**T * X ||.
Parameters
intrans= ‘N’: the linear system involves A; = ‘T’: the linear system involves A**T.
inmThe number of rows of the matrix A. m >= 0.
innThe number of columns of the matrix A. n >= 0.
innrhsThe number of right hand sides. nrhs >= 0.
inoutADouble precision array, dimension (lda, n). On entry, the M-by-N matrix A. On exit, A is overwritten by details of its QR or LQ factorization.
inldaThe leading dimension of the array A. lda >= max(1, m).
inoutBDouble precision array, dimension (ldb, nrhs). On entry, the right hand side matrix B. On exit, the solution vectors.
inldbThe leading dimension of the array B. ldb >= max(1, m, n).
outworkDouble precision array, dimension (max(1, lwork)). On exit, if info = 0, work[0] contains the optimal lwork.
inlworkThe dimension of the array work. If lwork = -1 or -2, a workspace query is assumed. If lwork = -1, returns optimal workspace size. If lwork = -2, returns minimal workspace size.
outinfo= 0: successful exit
< 0: if info = -i, the i-th argument had an illegal value
> 0: if info = i, the i-th diagonal element of the triangular factor of A is exactly zero.
void dgetsls(
const char* trans,
const INT m,
const INT n,
const INT nrhs,
f64* restrict A,
const INT lda,
f64* restrict B,
const INT ldb,
f64* restrict work,
const INT lwork,
INT* info
);
Functions
-
void cgetsls(const char *trans, const INT m, const INT n, const INT nrhs, c64 *restrict A, const INT lda, c64 *restrict B, const INT ldb, c64 *restrict work, const INT lwork, INT *info)#
CGETSLS solves overdetermined or underdetermined complex linear systems involving an M-by-N matrix A, using a tall skinny QR or short wide LQ factorization of A.
It is assumed that A has full rank, and only a rudimentary protection against rank-deficient matrices is provided.
The following options are provided:
If TRANS = ‘N’ and m >= n: find the least squares solution of an overdetermined system, minimize || B - A*X ||.
If TRANS = ‘N’ and m < n: find the minimum norm solution of an underdetermined system A * X = B.
If TRANS = ‘C’ and m >= n: find the minimum norm solution of an undetermined system A**H * X = B.
If TRANS = ‘C’ and m < n: find the least squares solution of an overdetermined system, minimize || B - A**H * X ||.
Parameters
intrans= ‘N’: the linear system involves A; = ‘C’: the linear system involves A**H.
inmThe number of rows of the matrix A. m >= 0.
innThe number of columns of the matrix A. n >= 0.
innrhsThe number of right hand sides. nrhs >= 0.
inoutASingle complex array, dimension (lda, n). On entry, the M-by-N matrix A. On exit, A is overwritten by details of its QR or LQ factorization.
inldaThe leading dimension of the array A. lda >= max(1, m).
inoutBSingle complex array, dimension (ldb, nrhs). On entry, the right hand side matrix B. On exit, the solution vectors.
inldbThe leading dimension of the array B. ldb >= max(1, m, n).
outworkSingle complex array, dimension (max(1, lwork)). On exit, if info = 0, work[0] contains the optimal lwork.
inlworkThe dimension of the array work. If lwork = -1 or -2, a workspace query is assumed. If lwork = -1, returns optimal workspace size. If lwork = -2, returns minimal workspace size.
outinfo= 0: successful exit
< 0: if info = -i, the i-th argument had an illegal value
> 0: if info = i, the i-th diagonal element of the triangular factor of A is exactly zero.
void cgetsls(
const char* trans,
const INT m,
const INT n,
const INT nrhs,
c64* restrict A,
const INT lda,
c64* restrict B,
const INT ldb,
c64* restrict work,
const INT lwork,
INT* info
);
Functions
-
void zgetsls(const char *trans, const INT m, const INT n, const INT nrhs, c128 *restrict A, const INT lda, c128 *restrict B, const INT ldb, c128 *restrict work, const INT lwork, INT *info)#
ZGETSLS solves overdetermined or underdetermined complex linear systems involving an M-by-N matrix A, using a tall skinny QR or short wide LQ factorization of A.
It is assumed that A has full rank, and only a rudimentary protection against rank-deficient matrices is provided.
The following options are provided:
If TRANS = ‘N’ and m >= n: find the least squares solution of an overdetermined system, minimize || B - A*X ||.
If TRANS = ‘N’ and m < n: find the minimum norm solution of an underdetermined system A * X = B.
If TRANS = ‘C’ and m >= n: find the minimum norm solution of an undetermined system A**H * X = B.
If TRANS = ‘C’ and m < n: find the least squares solution of an overdetermined system, minimize || B - A**H * X ||.
Parameters
intrans= ‘N’: the linear system involves A; = ‘C’: the linear system involves A**H.
inmThe number of rows of the matrix A. m >= 0.
innThe number of columns of the matrix A. n >= 0.
innrhsThe number of right hand sides. nrhs >= 0.
inoutADouble complex array, dimension (lda, n). On entry, the M-by-N matrix A. On exit, A is overwritten by details of its QR or LQ factorization.
inldaThe leading dimension of the array A. lda >= max(1, m).
inoutBDouble complex array, dimension (ldb, nrhs). On entry, the right hand side matrix B. On exit, the solution vectors.
inldbThe leading dimension of the array B. ldb >= max(1, m, n).
outworkDouble complex array, dimension (max(1, lwork)). On exit, if info = 0, work[0] contains the optimal lwork.
inlworkThe dimension of the array work. If lwork = -1 or -2, a workspace query is assumed. If lwork = -1, returns optimal workspace size. If lwork = -2, returns minimal workspace size.
outinfo= 0: successful exit
< 0: if info = -i, the i-th argument had an illegal value
> 0: if info = i, the i-th diagonal element of the triangular factor of A is exactly zero.
void zgetsls(
const char* trans,
const INT m,
const INT n,
const INT nrhs,
c128* restrict A,
const INT lda,
c128* restrict B,
const INT ldb,
c128* restrict work,
const INT lwork,
INT* info
);