naginterfaces.library.lapackeig.dggglm

naginterfaces.library.lapackeig.dggglm(p, a, b, d)[source]

dggglm solves a real general Gauss–Markov linear (least squares) model problem.

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

https://support.nag.com/numeric/nl/nagdoc_30.2/flhtml/f08/f08zbf.html

Parameters
pint

, the number of columns of the matrix .

afloat, array-like, shape

The matrix .

bfloat, array-like, shape

The matrix .

dfloat, array-like, shape

The left-hand side vector of the GLM equation.

Returns
afloat, ndarray, shape

is overwritten.

bfloat, ndarray, shape

is overwritten.

dfloat, ndarray, shape

is overwritten.

xfloat, ndarray, shape

The solution vector of the GLM problem.

yfloat, ndarray, shape

The solution vector of the GLM problem.

Raises
NagValueError
(errno )

On entry, error in parameter .

Constraint: .

(errno )

On entry, error in parameter .

Constraint: .

(errno )

On entry, error in parameter .

Constraint: .

(errno )

The upper triangular factor associated with in the generalized factorization of the pair is singular, so that ; the least squares solution could not be computed.

(errno )

The bottom part of the upper trapezoidal factor associated with in the generalized factorization of the pair is singular, so that ; the least squares solutions could not be computed.

Notes

dggglm solves the real general Gauss–Markov linear model (GLM) problem

where is an matrix, is an matrix and is an element vector. It is assumed that , and , where . Under these assumptions, the problem has a unique solution and a minimal -norm solution , which is obtained using a generalized factorization of the matrices and .

In particular, if the matrix is square and nonsingular, then the GLM problem is equivalent to the weighted linear least squares problem

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

Anderson, E, Bai, Z and Dongarra, J, 1992, Generalized factorization and its applications, Linear Algebra Appl. (Volume 162–164), 243–271