dverk78 - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


dsolve/numeric/dverk78

numerical solution of ordinary differential equations

 

Calling Sequence

Parameters

Description

Examples

References

Credits

Calling Sequence

dsolve(odesys, numeric, method=dverk78, vars, options)

dsolve(numeric, method=dverk78, procopts, options)

Parameters

odesys

-

set or list; ordinary differential equation(s) and initial conditions

numeric

-

literal name; instruct dsolve to find a numerical solution

method=dverk78

-

literal equation; numerical method to use

vars

-

(optional) dependent variable or a set or list of dependent variables for odesys

options

-

(optional) equations of the form keyword = value

procopts

-

options used to specify the ODE system using a procedure (procedure, initial, start, number, and procvars). For more information, see dsolve[numeric,IVP].

Description

• 

The dsolve command with options numeric and method=dverk78 finds a numerical solution using a seventh-eighth order continuous Runge-Kutta method.

• 

The following options are available for the basic use form of the dverk78 method:

'output'      =

keyword or array

'known'       =

name or list of names

'number'      =

integer

'procedure'   =

procedure

'start'       =

numeric

'initial'     =

array

'procvars'    =

list

'startinit'   =

boolean

'implicit'    =

boolean

'optimize'    =

boolean

'abserr'      =

numeric

'relerr'      =

numeric

'errorest'    =

symbol

'initstep'    =

numeric

'minstep'     =

numeric

'maxstep'     =

numeric

'maxfun'      =

integer

  

 

  

'output'

  

Specifies the desired output from dsolve, and the known option specifies user-defined known functions. For more information, see dsolve[numeric].

  

 

  

'number', 'procedure', 'start', 'initial', and 'procvars'

  

These options are used to specify the IVP using procedures. For more information, see dsolve[numeric,IVP].

  

 

  

'startinit','implicit', and 'optimize'

  

These options control the method and behavior of the computation. For more information on the first two, see dsolve[numeric,IVP], for the last, see dsolve[numeric].

  

 

  

'abserr', 'relerr', 'initstep', 'minstep', and 'maxstep'

  

Specify the desired accuracy of the solution, and allow for more detailed control of the step size. For more information, see dsolve[Error_Control]. The default values are abserr=1.×10−8, relerr=1.×10−8, minstep=0, maxstep=2.0, and initstep=maxsteprelerr16.

  

The dverk78 method is capable of working in arbitrary precision based on the setting of Digits, and can be used to obtain high accuracy solutions for ODE systems. As a note of caution, however, it is often necessary to work with a greater number of Digits than would be expected for the requested error tolerance, to prevent round-off error from giving an inaccurate error estimate. When the error tolerance is too strict for the current setting of Digits, it is detected by the algorithm, and an error is issued. Asymptotically dverk78 requires Digits set so that tol=OFloat1,Digits98.

  

Note: As for all other numeric dsolve methods, any setting of Digits that is less than or equal to hardware precision works in hardware precision, so for Digits<evalhfDigits, the algorithm works in truncevalhfDigits Digits (see evalhf).

  

 

  

'errorest'

  

Allows control over the method used to obtain error estimates, and can have the values interpolant or pair. The interpolant option is the default, and tells dverk78 to estimate the error using the interpolant of the method. The pair option tells dverk to estimate the error using the difference between the computed solution and a lower order estimate of the solution (hence 'pair'). Typically, the interpolant option gives a better error estimate than the pair option, but requires more work to compute. This may also be a better option for expensive systems, as dverk78 with the interpolant option performs 20 function evaluations per step, while the pair option only requires 13.

  

 

  

'maxfun'

  

An integer that specifies the maximum on the number of evaluations of the ODE or ODE system in one call to the returned procedure. This limits the amount of work done on any individual call (See dsolve[maxfun]). This option is relevant for the procedure-style output only. By default, this value is set to zero (disabled).

  

 

• 

Results can be plotted using the function odeplot in the plots package.

Examples

Default output at several points

dsol1dsolvey0=1&comma;Dyx=yx&comma;numeric&comma;method=dverk78&comma;abserr=1.×10−8&comma;relerr=1.×10−8

dsol1procx_dverk78...end proc

(1)

dsol10

x=0.&comma;yx=1.

(2)

dsol10.4

