MAGMA  2.7.1
Matrix Algebra for GPU and Multicore Architectures
 All Classes Files Functions Friends Groups Pages
or/unglq: Generate Q from LQ factorization

Functions

magma_int_t magma_cunglq (magma_int_t m, magma_int_t n, magma_int_t k, magmaFloatComplex *A, magma_int_t lda, magmaFloatComplex *tau, magmaFloatComplex *work, magma_int_t lwork, magma_int_t *info)
 

Purpose:

CUNGLQ generates an M-by-N complex matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N More...
 
magma_int_t magma_dorglq (magma_int_t m, magma_int_t n, magma_int_t k, double *A, magma_int_t lda, double *tau, double *work, magma_int_t lwork, magma_int_t *info)
 

Purpose:

DORGLQ generates an M-by-N real matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N More...
 
magma_int_t magma_sorglq (magma_int_t m, magma_int_t n, magma_int_t k, float *A, magma_int_t lda, float *tau, float *work, magma_int_t lwork, magma_int_t *info)
 

Purpose:

SORGLQ generates an M-by-N real matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N More...
 
magma_int_t magma_zunglq (magma_int_t m, magma_int_t n, magma_int_t k, magmaDoubleComplex *A, magma_int_t lda, magmaDoubleComplex *tau, magmaDoubleComplex *work, magma_int_t lwork, magma_int_t *info)
 

Purpose:

ZUNGLQ generates an M-by-N complex matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N More...
 

Detailed Description

Function Documentation

magma_int_t magma_cunglq ( magma_int_t  m,
magma_int_t  n,
magma_int_t  k,
magmaFloatComplex *  A,
magma_int_t  lda,
magmaFloatComplex *  tau,
magmaFloatComplex *  work,
magma_int_t  lwork,
magma_int_t *  info 
)

Purpose:

CUNGLQ generates an M-by-N complex matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N

Q  =  H(k)**H . . . H(2)**H H(1)**H

as returned by CGELQF.

Arguments:

Parameters
[in]mINTEGER The number of rows of the matrix Q. M >= 0.
[in]nINTEGER The number of columns of the matrix Q. N >= M.
[in]kINTEGER The number of elementary reflectors whose product defines the matrix Q. M >= K >= 0.
[in,out]ACOMPLEX array, dimension (LDA,N) On entry, the i-th row must contain the vector which defines the elementary reflector H(i), for i = 1,2,...,k, as returned by CGELQF in the first k rows of its array argument A. On exit, the M-by-N matrix Q.
[in]ldaINTEGER The first dimension of the array A. LDA >= max(1,M).
[in]tauCOMPLEX array, dimension (K) TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by CGELQF.
[out]workCOMPLEX array, dimension (MAX(1,LWORK)) On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
[in]lworkINTEGER The dimension of the array WORK. LWORK >= M*NB, where NB is the optimal blocksize.

If LWORK = -1, a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

Parameters
[out]infoINTEGER
  • = 0: successful exit;
  • < 0: if INFO = -i, the i-th argument had an illegal value
magma_int_t magma_dorglq ( magma_int_t  m,
magma_int_t  n,
magma_int_t  k,
double *  A,
magma_int_t  lda,
double *  tau,
double *  work,
magma_int_t  lwork,
magma_int_t *  info 
)

Purpose:

DORGLQ generates an M-by-N real matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N

Q  =  H(k)**H . . . H(2)**H H(1)**H

as returned by DGELQF.

Arguments:

Parameters
[in]mINTEGER The number of rows of the matrix Q. M >= 0.
[in]nINTEGER The number of columns of the matrix Q. N >= M.
[in]kINTEGER The number of elementary reflectors whose product defines the matrix Q. M >= K >= 0.
[in,out]ADOUBLE PRECISION array, dimension (LDA,N) On entry, the i-th row must contain the vector which defines the elementary reflector H(i), for i = 1,2,...,k, as returned by DGELQF in the first k rows of its array argument A. On exit, the M-by-N matrix Q.
[in]ldaINTEGER The first dimension of the array A. LDA >= max(1,M).
[in]tauDOUBLE PRECISION array, dimension (K) TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by DGELQF.
[out]workDOUBLE PRECISION array, dimension (MAX(1,LWORK)) On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
[in]lworkINTEGER The dimension of the array WORK. LWORK >= M*NB, where NB is the optimal blocksize.

