dpjibt Subroutine

public subroutine dpjibt(Neq, Y, Yh, Nyh, Ewt, Rtem, Savr, S, Wm, Iwm, res, jac, adda)

DPJIBT is called by DSTODI to compute and process the matrix P = A - HEL(1)J, where J is an approximation to the Jacobian dr/dy, and r = g(t,y) - A(t,y)*s.

Here J is computed by the user-supplied routine JAC if MITER = 1, or by finite differencing if MITER = 2.

J is stored in WM, rescaled, and ADDA is called to generate P.

P is then subjected to LU decomposition by DDECBT in preparation for later solution of linear systems with P as coefficient matrix.

In addition to variables described previously, communication with DPJIBT uses the following:

Y

array containing predicted values on entry.

RTEM

work array of length N (ACOR in DSTODI).

SAVR

array used for output only. On output it contains the residual evaluated at current values of t and y.

S

array containing predicted values of dy/dt (SAVF in DSTODI).

WM

real work space for matrices. On output it contains the LU decomposition of P. Storage of matrix elements starts at WM(3). WM also contains the following matrix-related data: WM(1) = SQRT(UROUND), used in numerical Jacobian increments.

IWM

integer work space containing pivot information, starting at IWM(21). IWM also contains block structure parameters MB = IWM(1) and NB = IWM(2). EL0

EL(1) (input).

IERPJ

output error flag. = 0 if no trouble occurred, = 1 if the P matrix was found to be unfactorable, = IRES (= 2 or 3) if RES returned IRES = 2 or 3.

JCUR

output flag = 1 to indicate that the Jacobian matrix (or approximation) is now current.

This routine also uses the Common variables EL0, H, TN, UROUND, MITER, N, NFE, and NJE.

Arguments

Type IntentOptional Attributes Name
integer, dimension(*) :: Neq
real(kind=dp), intent(inout), dimension(*) :: Y
real(kind=dp), intent(in), dimension(Nyh,*) :: Yh
integer, intent(in) :: Nyh
real(kind=dp), intent(in), dimension(*) :: Ewt
real(kind=dp), intent(inout), dimension(*) :: Rtem
real(kind=dp), dimension(*) :: Savr
real(kind=dp), dimension(*) :: S
real(kind=dp), intent(inout), dimension(*) :: Wm
integer, dimension(*) :: Iwm
real :: res
integer :: jac
real :: adda

Calls

proc~~dpjibt~2~~CallsGraph proc~dpjibt~2 M_odepack::dpjibt proc~dgefa~2 M_odepack::dgefa proc~dpjibt~2->proc~dgefa~2 proc~dgesl M_odepack::dgesl proc~dpjibt~2->proc~dgesl proc~daxpy~2 M_odepack::daxpy proc~dgefa~2->proc~daxpy~2 proc~dscal M_odepack::dscal proc~dgefa~2->proc~dscal proc~dgesl->proc~daxpy~2