MA 432 Tue/Thur 11.45 am - 1 pm
Class-room: 1218 SAS Hall
Instructor: Mette S Olufsen
Office: SAS 3216
Office Hours: By appointment
Phone Number: 515-2678
About modeling (handout),
3. Compartment models
Euler method (Trapezoidal rule) in matlab
example using Matlabs ODE solvers
7. Notes on Euler's method and RK methods
8 Notes on
ordinary differential equations
9. Text for
chemostat model: Part 1,
Part 2, Part 3,
10. Phase plane analysis: Part1, Part2 (chemostat), Part 3
11. Text for
chemostat part 2
12. Matlab code
13. Population dynamics: Part 1, Problems
14. Disease models: SIR models, Problems, References
15: Base code
The Nelder Mead method
18. Introduction to
cardiovascular models (steady state) (pdf)
19. Cardiovascular models (steady
state): notes and exercises
20. Cardiovascular models
Time varying cardiovascular model: paper
X. Measurement of blood
X. Powerpoint version 2
X. Powerpoint version 3
X. Powerpoint version 4 (powerpoint, pdf)
Homework 1 (Due Thursday 1/16)
1: From the modeling
powerpoint presentation - do problems on slides 9, 12, 14, 16,
2: In notes on
compartment models complete problems 1.8 (2-4)
3: Complete problem on cleaning the great lakes. For (c)
set up the equations but you don't need to solve them.
2 (Due Thursday 1/23)
1: For the differential
equation y' = y(1-y) with initial conditions y(0)=0.1. Let 0
< t <= 5.
Use Euler's method, the improved Euler method, the 2nd and 4th
order Runge Kutta method. Compare results with those obtained
B: Plot the absolute error and use plots to
discuss the order of accuracy of the methods.
2: Solve the system of
equations x' = y / 60 - 3 x /40 and y' = 3 x/40 - y/ 20, with
initial conditions x(0)=1 and y(0)=0.
Let 0 < t <= 100.
Plot x(t) and y(t).
B: Plot the absolute error as you reduce the step
size h, discuss what happens to the error when you reduce h.
3: Use Matlab's build in
ODE solver ode45 to solve the same system of equations
Homework 3 (Due Tuesday 2/4)
1: Use matlab to solve
the chemostat model (see notes in 7 - above) with
= alpha1 C N / (1+C) - N
dC/dt = - C N / (1+C) - C + alpha 2
using appropriate parameter values and initial conditions.
that the solution reaches the steady state value that we predicted
2: Do problems 8
and 10 in text for chemostat problems.
3: For the chemostat
= alpha1 C N / (1+C) - N
= - C N / (1+C) - C + alpha 2
found nullclines for this model
N-nullclines dN/dt = 0 are given by N = 0 and C = 1/(1-alpha1)
C-nullclines dC/dt = 0 are given by N = (alpha2 - C) (1+C)/C
Use analysis discussed in Note on "Phase plane
analysis" given in 10 (above)
to compute direction field along each of the 3 nullclines. Also
for the two fixpoints, calculate the Jacobian
needed to determine the stability of the fixpoints. Determine
conditions for alpha1 and alpha2.
You may use pplane8 to
illustrate your solutions or you can use the online version,
which can be found at: http://math.rice.edu/~dfield/dfpp.html.
4: Interpret what
happens to the solution if we start the nutrient level N at zero
versus at some small value epsilon. Support your solution with
phaseportrait and your solution from matlab where you can plot N(t)
(Due Thursday 2/13)
1: Population dynamics
problems: 2, 7,12, 13
2: In Matlab try to
reproduce the graph shown in Fig 6.3
3: SIR models
problems: 25, 26 (Discuss the table and verify at least 3 results in
the table), 30
(Due Thursday 2/27)
Code: SIRSdata.m; SIRSsens.m;
1: Derive sensitivity equations (on paper and input in code
SIRSsens) and predict the following:
sensitivities dx/dp (x is the variable, p the parameter)
sensitivities dx/dp p/x (note you cannot divide by zero, so if x=0
for any t you need to
think about how you get relative sensitivities that makes sense.
2: The next couple of lines in the code involves
generating ranked sensitivities.
what parameter is the solution the most sensitive to?
you only have data for S, what parameter is S the most sensitive to?
you only have data for I, what parameter is I the most sensitive to?
you only have data for R, what parameter is R the most sensitive to?
3: Change initial parameter values and initial
conditions, how does that affect the sensitivities?
4: Generate data (SIRSdata) without noise, with a
medium level noise, and very noisy
5: Use fminsearch (SIRSopt) to estimate optimal
initial parameter values and initial conditions, estimate parameters
for all 3 data-sets gene
rated in 1, can you find the
correct parameters for all datasets?
Repeat simulations with 2 different parameter sets,
that are further away from the optimal values.
the code so in addition to estimating parameters you also estimate
initial conditions. Note
for this part of the problem you need to start with
values away from the initial values used for
generating the data.
(Due Thursday 3/6)
Use the harelynx data and modify codes from SIR
model to estimate parameters for a population model predicting
competition between hare's and lynx. Use the same model you used in
HW4 problem 2.
Homework 7 (Due Tuesday
3/18 - after spring break)
equations displayed on Fig 1.6 for V, P, and Q as a function of
parameters (R's, C's, and K's).
The figure can be found in the pdf and notes on
problems 1.2, 1.3, 1.4, 1.5, and 1.10 from the notes on CV models.
3: Show that the elastance function is smooth.
1: Outline topic
2: Problem formulation with
3: Model diagram
4: Discussion of how the
model can answer the proposed questions
1: Outline reduced problem and questions
2: Show data to be used
for the model
3: Show updated model
4: Discuss model
5: Show model equations
6: Show initial
Hand in outline for
report - all sections should be named, and an introduction
should be written.
Discuss briefly what goes in each
Reports and Individual questions due
OLD HW - NOT ASSIGNED YET
solutions to be handed in on paper.
Solve problems 1.14, 1.15, 1.16 from notes on CV models.
the ODEs including equations for Rav, Rmv, and plv for the
time-varying CV model.
Use diagram shown in the powerpoint/pdf on
cardiovascualr models (version 2).
3: Show that
the least squares error J can be coputed as transposed(R) x R, where
R is the model residual.
tables given in the powerpoint/pdf on cardiovascular models (version
2) to calculate initial values for all
Solutions to problems 5 and 6 can
be done with 1-2 partners (NOT IN GROUPS OF 6)
5: Complete and run the code DriverBasic.m include graphs
for all time-varying quantities.
Hand in the code and the graphs.
Graphs should be summarized in a document.
Discuss results of computations, did you get the expected
6: Vary some
of the model parameters, use results from homework 8 to choose
what parameters that should be varied.
You only need to vary 3-4
parameters. Discuss what you observe.
With the new version of the code.
sensitivities and show ranked sensitivities also show 3 (1 high,
1 medium, and 1 low) sensitive
parameters as a function of
2: Use the
code to find a subset of parameters. What parameters are
included in your subset (I don't want numbers
but names of parameters). In
DriverBasic_jacobian some parameters were kept fixed. What
happens if you leave
these out or change the fixed parameters?
parameters in your original subset estimate parameters and
plot results (use DriverBasic_SS.m) to do so
I want to see graphs not only of the state
you estimate but of all states in the model. To use optimized
in load_global_SS.m you need to load the
For all three
questions - discuss your results, relate results to those found
using the initial parameter values.
discussion relate computations to biological observations.
Relate results you have worked with to discussion
the head up tilt model presented in class today.
ALL HOMEWORK REDO'S AND LATE RETURNS DUE TUE 3/13 (AFTER SPRING
Cardiovascular homework 30%
Project 40% (report, presentations, answer to
This page was last modified January 7th 2014.