Learn R Programming

mosaicCalc (version 0.6.4)

makeODE: Create a dynamics object for use in integrateODE() and the ODE graphics

Description

An ODE object consists of some dynamics, initial conditions, parameter values, time domain, etc.

Usage

makeODE(...)

Value

a list containing various functions and values specifying the ODE.

Arguments

...

The components of an ODE and/or a set of other ODE objects.

By default, the time step is set to dt = 0.01. Change it with dt = value.

Examples

Run this code
SIR <- makeODE(dS~ -a*S*I, dI ~ a*S*I - b*I, a=0.0026, b=.5, S=762, I=1)
soln <- integrateODE(SIR, domain(t=0:20))

Run the code above in your browser using DataLab