Developer Reference for Intel® oneAPI Math Kernel Library for C
?gttrf
Computes the LU factorization of a tridiagonal matrix.
Syntax
lapack_intLAPACKE_sgttrf ( lapack_intn , float*dl , float*d , float*du , float*du2 , lapack_int*ipiv );
lapack_intLAPACKE_dgttrf ( lapack_intn , double*dl , double*d , double*du , double*du2 , lapack_int*ipiv );
lapack_intLAPACKE_cgttrf ( lapack_intn , lapack_complex_float*dl , lapack_complex_float*d , lapack_complex_float*du , lapack_complex_float*du2 , lapack_int*ipiv );
lapack_intLAPACKE_zgttrf ( lapack_intn , lapack_complex_double*dl , lapack_complex_double*d , lapack_complex_double*du , lapack_complex_double*du2 , lapack_int*ipiv );
Include Files
mkl.h
Description
sgttrf dgttrf cgttrf zgttrf gttrf
The routine computes the LU factorization of a real or complex tridiagonal matrix A using elimination with partial pivoting and row interchanges.
The factorization has the form
A = L*U ,
where L is a product of permutation and unit lower bidiagonal matrices and U is upper triangular with nonzeroes in only the main diagonal and first two superdiagonals.
Input Parameters
n
The order of the matrix A ; n ≥ 0.
dl , d , du
Arrays containing elements of A .
The array dl of dimension (n - 1) contains the subdiagonal elements of A .
The array d of dimension n contains the diagonal elements of A .
The array du of dimension (n - 1) contains the superdiagonal elements of A .
Output Parameters
dl
Overwritten by the (n-1) multipliers that define the matrix L from the LU factorization of A .
d
Overwritten by the n diagonal elements of the upper triangular matrix U from the LU factorization of A .
du
Overwritten by the (n-1) elements of the first superdiagonal of U .
du2
Array, dimension (n -2) . On exit, du2 contains (n-2) elements of the second superdiagonal of U .
ipiv
Array, dimension ( n ). The pivot indices: for 1 ≤ i ≤ n , row i was interchanged with row ipiv [ i -1]. ipiv [ i -1] is always i or i +1; ipiv [ i -1] = i indicates a row interchange was not required.
Return Values
This function returns a value info .
If info = 0 , the execution is successful.
If info = -i , parameter i had an illegal value.
If info = i , \(U_{ii}\) is 0. The factorization has been completed, but U is exactly singular. Division by zero will occur if you use the factor U for solving a system of linear equations.
LAPACK 95 Interface Notes
There exist FORTRAN 77 and FORTRAN 95 interfaces for this routine. See the Intel® oneMKL Fortran Developer Reference for details.
Application Notes
?gbtrs (Solves a system of linear equations with an LU-factored band coefficient matrix, with multiple right-hand sides.)
to solve \(A X = B\) or \(A^{T} X = B\) or \(A^{H} X = B\)
?gbcon (Estimates the reciprocal of the condition number of a band matrix in the 1-norm or the infinity-norm.)
to estimate the condition number of \(A\) .