naginterfaces.library.lapacklin.zgttrf

naginterfaces.library.lapacklin.zgttrf(n, dl, d, du)[source]

zgttrf computes the factorization of a complex tridiagonal matrix .

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

https://support.nag.com/numeric/nl/nagdoc_30.1/flhtml/f07/f07crf.html

Parameters
nint

, the order of the matrix .

dlcomplex, array-like, shape

Must contain the subdiagonal elements of the matrix .

dcomplex, array-like, shape

Must contain the diagonal elements of the matrix .

ducomplex, array-like, shape

Must contain the superdiagonal elements of the matrix .

Returns
dlcomplex, ndarray, shape

Is overwritten by the multipliers that define the matrix of the factorization of .

dcomplex, ndarray, shape

Is overwritten by the diagonal elements of the upper triangular matrix from the factorization of .

ducomplex, ndarray, shape

Is overwritten by the elements of the first superdiagonal of .

du2complex, ndarray, shape

Contains the elements of the second superdiagonal of .

ipivint, ndarray, shape

Contains the pivot indices that define the permutation matrix . At the th step, row of the matrix was interchanged with row . will always be either or , indicating that a row interchange was not performed.

Raises
NagValueError
(errno )

On entry, error in parameter .

Constraint: .

Warns
NagAlgorithmicWarning
(errno )

Element of the diagonal is exactly zero. The factorization has been completed, but the factor is exactly singular, and division by zero will occur if it is used to solve a system of equations.

Notes

zgttrf uses Gaussian elimination with partial pivoting and row interchanges to factorize the matrix as

where is a permutation matrix, is unit lower triangular with at most one nonzero subdiagonal element in each column, and is an upper triangular band matrix, with two superdiagonals.

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