naginterfaces.library.blas.zusqr

naginterfaces.library.blas.zusqr(side, k1, k2, s, a)[source]

zusqr performs a or factorization (as a sequence of plane rotations) of a complex upper spiked matrix.

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

https://support.nag.com/numeric/nl/nagdoc_30/flhtml/f06/f06tsf.html

Parameters
sidestr, length 1

Specifies whether is operated on from the left or the right.

is pre-multiplied from the left.

is post-multiplied from the right.

k1int

The value .

k2int

The value .

scomplex, array-like, shape

The nonzero elements of the spike of : must hold if , and if , for .

acomplex, array-like, shape

The upper triangular part of the upper spiked matrix . The imaginary parts of the diagonal elements must be zero, except for the element if , or the element if .

Returns
cfloat, ndarray, shape

holds , the cosine of the rotation , for .

scomplex, ndarray, shape

holds , the sine of the rotation , for ; holds , the th diagonal element of , if , or , the th diagonal element of , if .

acomplex, ndarray, shape

The upper triangular matrix . The imaginary parts of the diagonal elements are set to zero.

Raises
NagValueError
(errno )

On entry, error in parameter .

Constraint: or .

(errno )

On entry, error in parameter .

Constraint: .

Notes

No equivalent traditional C interface for this routine exists in the NAG Library.

zusqr transforms an complex upper spiked matrix to upper triangular form by applying a complex unitary matrix from the left or the right. is assumed to have real diagonal elements except where the spike joins the diagonal; has real diagonal elements. is formed as a sequence of plane rotations in planes to .

If , is assumed to have a row spike, with nonzero elements , for . The rotations are applied from the left:

where , is a rotation in the plane and with .

If , is assumed to have a column spike, with nonzero elements , for . The rotations are applied from the right:

where , is a rotation in the plane and with .

The plane rotation part of has the form

with real.