2
SUBROUTINE SPPFA (AP, N, INFO)
3
C***BEGIN PROLOGUE SPPFA
4
C***PURPOSE Factor a real symmetric positive definite matrix stored in
6
C***LIBRARY SLATEC (LINPACK)
8
C***TYPE SINGLE PRECISION (SPPFA-S, DPPFA-D, CPPFA-C)
9
C***KEYWORDS LINEAR ALGEBRA, LINPACK, MATRIX FACTORIZATION, PACKED,
11
C***AUTHOR Moler, C. B., (U. of New Mexico)
14
C SPPFA factors a real symmetric positive definite matrix
15
C stored in packed form.
17
C SPPFA is usually called by SPPCO, but it can be called
18
C directly with a saving in time if RCOND is not needed.
19
C (Time for SPPCO) = (1 + 18/N)*(Time for SPPFA) .
24
C the packed form of a symmetric matrix A . The
25
C columns of the upper triangle are stored sequentially
26
C in a one-dimensional array of length N*(N+1)/2 .
27
C See comments below for details.
30
C the order of the matrix A .
34
C AP an upper triangular matrix R , stored in packed
35
C form, so that A = TRANS(R)*R .
38
C = 0 for normal return.
39
C = K if the leading minor of order K is not
45
C The following program segment will pack the upper
46
C triangle of a symmetric matrix.
56
C***REFERENCES J. J. Dongarra, J. R. Bunch, C. B. Moler, and G. W.
57
C Stewart, LINPACK Users' Guide, SIAM, 1979.
58
C***ROUTINES CALLED SDOT
59
C***REVISION HISTORY (YYMMDD)
61
C 890831 Modified array declarations. (WRB)
62
C 890831 REVISION DATE from Version 3.2
63
C 891214 Prologue converted to Version 4.0 format. (BAB)
64
C 900326 Removed duplicate information from DESCRIPTION section.
66
C 920501 Reformatted the REFERENCES section. (WRB)
67
C***END PROLOGUE SPPFA
73
INTEGER J,JJ,JM1,K,KJ,KK
74
C***FIRST EXECUTABLE STATEMENT SPPFA
82
IF (JM1 .LT. 1) GO TO 20
85
T = AP(KJ) - SDOT(K-1,AP(KK+1),1,AP(JJ+1),1)
94
IF (S .LE. 0.0E0) GO TO 40