300 likes | 434 Views
COMPUTER MODELS IN BIOLOGY. Bernie Roitberg and Greg Baker. WHERE NUMERICAL SOLUTIONS ARE USEFUL. Problems without direct solutions. WHERE NUMERICAL SOLUTIONS ARE USEFUL. Problems without direct solutions Complex differential equations. WHERE NUMERICAL SOLUTIONS ARE USEFUL.
E N D
COMPUTER MODELS IN BIOLOGY Bernie Roitberg and Greg Baker
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without directsolutions
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes • Individual-based problems
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes • Individual-based problems • Stochastic problems
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without directsolutions
HOW TO SOLVE THE EULER • Start with lnR0/G ≈ r
HOW TO SOLVE THE EULER • Start with lnR0/G ≈ r • Insert ESTIMATE into the Euler equation. This will yield an underestimate or overestimate
HOW TO SOLVE THE EULER • Start with lnR0/G ≈ r • Inserted ESTIMATE into the Euler equation. This will yield an underestimate or overestimate • Try successive values that approximate lnR0/G until exact value is discovered
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations
THE CONCEPT • For small changes in x (e.g. time) the difference quotient Dy/Dx approximates the derivative dy/dx i.e. dy/dx = Dx 0 Dy/Dx • Thus, if dy/dx = f(y) then Dy/Dx≈ f(y) for small changes in x • Therefore Dy ≈ f(y) Dx
THE GENERAL RULE • For all numerical integration techniques: y(x + Dx) = yx + D y
EULER SOLVES THE EXPONENTIAL dn/dt = rN DN/Dt ≈ rN DN ≈ rN Dt N(t+Dt) = Nt + DN Repeat until total time is reached.
NUMERICAL EXAMPLE • N 0+Dt = N0 + (N0 r DT) t = 0.1 • N.1 = 100 + (100 * 1.099 * 0.1) = 110.99 • N.2 = 110.99 + (110.99 * 1.099 * 0.1) =123.19 • N.3 = 123.19 + (123.19 * 1.099 * 0.1) =136.73. • …... • N1.0 = 283.69 • Analytical solution = 300.11
INSIGHTS • The bigger the time step the greater is the error • Errors are cumulative • Reducing time step size to reduce error can be very expensive
RUNGE-KUTTA N Dt
RUNGE-KUTTA • ∆yt = f(yt) ∆ t • yt+ ∆ t = yt + ∆ yt • ∆ y t+ ∆ t = f(yt+ ∆ t ) • y t+ ∆ t = yt + ((∆yt + ∆ y t+ ∆ t )/2)
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes
COMPLEX FITNESS LANDSCAPES • Employing backwards induction to solve the optimal when state dependent • Numerical solutions for even more complex surfaces • Random search • Constrained random search (GA’s)
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes • Individual-based problems
INDIVIDUAL BASED PROBLEMS • Simulate a population of individuals that “know” the theory but may differ according to state
WHERE NUMERICAL SOLUTIONS ARE USEFUL • Problems without direct solutions • Complex differential equations • Complex fitness landscapes • Individual-based problems • Stochastic problems
STOCHASTIC PROBLEMS • Two issues: • Generating a probability distribution • Drawing from a distribution
FINAL PROBLEM • What do you do with all those data?