gesvdx#

Functions

void sgesvdx(
    const char*          jobu,
    const char*          jobvt,
    const char*          range,
    const INT            m,
    const INT            n,
          f32*  restrict A,
    const INT            lda,
    const f32            vl,
    const f32            vu,
    const INT            il,
    const INT            iu,
          INT*           ns,
          f32*  restrict S,
          f32*  restrict U,
    const INT            ldu,
          f32*  restrict VT,
    const INT            ldvt,
          f32*  restrict work,
    const INT            lwork,
          INT*  restrict iwork,
          INT*           info
);
void sgesvdx(const char *jobu, const char *jobvt, const char *range, const INT m, const INT n, f32 *restrict A, const INT lda, const f32 vl, const f32 vu, const INT il, const INT iu, INT *ns, f32 *restrict S, f32 *restrict U, const INT ldu, f32 *restrict VT, const INT ldvt, f32 *restrict work, const INT lwork, INT *restrict iwork, INT *info)#

SGESVDX computes the singular value decomposition (SVD) of a real M-by-N matrix A, optionally computing the left and/or right singular vectors.

The SVD is written

 A = U * SIGMA * transpose(V)
where SIGMA is an M-by-N matrix which is zero except for its min(m,n) diagonal elements, U is an M-by-M orthogonal matrix, and V is an N-by-N orthogonal matrix. The diagonal elements of SIGMA are the singular values of A; they are real and non-negative, and are returned in descending order. The first min(m,n) columns of U and V are the left and right singular vectors of A.

SGESVDX uses an eigenvalue problem for obtaining the SVD, which allows for the computation of a subset of singular values and vectors. See SBDSVDX for details.

Note that the routine returns V**T, not V.

Parameters

in
jobu

= ‘V’: Compute left singular vectors. = ‘N’: Do not compute left singular vectors.

in
jobvt

= ‘V’: Compute right singular vectors (V**T). = ‘N’: Do not compute right singular vectors.

in
range

= ‘A’: all singular values will be found. = ‘V’: all singular values in (VL,VU] will be found. = ‘I’: the IL-th through IU-th singular values.

in
m

Number of rows of A. m >= 0.

in
n

Number of columns of A. n >= 0.

inout
A

Array (lda, n). On entry, the M-by-N matrix A. On exit, contents are destroyed.

in
lda

Leading dimension of A. lda >= max(1,m).

in
vl

If range=’V’, lower bound of interval (exclusive).

in
vu

If range=’V’, upper bound of interval. vu > vl.

in
il

If range=’I’, index of smallest singular value (0-based).

in
iu

If range=’I’, index of largest singular value (0-based).

out
ns

Number of singular values found.

out
S

Array (min(m,n)). Singular values in descending order.

out
U

Array (ldu, *). Left singular vectors if jobu=’V’.

in
ldu

Leading dimension of U. ldu >= 1; ldu >= m if jobu=’V’.

out
VT

Array (ldvt, n). Right singular vectors if jobvt=’V’.

in
ldvt

Leading dimension of VT. ldvt >= 1; ldvt >= ns if jobvt=’V’.

out
work

Workspace array of dimension lwork.

in
lwork

Dimension of work. If lwork = -1, workspace query.

out
iwork

Integer workspace of dimension 12*min(m,n).

out
info

  • = 0: success.

  • < 0: illegal argument.

  • > 0: i eigenvectors failed to converge in SBDSVDX.

Functions

void dgesvdx(
    const char*          jobu,
    const char*          jobvt,
    const char*          range,
    const INT            m,
    const INT            n,
          f64*  restrict A,
    const INT            lda,
    const f64            vl,
    const f64            vu,
    const INT            il,
    const INT            iu,
          INT*           ns,
          f64*  restrict S,
          f64*  restrict U,
    const INT            ldu,
          f64*  restrict VT,
    const INT            ldvt,
          f64*  restrict work,
    const INT            lwork,
          INT*  restrict iwork,
          INT*           info
);
void dgesvdx(const char *jobu, const char *jobvt, const char *range, const INT m, const INT n, f64 *restrict A, const INT lda, const f64 vl, const f64 vu, const INT il, const INT iu, INT *ns, f64 *restrict S, f64 *restrict U, const INT ldu, f64 *restrict VT, const INT ldvt, f64 *restrict work, const INT lwork, INT *restrict iwork, INT *info)#

DGESVDX computes the singular value decomposition (SVD) of a real M-by-N matrix A, optionally computing the left and/or right singular vectors.

The SVD is written

 A = U * SIGMA * transpose(V)
