1SPSTF2(1) LAPACK PROTOTYPE routine (version 3.2) SPSTF2(1)
2
3
4
6 SPSTF2 - computes the Cholesky factorization with complete pivoting of
7 a real symmetric positive semidefinite matrix A
8
10 SUBROUTINE SPSTF2( UPLO, N, A, LDA, PIV, RANK, TOL, WORK, INFO )
11
12 REAL TOL
13
14 INTEGER INFO, LDA, N, RANK
15
16 CHARACTER UPLO
17
18 REAL A( LDA, * ), WORK( 2*N )
19
20 INTEGER PIV( N )
21
23 SPSTF2 computes the Cholesky factorization with complete pivoting of a
24 real symmetric positive semidefinite matrix A. The factorization has
25 the form
26 P' * A * P = U' * U , if UPLO = 'U',
27 P' * A * P = L * L', if UPLO = 'L',
28 where U is an upper triangular matrix and L is lower triangular, and P
29 is stored as vector PIV.
30 This algorithm does not attempt to check that A is positive semidefi‐
31 nite. This version of the algorithm calls level 2 BLAS.
32
34 UPLO (input) CHARACTER*1
35 Specifies whether the upper or lower triangular part of the
36 symmetric matrix A is stored. = 'U': Upper triangular
37 = 'L': Lower triangular
38
39 N (input) INTEGER
40 The order of the matrix A. N >= 0.
41
42 A (input/output) REAL array, dimension (LDA,N)
43 On entry, the symmetric matrix A. If UPLO = 'U', the leading n
44 by n upper triangular part of A contains the upper triangular
45 part of the matrix A, and the strictly lower triangular part of
46 A is not referenced. If UPLO = 'L', the leading n by n lower
47 triangular part of A contains the lower triangular part of the
48 matrix A, and the strictly upper triangular part of A is not
49 referenced. On exit, if INFO = 0, the factor U or L from the
50 Cholesky factorization as above.
51
52 PIV (output) INTEGER array, dimension (N)
53 PIV is such that the nonzero entries are P( PIV(K), K ) = 1.
54
55 RANK (output) INTEGER
56 The rank of A given by the number of steps the algorithm com‐
57 pleted.
58
59 TOL (input) REAL
60 User defined tolerance. If TOL < 0, then N*U*MAX( A( K,K ) )
61 will be used. The algorithm terminates at the (K-1)st step if
62 the pivot <= TOL.
63
64 LDA (input) INTEGER
65 The leading dimension of the array A. LDA >= max(1,N).
66
67 WORK REAL array, dimension (2*N)
68 Work space.
69
70 INFO (output) INTEGER
71 < 0: If INFO = -K, the K-th argument had an illegal value,
72 = 0: algorithm completed successfully, and
73 > 0: the matrix A is either rank deficient with computed rank
74 as returned in RANK, or is indefinite. See Section 7 of LAPACK
75 Working Note #161 for further information.
76
77
78
79 LAPACK PROTOTYPE routine (versionNo3v.e2m)ber 2008 SPSTF2(1)