Modeling Infectious Diseases in Humans and Animals
Matt J. Keeling & Pejman Rohani


These web pages contain all the programs labelled in the book "Modeling Infectious Diseases in Humans and Animals". They are generally available as C++, Fortran and Matlab files, while some are also coded in web-based java to allow readers to quickly experiment with this type of model.

This set of web pages is organised by chapter, then program and finally the desired lanuage. The web pages associated with each program have a standard format: a brief desciption of the model is given along with the equations, followed by a table of parameters. In this table parameters that have not been encountered in earlier programs are highlighted in yellow, whereas parameters highlighted in gray have their value fixed within the program (eg. forcing birth and death rates to be equal).  There is also an additional section for programming contributions from other researchers. All these can be navigated through the side bar.

The C++ and Fortran codes allow parameters to be read from a file, as well as having default parameters hard-coded into the programs -- to keep the programs simple, the structure of these parameter files must be maintained. The Matlab code takes the parameters as part of the input comand line.

Two points must be stressed about all the programs. Firstly they are simple examples which can be readily compiler, understood and altered, they are not necessarily the most efficient means of programming and a certainly not to be considered as examples of how to program. Secondly, although the examples are intendent to be robust, they are not idiot-proof. Extreme parameters (such as an R0 of several million) may cause spurious results.

A few final passing remarks:
1) Although we are happy to hear from readers and researchers by email, please check the FAQ and Erratum sections before telling us about any mistakes or suggestions.
2) These programs are meant to be used in conjuction with our book. Therefore if you use any of the programs in your research, we ask that you reference:
Keeling, M.J. and Rohani, P. (2007) Modeling Infectious Diseases in Humans and Animals. Princeton University Press.

We hope you enjoy the book and programs,

 Matt & Pej.

Questions and comments to: or
Princeton University Press
Our research web pages:
Matt Keeling      Pejman Rohani