If LWORK = -1, a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

Parameters
[out]infoINTEGER
  • = 0: successful exit;
  • < 0: if INFO = -i, the i-th argument had an illegal value
magma_int_t magma_sorglq ( magma_int_t  m,
magma_int_t  n,
magma_int_t  k,
float *  A,
magma_int_t  lda,
float *  tau,
float *  work,
magma_int_t  lwork,
magma_int_t *  info 
)

Purpose:

SORGLQ generates an M-by-N real matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N

Q  =  H(k)**H . . . H(2)**H H(1)**H

as returned by SGELQF.

Arguments:

Parameters
[in]mINTEGER The number of rows of the matrix Q. M >= 0.
[in]nINTEGER The number of columns of the matrix Q. N >= M.
[in]kINTEGER The number of elementary reflectors whose product defines the matrix Q. M >= K >= 0.
[in,out]AREAL array, dimension (LDA,N) On entry, the i-th row must contain the vector which defines the elementary reflector H(i), for i = 1,2,...,k, as returned by SGELQF in the first k rows of its array argument A. On exit, the M-by-N matrix Q.
[in]ldaINTEGER The first dimension of the array A. LDA >= max(1,M).
[in]tauREAL array, dimension (K) TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by SGELQF.
[out]workREAL array, dimension (MAX(1,LWORK)) On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
[in]lworkINTEGER The dimension of the array WORK. LWORK >= M*NB, where NB is the optimal blocksize.

If LWORK = -1, a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

Parameters
[out]infoINTEGER
  • = 0: successful exit;
  • < 0: if INFO = -i, the i-th argument had an illegal value
magma_int_t magma_zunglq ( magma_int_t  m,
magma_int_t  n,
magma_int_t  k,
magmaDoubleComplex *  A,
magma_int_t  lda,
magmaDoubleComplex *  tau,
magmaDoubleComplex *  work,
magma_int_t  lwork,
magma_int_t *  info 
)

Purpose:

ZUNGLQ generates an M-by-N complex matrix Q with orthonormal rows, which is defined as the first M rows of a product of K elementary reflectors of order N

Q  =  H(k)**H . . . H(2)**H H(1)**H

as returned by ZGELQF.

Arguments:

Parameters
[in]mINTEGER The number of rows of the matrix Q. M >= 0.
[in]nINTEGER The number of columns of the matrix Q. N >= M.
[in]kINTEGER The number of elementary reflectors whose product defines the matrix Q. M >= K >= 0.
[in,out]ACOMPLEX_16 array, dimension (LDA,N) On entry, the i-th row must contain the vector which defines the elementary reflector H(i), for i = 1,2,...,k, as returned by ZGELQF in the first k rows of its array argument A. On exit, the M-by-N matrix Q.
[in]ldaINTEGER The first dimension of the array A. LDA >= max(1,M).
[in]tauCOMPLEX_16 array, dimension (K) TAU(i) must contain the scalar factor of the elementary reflector H(i), as returned by ZGELQF.
[out]workCOMPLEX_16 array, dimension (MAX(1,LWORK)) On exit, if INFO = 0, WORK(1) returns the optimal LWORK.
[in]lworkINTEGER The dimension of the array WORK. LWORK >= M*NB, where NB is the optimal blocksize.

If LWORK = -1, a workspace query is assumed; the routine only calculates the optimal size of the WORK array, returns this value as the first entry of the WORK array, and no error message related to LWORK is issued by XERBLA.

Parameters
[out]infoINTEGER
  • = 0: successful exit;
  • < 0: if INFO = -i, the i-th argument had an illegal value