# naginterfaces.library.lapacklin.dtrtri¶

naginterfaces.library.lapacklin.dtrtri(uplo, diag, a)[source]

dtrtri computes the inverse of a real triangular matrix.

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

https://www.nag.com/numeric/nl/nagdoc_27.3/flhtml/f07/f07tjf.html

Parameters
uplostr, length 1

Specifies whether is upper or lower triangular.

is upper triangular.

is lower triangular.

diagstr, length 1

Indicates whether is a nonunit or unit triangular matrix.

is a nonunit triangular matrix.

is a unit triangular matrix; the diagonal elements are not referenced and are assumed to be .

afloat, array-like, shape

The triangular matrix .

Returns
afloat, ndarray, shape

is overwritten by , using the same storage format as described above.

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: .

Warns
NagAlgorithmicWarning
(errno )

Element of the diagonal is exactly zero. is singular its inverse cannot be computed.

Notes

dtrtri forms the inverse of a real triangular matrix . Note that the inverse of an upper (lower) triangular matrix is also upper (lower) triangular.

References

Du Croz, J J and Higham, N J, 1992, Stability of methods for matrix inversion, IMA J. Numer. Anal. (12), 1–19