example9: Example ODE System Number Nine

Description Usage Arguments Details Value Author(s) See Also Examples

Description

The derivative function of an example two dimensional autonomous ODE system.

Usage

1
example9(t, y, parameters)

Arguments

t

Value of t, the independent variable, to evaluate the derivative at. Should be a single number.

y

Values of x and y, the dependent variables, to evaluate the derivative at. Should be a vector of length 2.

parameters

Values of the parameters of the system. Not required here.

Details

Evaluates the derivative of the following coupled ODE system at the point (t, x, y):

dx/dt = -2*x + 3*y, dy/dt = 7*x + 6*y.

Format is designed to be compatible with ode from the deSolve package.

Value

Returns a list dy containing the values of the two derivatives at (t, x, y).

Author(s)

Michael J. Grayling

See Also

ode

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# Plot the velocity field, nullclines and several trajectories.
example9.flowField  <- flowField(example9, x.lim = c(-3, 3), y.lim = c(-3, 3),
                                 points = 19, add = FALSE)
y0                  <- matrix(c(1, 0, -3, 2, 2, -2, -2, -2), ncol = 2, nrow = 4,
                              byrow = TRUE)
example9.nullclines <- nullclines(example9, x.lim = c(-3, 3), y.lim = c(-3, 3))
example9.trajectory <- trajectory(example9, y0 = y0, t.end = 10)

# Determine the stability of the equilibrium point.
example9.stability <- stability(example9, y.star = c(0, 0))


Search within the phaseR package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.