x=0.400000000000000&comma;yx=1.49182469764117

(3)

dsol11.2

x=1.20000000000000&comma;yx=3.32011692267802

(4)

dsol11.5

x=1.50000000000000&comma;yx=4.48168906989179

(5)

array output

dsys2diffxt&comma;t=yt&comma;diffyt&comma;t=xt

dsys2&DifferentialD;&DifferentialD;txt=yt&comma;&DifferentialD;&DifferentialD;tyt=xt

(6)

init2x0=1&comma;y0=0

init2x0=1&comma;y0=0

(7)

dsol2dsolvedsys2unioninit2&comma;numeric&comma;method=dverk78&comma;output=Array0&comma;0.7&comma;1.1&comma;1.5&comma;2.2&comma;2.5

dsol2txtyt0.1.0.0.70.7648421872847910.6442176872371351.10.4535961215337580.8912073599322991.50.07073720179088110.9974949865466862.2−0.5885011161042540.8084964039944372.5−0.8011436142677190.598472144707831

(8)

dsol21,11=dsol22,16,1&comma;dsol21,12=dsol22,16,2

t=2.5&comma;xt=−0.801143614267719

(9)

listprocedure output

dsys3diffxt&comma;`$`t&comma;3=xt+yt&comma;diffyt&comma;t=xt+yt

dsys3&DifferentialD;3&DifferentialD;t3xt=xt+yt&comma;&DifferentialD;&DifferentialD;tyt=xt+yt

(10)

init3x0=1&comma;y0=1.3&comma;Dx0=1&comma;D2x0=0.5

init3x0=1&comma;y0=1.3&comma;Dx0=−1&comma;D2x0=0.5

(11)

dsol3dsolvedsys3unioninit3&comma;numeric&comma;method=dverk78&comma;output=listprocedure&comma;maxstep=0.01&colon;

dsol3xsubsdsol3&comma;xt&colon;dsol3ysubsdsol3&comma;yt&colon;

dsol3x0&comma;dsol3y0

1.&comma;1.3

(12)

dsol3x1&comma;dsol3y1

0.623059643663728&comma;2.30932410466714

(13)

dsol3x1.5&comma;dsol3y1.5

1.36464098811480&comma;3.23223976483577

(14)

Comparison of use of 'interpolant' and 'pair'

dsol4adsolvediffyx&comma;x&comma;x=yx&comma;y0=0&comma;Dy0=1&comma;numeric&comma;method=dverk78&comma;tolerance=1.×10−9&comma;errorest=interpolant

dsol4aprocx_dverk78...end proc

(15)

tttime&colon;

dsol4a1000

x=1000.&comma;yx=0.826879438181235&comma;&DifferentialD;&DifferentialD;xyx=0.562379146833518

(16)

timett

0.220

(17)

dsol4bdsolvediffyx&comma;x&comma;x=yx&comma;y0=0&comma;Dy0=1&comma;numeric&comma;method=dverk78&comma;tolerance=1.×10−9&comma;errorest=pair

dsol4bprocx_dverk78...end proc

(18)

tttime&colon;

dsol4b1000

x=1000.&comma;yx=0.826879446231662&comma;&DifferentialD;&DifferentialD;xyx=0.562379141799196

(19)

timett

0.118

(20)

References

  

Enright, W.H. "The Relative Efficiency of Alternative Defect Control Schemes for High Order Continuous Runge-Kutta Formulas." Technical Report 252/91, Dept. of Computer Science, University of Toronto, June, 1991.

  

Verner, J.H. "Explicit Runge-Kutta Methods with Estimates of the Local Truncation Error." SIAM Journal of Numerical Analysis, Aug. 1978.

Credits

  

Much appreciation and thanks go to Dr. Jim Verner who provided us with the coefficients for the dverk78 method, and the related interpolant. Without these coefficients the method would be restricted to hardware precision.

See Also

dsolve/Error_Control

dsolve[ck45]

dsolve[classical]

dsolve[gear]

dsolve[lsode]

dsolve[maxfun]

dsolve[numeric,IVP]

dsolve[numeric]

dsolve[piecewise]

dsolve[rkf45]

dsolve[rosenbrock]

dsolve[Stiffness]

dsolve[taylorseries]

plots[odeplot]