where SIGMA is an M-by-N matrix which is zero except for its min(m,n) diagonal elements, U is an M-by-M orthogonal matrix, and V is an N-by-N orthogonal matrix. The diagonal elements of SIGMA are the singular values of A; they are real and non-negative, and are returned in descending order. The first min(m,n) columns of U and V are the left and right singular vectors of A.

DGESVDX uses an eigenvalue problem for obtaining the SVD, which allows for the computation of a subset of singular values and vectors. See DBDSVDX for details.

Note that the routine returns V**T, not V.

Parameters

in
jobu

= ‘V’: Compute left singular vectors. = ‘N’: Do not compute left singular vectors.

in
jobvt

= ‘V’: Compute right singular vectors (V**T). = ‘N’: Do not compute right singular vectors.

in
range

= ‘A’: all singular values will be found. = ‘V’: all singular values in (VL,VU] will be found. = ‘I’: the IL-th through IU-th singular values.

in
m

Number of rows of A. m >= 0.

in
n

Number of columns of A. n >= 0.

inout
A

Array (lda, n). On entry, the M-by-N matrix A. On exit, contents are destroyed.

in
lda

Leading dimension of A. lda >= max(1,m).

in
vl

If range=’V’, lower bound of interval (exclusive).

in
vu

If range=’V’, upper bound of interval. vu > vl.

in
il

If range=’I’, index of smallest singular value (0-based).

in
iu

If range=’I’, index of largest singular value (0-based).

out
ns

Number of singular values found.

out
S

Array (min(m,n)). Singular values in descending order.

out
U

Array (ldu, *). Left singular vectors if jobu=’V’.

in
ldu

Leading dimension of U. ldu >= 1; ldu >= m if jobu=’V’.

out
VT

Array (ldvt, n). Right singular vectors if jobvt=’V’.

in
ldvt

Leading dimension of VT. ldvt >= 1; ldvt >= ns if jobvt=’V’.

out
work

Workspace array of dimension lwork.

in
lwork

Dimension of work. If lwork = -1, workspace query.

out
iwork

Integer workspace of dimension 12*min(m,n).

out
info

  • = 0: success.

  • < 0: illegal argument.

  • > 0: i eigenvectors failed to converge in DBDSVDX.

Functions

void cgesvdx(
    const char*          jobu,
    const char*          jobvt,
    const char*          range,
    const INT            m,
    const INT            n,
          c64*  restrict A,
    const INT            lda,
    const f32            vl,
    const f32            vu,
    const INT            il,
    const INT            iu,
          INT*           ns,
          f32*  restrict S,
          c64*  restrict U,
    const INT            ldu,
          c64*  restrict VT,
    const INT            ldvt,
          c64*  restrict work,
    const INT            lwork,
          f32*  restrict rwork,
          INT*  restrict iwork,
          INT*           info
);
void cgesvdx(const char *jobu, const char *jobvt, const char *range, const INT m, const INT n, c64 *restrict A, const INT lda, const f32 vl, const f32 vu, const INT il, const INT iu, INT *ns, f32 *restrict S, c64 *restrict U, const INT ldu, c64 *restrict VT, const INT ldvt, c64 *restrict work, const INT lwork, f32 *restrict rwork, INT *restrict iwork, INT *info)#

CGESVDX computes the singular value decomposition (SVD) of a complex M-by-N matrix A, optionally computing the left and/or right singular vectors.

The SVD is written

 A = U * SIGMA * transpose(V)
where SIGMA is an M-by-N matrix which is zero except for its min(m,n) diagonal elements, U is an M-by-M unitary matrix, and V is an N-by-N unitary matrix. The diagonal elements of SIGMA are the singular values of A; they are real and non-negative, and are returned in descending order. The first min(m,n) columns of U and V are the left and right singular vectors of A.

CGESVDX uses an eigenvalue problem for obtaining the SVD, which allows for the computation of a subset of singular values and vectors. See SBDSVDX for details.

Note that the routine returns V**T, not V.

Parameters

in
jobu

= ‘V’: Compute left singular vectors. = ‘N’: Do not compute left singular vectors.

in
jobvt

= ‘V’: Compute right singular vectors (V**H). = ‘N’: Do not compute right singular vectors.

in
range

= ‘A’: all singular values will be found. = ‘V’: all singular values in (VL,VU] will be found. = ‘I’: the IL-th through IU-th singular values.

in
m

Number of rows of A. m >= 0.

in
n

Number of columns of A. n >= 0.

inout
A

Complex*16 array (lda, n). On entry, the M-by-N matrix A. On exit, contents are destroyed.

in
lda

Leading dimension of A. lda >= max(1,m).

in
vl

