---
name: "hetri"
section: "3"
platform: "linux"
package: "lapack-doc"
version: "3.12.1-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/hetri"
---

# hetri(3)

{he,sy}tri: triangular inverse

## NAME

hetri - {he,sy}tri: triangular inverse

## SYNOPSIS

### Functions

subroutine **chetri** (uplo, n, a, lda, ipiv, work, info)\
 **CHETRI**  subroutine **csytri** (uplo, n, a, lda, ipiv, work, info)\
 **CSYTRI**  subroutine **dsytri** (uplo, n, a, lda, ipiv, work, info)\
 **DSYTRI**  subroutine **ssytri** (uplo, n, a, lda, ipiv, work, info)\
 **SSYTRI**  subroutine **zhetri** (uplo, n, a, lda, ipiv, work, info)\
 **ZHETRI**  subroutine **zsytri** (uplo, n, a, lda, ipiv, work, info)\
 **ZSYTRI**

## Detailed Description

## Function Documentation

### subroutine chetri (character uplo, integer n, complex, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, complex, dimension( \* ) work, integer info)

**CHETRI**

**Purpose:**

```
!>
!> CHETRI computes the inverse of a complex Hermitian indefinite matrix
!> A using the factorization A = U*D*U**H or A = L*D*L**H computed by
!> CHETRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**H;
!>          = 'L':  Lower triangular, form is A = L*D*L**H.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is COMPLEX array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by CHETRF.
!>
!>          On exit, if INFO = 0, the (Hermitian) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by CHETRF.
!>
```

*WORK*

```
!>          WORK is COMPLEX array, dimension (N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **chetri.f**.

### subroutine csytri (character uplo, integer n, complex, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, complex, dimension( \* ) work, integer info)

**CSYTRI**

**Purpose:**

```
!>
!> CSYTRI computes the inverse of a complex symmetric indefinite matrix
!> A using the factorization A = U*D*U**T or A = L*D*L**T computed by
!> CSYTRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**T;
!>          = 'L':  Lower triangular, form is A = L*D*L**T.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is COMPLEX array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by CSYTRF.
!>
!>          On exit, if INFO = 0, the (symmetric) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by CSYTRF.
!>
```

*WORK*

```
!>          WORK is COMPLEX array, dimension (2*N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **csytri.f**.

### subroutine dsytri (character uplo, integer n, double precision, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, double precision, dimension( \* ) work, integer info)

**DSYTRI**

**Purpose:**

```
!>
!> DSYTRI computes the inverse of a real symmetric indefinite matrix
!> A using the factorization A = U*D*U**T or A = L*D*L**T computed by
!> DSYTRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**T;
!>          = 'L':  Lower triangular, form is A = L*D*L**T.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is DOUBLE PRECISION array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by DSYTRF.
!>
!>          On exit, if INFO = 0, the (symmetric) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by DSYTRF.
!>
```

*WORK*

```
!>          WORK is DOUBLE PRECISION array, dimension (N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **dsytri.f**.

### subroutine ssytri (character uplo, integer n, real, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, real, dimension( \* ) work, integer info)

**SSYTRI**

**Purpose:**

```
!>
!> SSYTRI computes the inverse of a real symmetric indefinite matrix
!> A using the factorization A = U*D*U**T or A = L*D*L**T computed by
!> SSYTRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**T;
!>          = 'L':  Lower triangular, form is A = L*D*L**T.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is REAL array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by SSYTRF.
!>
!>          On exit, if INFO = 0, the (symmetric) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by SSYTRF.
!>
```

*WORK*

```
!>          WORK is REAL array, dimension (N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **ssytri.f**.

### subroutine zhetri (character uplo, integer n, complex\*16, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, complex\*16, dimension( \* ) work, integer info)

**ZHETRI**

**Purpose:**

```
!>
!> ZHETRI computes the inverse of a complex Hermitian indefinite matrix
!> A using the factorization A = U*D*U**H or A = L*D*L**H computed by
!> ZHETRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**H;
!>          = 'L':  Lower triangular, form is A = L*D*L**H.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is COMPLEX*16 array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by ZHETRF.
!>
!>          On exit, if INFO = 0, the (Hermitian) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by ZHETRF.
!>
```

*WORK*

```
!>          WORK is COMPLEX*16 array, dimension (N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **zhetri.f**.

### subroutine zsytri (character uplo, integer n, complex\*16, dimension( lda, \* ) a, integer lda, integer, dimension( \* ) ipiv, complex\*16, dimension( \* ) work, integer info)

**ZSYTRI**

**Purpose:**

```
!>
!> ZSYTRI computes the inverse of a complex symmetric indefinite matrix
!> A using the factorization A = U*D*U**T or A = L*D*L**T computed by
!> ZSYTRF.
!>
```

**Parameters**

*UPLO*

```
!>          UPLO is CHARACTER*1
!>          Specifies whether the details of the factorization are stored
!>          as an upper or lower triangular matrix.
!>          = 'U':  Upper triangular, form is A = U*D*U**T;
!>          = 'L':  Lower triangular, form is A = L*D*L**T.
!>
```

*N*

```
!>          N is INTEGER
!>          The order of the matrix A.  N >= 0.
!>
```

*A*

```
!>          A is COMPLEX*16 array, dimension (LDA,N)
!>          On entry, the block diagonal matrix D and the multipliers
!>          used to obtain the factor U or L as computed by ZSYTRF.
!>
!>          On exit, if INFO = 0, the (symmetric) inverse of the original
!>          matrix.  If UPLO = 'U', the upper triangular part of the
!>          inverse is formed and the part of A below the diagonal is not
!>          referenced; if UPLO = 'L' the lower triangular part of the
!>          inverse is formed and the part of A above the diagonal is
!>          not referenced.
!>
```

*LDA*

```
!>          LDA is INTEGER
!>          The leading dimension of the array A.  LDA >= max(1,N).
!>
```

*IPIV*

```
!>          IPIV is INTEGER array, dimension (N)
!>          Details of the interchanges and the block structure of D
!>          as determined by ZSYTRF.
!>
```

*WORK*

```
!>          WORK is COMPLEX*16 array, dimension (2*N)
!>
```

*INFO*

```
!>          INFO is INTEGER
!>          = 0: successful exit
!>          < 0: if INFO = -i, the i-th argument had an illegal value
!>          > 0: if INFO = i, D(i,i) = 0; the matrix is singular and its
!>               inverse could not be computed.
!>
```

**Author**

Univ. of Tennessee

Univ. of California Berkeley

Univ. of Colorado Denver

NAG Ltd.

Definition at line **113** of file **zsytri.f**.

## Author

Generated automatically by Doxygen for LAPACK from the source code.
