GNU Octave  4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
dfnrmd.f
Go to the documentation of this file.
1 C Work performed under the auspices of the U.S. Department of Energy
2 C by Lawrence Livermore National Laboratory under contract number
3 C W-7405-Eng-48.
4 C
5  SUBROUTINE dfnrmd (NEQ, Y, T, YPRIME, R, CJ, WT, RES, IRES,
6  * fnorm, wm, iwm, rpar, ipar)
7 C
8 C***BEGIN PROLOGUE DFNRMD
9 C***REFER TO DLINSD
10 C***DATE WRITTEN 941025 (YYMMDD)
11 C
12 C
13 C-----------------------------------------------------------------------
14 C***DESCRIPTION
15 C
16 C DFNRMD calculates the scaled preconditioned norm of the nonlinear
17 C function used in the nonlinear iteration for obtaining consistent
18 C initial conditions. Specifically, DFNRMD calculates the weighted
19 C root-mean-square norm of the vector (J-inverse)*G(T,Y,YPRIME),
20 C where J is the Jacobian matrix.
21 C
22 C In addition to the parameters described in the calling program
23 C DLINSD, the parameters represent
24 C
25 C R -- Array of length NEQ that contains
26 C (J-inverse)*G(T,Y,YPRIME) on return.
27 C FNORM -- Scalar containing the weighted norm of R on return.
28 C-----------------------------------------------------------------------
29 C
30 C***ROUTINES CALLED
31 C RES, DSLVD, DDWNRM
32 C
33 C***END PROLOGUE DFNRMD
34 C
35 C
36  IMPLICIT DOUBLE PRECISION (a-h,o-z)
37  EXTERNAL res
38  dimension y(*), yprime(*), wt(*), r(*)
39  dimension wm(*),iwm(*), rpar(*),ipar(*)
40 C-----------------------------------------------------------------------
41 C Call RES routine.
42 C-----------------------------------------------------------------------
43  ires = 0
44  CALL res(t,y,yprime,cj,r,ires,rpar,ipar)
45  IF (ires .LT. 0) RETURN
46 C-----------------------------------------------------------------------
47 C Apply inverse of Jacobian to vector R.
48 C-----------------------------------------------------------------------
49  CALL dslvd(neq,r,wm,iwm)
50 C-----------------------------------------------------------------------
51 C Calculate norm of R.
52 C-----------------------------------------------------------------------
53  fnorm = ddwnrm(neq,r,wt,rpar,ipar)
54 C
55  RETURN
56 C----------------------- END OF SUBROUTINE DFNRMD ----------------------
57  END
std::string dimension(void) const
subroutine dslvd(NEQ, DELTA, WM, IWM)
Definition: dslvd.f:5
subroutine dfnrmd(NEQ, Y, T, YPRIME, R, CJ, WT, RES, IRES, FNORM, WM, IWM, RPAR, IPAR)
Definition: dfnrmd.f:5
double precision function ddwnrm(NEQ, V, RWT, RPAR, IPAR)
Definition: ddwnrm.f:5