If range=’V’, lower bound of interval (exclusive).

in
vu

If range=’V’, upper bound of interval. vu > vl.

in
il

If range=’I’, index of smallest singular value (0-based).

in
iu

If range=’I’, index of largest singular value (0-based).

out
ns

Number of singular values found.

out
S

Single precision array (min(m,n)). Singular values in descending order.

out
U

Complex*16 array (ldu, *). Left singular vectors if jobu=’V’.

in
ldu

Leading dimension of U. ldu >= 1; ldu >= m if jobu=’V’.

out
VT

Complex*16 array (ldvt, n). Right singular vectors if jobvt=’V’.

in
ldvt

Leading dimension of VT. ldvt >= 1; ldvt >= ns if jobvt=’V’.

out
work

Complex*16 workspace array of dimension lwork.

in
lwork

Dimension of work. If lwork = -1, workspace query.

out
rwork

Single precision workspace array.

out
iwork

Integer workspace of dimension 12*min(m,n).

out
info

  • = 0: success.

  • < 0: illegal argument.

  • > 0: i eigenvectors failed to converge in SBDSVDX.

Functions

void zgesvdx(
    const char*          jobu,
    const char*          jobvt,
    const char*          range,
    const INT            m,
    const INT            n,
          c128* restrict A,
    const INT            lda,
    const f64            vl,
    const f64            vu,
    const INT            il,
    const INT            iu,
          INT*           ns,
          f64*  restrict S,
          c128* restrict U,
    const INT            ldu,
          c128* restrict VT,
    const INT            ldvt,
          c128* restrict work,
    const INT            lwork,
          f64*  restrict rwork,
          INT*  restrict iwork,
          INT*           info
);
void zgesvdx(const char *jobu, const char *jobvt, const char *range, const INT m, const INT n, c128 *restrict A, const INT lda, const f64 vl, const f64 vu, const INT il, const INT iu, INT *ns, f64 *restrict S, c128 *restrict U, const INT ldu, c128 *restrict VT, const INT ldvt, c128 *restrict work, const INT lwork, f64 *restrict rwork, INT *restrict iwork, INT *info)#

ZGESVDX computes the singular value decomposition (SVD) of a complex M-by-N matrix A, optionally computing the left and/or right singular vectors.

The SVD is written

 A = U * SIGMA * transpose(V)
where SIGMA is an M-by-N matrix which is zero except for its min(m,n) diagonal elements, U is an M-by-M unitary matrix, and V is an N-by-N unitary matrix. The diagonal elements of SIGMA are the singular values of A; they are real and non-negative, and are returned in descending order. The first min(m,n) columns of U and V are the left and right singular vectors of A.

ZGESVDX uses an eigenvalue problem for obtaining the SVD, which allows for the computation of a subset of singular values and vectors. See DBDSVDX for details.

Note that the routine returns V**T, not V.

Parameters

in
jobu

= ‘V’: Compute left singular vectors. = ‘N’: Do not compute left singular vectors.

in
jobvt

= ‘V’: Compute right singular vectors (V**H). = ‘N’: Do not compute right singular vectors.

in
range

= ‘A’: all singular values will be found. = ‘V’: all singular values in (VL,VU] will be found. = ‘I’: the IL-th through IU-th singular values.

in
m

Number of rows of A. m >= 0.

in
n

Number of columns of A. n >= 0.

inout
A

Complex*16 array (lda, n). On entry, the M-by-N matrix A. On exit, contents are destroyed.

in
lda

Leading dimension of A. lda >= max(1,m).

in
vl

If range=’V’, lower bound of interval (exclusive).

in
vu

If range=’V’, upper bound of interval. vu > vl.

in
il

If range=’I’, index of smallest singular value (0-based).

in
iu

If range=’I’, index of largest singular value (0-based).

out
ns

Number of singular values found.

out
S

Double precision array (min(m,n)). Singular values in descending order.

out
U

Complex*16 array (ldu, *). Left singular vectors if jobu=’V’.

in
ldu

Leading dimension of U. ldu >= 1; ldu >= m if jobu=’V’.

out
VT

Complex*16 array (ldvt, n). Right singular vectors if jobvt=’V’.

in
ldvt

Leading dimension of VT. ldvt >= 1; ldvt >= ns if jobvt=’V’.

out
work

Complex*16 workspace array of dimension lwork.

in
lwork

Dimension of work. If lwork = -1, workspace query.

out
rwork

Double precision workspace array.

out
iwork

Integer workspace of dimension 12*min(m,n).

out
info

  • = 0: success.

  • < 0: illegal argument.

  • > 0: i eigenvectors failed to converge in DBDSVDX.