Epidemiology: The SEIR model: Difference between revisions
From JSXGraph Wiki
A WASSERMANN (talk | contribs) No edit summary |
A WASSERMANN (talk | contribs) No edit summary |
||
Line 57: | Line 57: | ||
function turtleMove(turtle,dx,dy) { | function turtleMove(turtle,dx,dy) { | ||
turtle.MoveTo([dx+turtle.pos[0],dy+turtle.pos[1]]); | |||
} | } | ||
function loop() { | function loop() { | ||
var dS = mu.Value()*(1-S.pos[1])-beta*I.pos[1]*S.pos[1]; | var dS = /*mu.Value()*(1-S.pos[1])*/-beta*I.pos[1]*S.pos[1]; | ||
var dE = beta*I.pos[1]*S.pos[1]-(mu.Value()+a.Value())*E.pos[1]; | var dE = beta*I.pos[1]*S.pos[1]-(mu.Value()+a.Value())*E.pos[1]; | ||
var dI = a.Value()*E.pos[1]-(gamma.Value()+mu.Value())*I.pos[1]; | var dI = /*a.Value()*E.pos[1]*/-(gamma.Value()+mu.Value())*I.pos[1]; | ||
var dR = gamma.Value()*I.pos[1]-mu.Value()*R.pos[1]; | var dR = gamma.Value()*I.pos[1]/*-mu.Value()*R.pos[1]*/; | ||
turtleMove(S,delta,dS); | turtleMove(S,delta,dS); | ||
// turtleMove(E,delta,dE); | |||
turtleMove(I,delta,dI); | turtleMove(I,delta,dI); | ||
turtleMove(R,delta,dR); | turtleMove(R,delta,dR); |
Revision as of 07:51, 27 April 2009