makeGrid.trans: Evaluates transition probability ODE over 2D grid of...

Description Usage Arguments Value Examples

View source: R/bsd_package.R

Description

Applies the function solve.trans to a grid of inputs s1, s2 for a fixed time.

Usage

1
  makeGrid.trans(time, dt, s1.seq, s2.seq, lam, v, mu)

Arguments

time

A number corresponding to the desired evaluation time of ODE

dt

A number giving the increment length used in solving the ODE

s1.seq

A vector of complex numbers; initial values of the ODE G

s2.seq

A vector of complex numbers as inputs of s2.seq

lam

Birth rate

v

Shift rate

mu

Death rate

Value

A matrix of dimension length(s1.seq) by length(s2.seq) of the function values

Examples

1
2
3
4
5
time = 5;  dt = 5; lam = .5; v = .2; mu = .4
gridLength = 32
s1.seq <- exp(2*pi*1i*seq(from = 0, to = (gridLength-1))/gridLength)
s2.seq <- exp(2*pi*1i*seq(from = 0, to = (gridLength-1))/gridLength)
makeGrid.trans(time,dt,s1.seq,s2.seq,lam,v,mu)

jasonxu90/bdsem documentation built on May 18, 2019, 5:54 p.m.