lasd2#

Functions

void slasd2(
    const INT           nl,
    const INT           nr,
    const INT           sqre,
          INT*          k,
          f32* restrict D,
          f32* restrict Z,
    const f32           alpha,
    const f32           beta,
          f32* restrict U,
    const INT           ldu,
          f32* restrict VT,
    const INT           ldvt,
          f32* restrict DSIGMA,
          f32* restrict U2,
    const INT           ldu2,
          f32* restrict VT2,
    const INT           ldvt2,
          INT* restrict IDXP,
          INT* restrict IDX,
          INT* restrict IDXC,
          INT* restrict IDXQ,
          INT* restrict COLTYP,
          INT*          info
);
void slasd2(const INT nl, const INT nr, const INT sqre, INT *k, f32 *restrict D, f32 *restrict Z, const f32 alpha, const f32 beta, f32 *restrict U, const INT ldu, f32 *restrict VT, const INT ldvt, f32 *restrict DSIGMA, f32 *restrict U2, const INT ldu2, f32 *restrict VT2, const INT ldvt2, INT *restrict IDXP, INT *restrict IDX, INT *restrict IDXC, INT *restrict IDXQ, INT *restrict COLTYP, INT *info)#

SLASD2 merges the two sets of singular values together into a single sorted set.

Then it tries to deflate the size of the problem. There are two ways in which deflation can occur: when two or more singular values are close together or if there is a tiny entry in the Z vector. For each such occurrence the order of the related secular equation problem is reduced by one.

SLASD2 is called from SLASD1.

Parameters

in
nl

The row dimension of the upper block. nl >= 1.

in
nr

The row dimension of the lower block. nr >= 1.

in
sqre

= 0: lower block is nr-by-nr square matrix. = 1: lower block is nr-by-(nr+1) rectangular.

out
k

Dimension of the non-deflated matrix. 1 <= k <= n.

inout
D

Array of dimension n. On entry, singular values of two submatrices. On exit, trailing n-k deflated values.

out
Z

Array of dimension n. The updating row vector.

in
alpha

Diagonal element associated with added row.

in
beta

Off-diagonal element associated with added row.

inout
U

Array (ldu, n). Left singular vectors.

in
ldu

Leading dimension of U. ldu >= n.

inout
VT

Array (ldvt, m). Right singular vectors transposed.

in
ldvt

Leading dimension of VT. ldvt >= m.

out
DSIGMA

Array of dimension n. Copy of diagonal elements.

out
U2

Array (ldu2, n). Copy of left singular vectors.

in
ldu2

Leading dimension of U2. ldu2 >= n.

out
VT2

Array (ldvt2, n). Copy of right singular vectors.

in
ldvt2

Leading dimension of VT2. ldvt2 >= m.

out
IDXP

Integer array of dimension n. Permutation for deflation.

out
IDX

Integer array of dimension n. Sorting permutation.

out
IDXC

Integer array of dimension n. Column arrangement permutation.

inout
IDXQ

Integer array of dimension n. Sorting permutation for subproblems.

out
COLTYP

Integer array of dimension n. Column type labels.

out
info

  • = 0: successful exit. < 0: illegal argument.

Functions

void dlasd2(
    const INT           nl,
    const INT           nr,
    const INT           sqre,
          INT*          k,
          f64* restrict D,
          f64* restrict Z,
    const f64           alpha,
    const f64           beta,
          f64* restrict U,
    const INT           ldu,
          f64* restrict VT,
    const INT           ldvt,
          f64* restrict DSIGMA,
          f64* restrict U2,
    const INT           ldu2,
          f64* restrict VT2,
    const INT           ldvt2,
          INT* restrict IDXP,
          INT* restrict IDX,
          INT* restrict IDXC,
          INT* restrict IDXQ,
          INT* restrict COLTYP,
          INT*          info
);
void dlasd2(const INT nl, const INT nr, const INT sqre, INT *k, f64 *restrict D, f64 *restrict Z, const f64 alpha, const f64 beta, f64 *restrict U, const INT ldu, f64 *restrict VT, const INT ldvt, f64 *restrict DSIGMA, f64 *restrict U2, const INT ldu2, f64 *restrict VT2, const INT ldvt2, INT *restrict IDXP, INT *restrict IDX, INT *restrict IDXC, INT *restrict IDXQ, INT *restrict COLTYP, INT *info)#

DLASD2 merges the two sets of singular values together into a single sorted set.

Then it tries to deflate the size of the problem. There are two ways in which deflation can occur: when two or more singular values are close together or if there is a tiny entry in the Z vector. For each such occurrence the order of the related secular equation problem is reduced by one.

DLASD2 is called from DLASD1.

Parameters

in
nl

The row dimension of the upper block. nl >= 1.

in
nr

The row dimension of the lower block. nr >= 1.

in
sqre

= 0: lower block is nr-by-nr square matrix. = 1: lower block is nr-by-(nr+1) rectangular.

out
k

Dimension of the non-deflated matrix. 1 <= k <= n.

inout
D

Array of dimension n. On entry, singular values of two submatrices. On exit, trailing n-k deflated values.

out
Z

Array of dimension n. The updating row vector.

in
alpha

Diagonal element associated with added row.

in
beta

Off-diagonal element associated with added row.

inout
U

Array (ldu, n). Left singular vectors.

in
ldu

Leading dimension of U. ldu >= n.

inout
VT

Array (ldvt, m). Right singular vectors transposed.

in
ldvt

Leading dimension of VT. ldvt >= m.

out
DSIGMA

Array of dimension n. Copy of diagonal elements.

out
U2

Array (ldu2, n). Copy of left singular vectors.

in
ldu2

Leading dimension of U2. ldu2 >= n.

out
VT2

Array (ldvt2, n). Copy of right singular vectors.

in
ldvt2

Leading dimension of VT2. ldvt2 >= m.

out
IDXP

Integer array of dimension n. Permutation for deflation.

out
IDX

Integer array of dimension n. Sorting permutation.

out
IDXC

Integer array of dimension n. Column arrangement permutation.

inout
IDXQ

Integer array of dimension n. Sorting permutation for subproblems.

out
COLTYP

Integer array of dimension n. Column type labels.

out
info

  • = 0: successful exit. < 0: illegal argument.