?hetrf_rook
?hetrf_rook
Computes the bounded Bunch-Kaufman factorization of a complex Hermitian matrix.
Syntax
lapack_int
LAPACKE_chetrf_rook
(
int
matrix_layout
,
char
uplo
,
lapack_int
n
,
lapack_complex_float
*
a
,
lapack_int
lda
,
lapack_int
*
ipiv
);
lapack_int
LAPACKE_zhetrf_rook
(
int
matrix_layout
,
char
uplo
,
lapack_int
n
,
lapack_complex_double
*
a
,
lapack_int
lda
,
lapack_int
*
ipiv
);
Include Files
- mkl.h
Description
The routine computes the factorization of a complex Hermitian matrix
A
using the bounded Bunch-Kaufman diagonal pivoting method:- if,uplo='U'A=U*D*UH
- if,uplo='L'A=L*D*LH,
where
A
is the input matrix, U
(or L
) is a product of permutation and unit upper ( or lower) triangular matrices, and D
is a Hermitian block-diagonal matrix with 1-by-1 and 2-by-2 diagonal blocks. This is the blocked version of the algorithm, calling Level 3 BLAS.
Input Parameters
- matrix_layout
- Specifies whether matrix storage layout for arraybis row major (LAPACK_ROW_MAJOR) or column major (LAPACK_COL_MAJOR).
- uplo
- Must be'U'or'L'.Indicates whether the upper or lower triangular part ofAis stored:If, the arrayuplo='U'astores the upper triangular part of the matrixA.If, the arrayuplo='L'astores the lower triangular part of the matrixA.
- n
- The order of matrixA;n≥0.
- a
- Arraya, size(lda*n)The arrayacontains the upper or the lower triangular part of the matrixA(seeuplo).Ifuplo= 'U', the leadingn-by-nupper triangular part ofacontains the upper triangular part of the matrixA, and the strictly lower triangular part ofais not referenced. Ifuplo= 'L', the leadingn-by-nlower triangular part ofacontains the lower triangular part of the matrixA, and the strictly upper triangular part ofais not referenced.
- lda
- The leading dimension ofa; at leastmax(1,.n)
Output Parameters
- a
- The block diagonal matrixDand the multipliers used to obtain the factorUorL(see Application Notes for further details).
- ipiv
- Ifuplo='U':If, then rows and columnsipiv(k) > 0kandwere interchanged andipiv(k)Dis a 1-by-1 diagonal block.k,kIfipiv(k) < 0 andipiv(k- 1) < 0, then rows and columnskand -ipiv(k) were interchanged and rows and columnsk- 1 and -ipiv(k- 1) were interchanged,Dis a 2-by-2 diagonal block.k- 1:k,k- 1:k
- Ifuplo='L':Ifipiv(k) > 0, then rows and columnskandipiv(k) were interchanged andDis a 1-by-1 diagonal block.k,kIfipiv(k) < 0 andipiv(k+ 1) < 0, then rows and columnskand -ipiv(k) were interchanged and rows and columnsk+ 1 and -ipiv(k+ 1) were interchanged,Dis a 2-by-2 diagonal block.k:k+ 1,k:k+ 1
Return Values
This function returns a value
info
.If , the execution is successful.
info
= 0If , the
info
= -i
i
-th parameter had an illegal value. If , is exactly 0. The factorization has been completed, but the block diagonal matrix
info
= i
D
i
i
D
is exactly singular, and division by 0 will occur if you use D
for solving a system of linear equations.Application Notes
If , where
uplo
= 'U', thenA
= U*D*U
H
U
= P
(n
)*U
(n
)* ... *P
(k
)U
(k
)* ..., i.e.,
U
is a product of terms P
(k
)*U
(k
), where k
decreases from n
to 1 in steps of 1 or 2, and D
is a block diagonal matrix with 1-by-1 and 2-by-2 diagonal blocks D
(k
). P
(k
) is a permutation matrix as defined by ipiv
(k
), and U
(k
) is a unit upper triangular matrix, such that if the diagonal block D
(k
) is of order s
(s
= 1 or 2), then
If
s
= 1, D
(k
) overwrites A
(k
,k
), and v
overwrites A
(1:k
-1,k
). If
s
= 2, the upper triangle of D
(k
) overwrites A
(k
-1,k
-1), A
(k
-1,k
), and A
(k
,k
), and v
overwrites A
(1:k
-2,k
-1:k
). If , where
uplo
= 'L', then A
= L*D*L
H
L
= P
(1)*L
(1)* ... *P
(k
)*L
(k
)* ..., i.e.,
L
is a product of terms P
(k
)*L
(k
), where k
increases from 1 to n
in steps of 1 or 2, and D
is a block diagonal matrix with 1-by-1 and 2-by-2 diagonal blocks D
(k
). P
(k
) is a permutation matrix as defined by ipiv
(k
), and L
(k
) is a unit lower triangular matrix, such that if the diagonal block D
(k
) is of order s
(s
= 1 or 2), then
If
s
= 1, D
(k
) overwrites A
(k
,k
), and v
overwrites A
(k
+1:n
,k
). If
s
= 2, the lower triangle of D
(k
) overwrites A
(k
,k
), A
(k
+1,k
), and A
(k
+1,k
+1), and v
overwrites A
(k
+2:n
,k
:k
+1).