naginterfaces.library.lapackeig.dggsvd

naginterfaces.library.lapackeig.dggsvd(jobu, jobv, jobq, a, b)[source]

dggsvd computes the generalized singular value decomposition (GSVD) of an real matrix and a real matrix . dggsvd is marked as deprecated by LAPACK; the replacement routine is dggsvd3() which makes better use of Level 3 BLAS.

Deprecated since version 27.0.0.0: dggsvd is deprecated. Please use dggsvd3() instead. See also the Replacement Calls document.

For full information please refer to the NAG Library document for f08va

https://support.nag.com/numeric/nl/nagdoc_30.3/flhtml/f08/f08vaf.html

Parameters
jobustr, length 1

If , the orthogonal matrix is computed.

If , is not computed.

jobvstr, length 1

If , the orthogonal matrix is computed.

If , is not computed.

jobqstr, length 1

If , the orthogonal matrix is computed.

If , is not computed.

afloat, array-like, shape

The matrix .

bfloat, array-like, shape

The matrix .

Returns
kint

and specify the dimension of the subblocks and as described in Notes; is the effective numerical rank of (A;B).

lint

and specify the dimension of the subblocks and as described in Notes; is the effective numerical rank of (A;B).

afloat, ndarray, shape

Contains the triangular matrix , or part of . See Notes for details.

bfloat, ndarray, shape

Contains the triangular matrix if . See Notes for details.

alphafloat, ndarray, shape

See the description of .

betafloat, ndarray, shape

and contain the generalized singular value pairs of and , and ;

,

,

and if ,

,

,

or if ,

,

,

,

, and

,

.

The notation above refers to consecutive elements , for .

ufloat, ndarray, shape

If , contains the orthogonal matrix .

If , is not referenced.

vfloat, ndarray, shape

If , contains the orthogonal matrix .

If , is not referenced.

qfloat, ndarray, shape

If , contains the orthogonal matrix .

If , is not referenced.

iworkint, ndarray, shape

Stores the sorting information. More precisely, the following loop will sort

for i in range(k+1, min(m,k+l)+1):
  swap alpha[i-1] and alpha[iwork[i-1]-1]

such that .

Raises
NagValueError
(errno )

On entry, error in parameter .

Constraint: or .

(errno )

On entry, error in parameter .

Constraint: or .

(errno )

On entry, error in parameter .

Constraint: or .

(errno )

On entry, error in parameter .

Constraint: .

(errno )

On entry, error in parameter .

Constraint: .

(errno )

On entry, error in parameter .

Constraint: .

(errno )

The Jacobi-type procedure failed to converge.

Notes

The generalized singular value decomposition is given by

where , and are orthogonal matrices. Let be the effective numerical rank of the matrix (A;B), then is a nonsingular upper triangular matrix, and are and ‘diagonal’ matrices structured as follows:

if ,

where

and

is stored as a submatrix of with elements stored as on exit.

If ,

where

and

is stored as a submatrix of with stored as , and is stored as a submatrix of with stored as .

The function computes , , and, optionally, the orthogonal transformation matrices , and .

In particular, if is an nonsingular matrix, then the GSVD of and implicitly gives the SVD of :

If (A;B) has orthonormal columns, then the GSVD of and is also equal to the CS decomposition of and . Furthermore, the GSVD can be used to derive the solution of the eigenvalue problem:

In some literature, the GSVD of and is presented in the form

where and are orthogonal and is nonsingular, and and are ‘diagonal’. The former GSVD form can be converted to the latter form by taking the nonsingular matrix as

References

Anderson, E, Bai, Z, Bischof, C, Blackford, S, Demmel, J, Dongarra, J J, Du Croz, J J, Greenbaum, A, Hammarling, S, McKenney, A and Sorensen, D, 1999, LAPACK Users’ Guide, (3rd Edition), SIAM, Philadelphia, https://www.netlib.org/lapack/lug

Golub, G H and Van Loan, C F, 1996, Matrix Computations, (3rd Edition), Johns Hopkins University Press, Baltimore