2 SUBROUTINE DPKSET
(NEQ
, Y
, YSV
, EWT
, FTEM
, SAVF
, WM
, IWM
, F
, JAC
)
5 DOUBLE PRECISION Y
, YSV
, EWT
, FTEM
, SAVF
, WM
6 DIMENSION NEQ
(*), Y
(*), YSV
(*), EWT
(*), FTEM
(*), SAVF
(*),
9 1 ICF
, IERPJ
, IERSL
, JCUR
, JSTART
, KFLAG
, L
,
10 2 LYH
, LEWT
, LACOR
, LSAVF
, LWM
, LIWM
, METH
, MITER
,
11 3 MAXORD
, MAXCOR
, MSBP
, MXNCF
, N
, NQ
, NST
, NFE
, NJE
, NQU
12 INTEGER JPRE
, JACFLG
, LOCWP
, LOCIWP
, LSAVX
, KMP
, MAXL
, MNEWT
,
13 1 NNI
, NLI
, NPS
, NCFN
, NCFL
14 DOUBLE PRECISION ROWNS
,
15 1 CCMAX
, EL0
, H
, HMIN
, HMXI
, HU
, RC
, TN
, UROUND
16 DOUBLE PRECISION DELT
, EPCON
, SQRTN
, RSQRTN
17 COMMON /DLS001
/ ROWNS
(209),
18 1 CCMAX
, EL0
, H
, HMIN
, HMXI
, HU
, RC
, TN
, UROUND
,
20 3 ICF
, IERPJ
, IERSL
, JCUR
, JSTART
, KFLAG
, L
,
21 4 LYH
, LEWT
, LACOR
, LSAVF
, LWM
, LIWM
, METH
, MITER
,
22 5 MAXORD
, MAXCOR
, MSBP
, MXNCF
, N
, NQ
, NST
, NFE
, NJE
, NQU
23 COMMON /DLPK01
/ DELT
, EPCON
, SQRTN
, RSQRTN
,
24 1 JPRE
, JACFLG
, LOCWP
, LOCIWP
, LSAVX
, KMP
, MAXL
, MNEWT
,
25 2 NNI
, NLI
, NPS
, NCFN
, NCFL
26 C-----------------------------------------------------------------------
27 C DPKSET is called by DSTODPK to interface with the user-supplied
28 C routine JAC, to compute and process relevant parts of
29 C the matrix P = I - H*EL(1)*J , where J is the Jacobian df/dy,
30 C as need for preconditioning matrix operations later.
32 C In addition to variables described previously, communication
33 C with DPKSET uses the following:
34 C Y = array containing predicted values on entry.
35 C YSV = array containing predicted y, to be saved (YH1 in DSTODPK).
36 C FTEM = work array of length N (ACOR in DSTODPK).
37 C SAVF = array containing f evaluated at predicted y.
38 C WM = real work space for matrices.
39 C Space for preconditioning data starts at WM(LOCWP).
40 C IWM = integer work space.
41 C Space for preconditioning data starts at IWM(LOCIWP).
42 C IERPJ = output error flag, = 0 if no trouble, .gt. 0 if
43 C JAC returned an error flag.
44 C JCUR = output flag = 1 to indicate that the Jacobian matrix
45 C (or approximation) is now current.
46 C This routine also uses Common variables EL0, H, TN, IERPJ, JCUR, NJE.
47 C-----------------------------------------------------------------------
54 CALL JAC
(F
, NEQ
, TN
, Y
, YSV
, EWT
, SAVF
, FTEM
, HL0
,
55 1 WM
(LOCWP
), IWM
(LOCIWP
), IER
)
57 IF (IER
.EQ
. 0) RETURN
60 C----------------------- End of Subroutine DPKSET ----------------------