**Table of Contents**

MesoRD is a tool for stochastic and
deterministic simulation of chemical reactions and diffusion in
3D, and planar 2D spaces^{[1]}.

The description of the system that you want to simulate is written in the SBML file format [Finney and Hucka 2003] . The SBML file contains all information about the species, reactions, reactions rates, compartment geometries, diffusion constants etc. In addition to the SBML file, MesoRD will require information about how the simulation should be executed, such as spatial discretisation of the reaction volume, duration of the simulation, visualisation, output options, and for deterministic simulations, also choice of integration method. These parameters are given through the MesoRD user interface. The output files from MesoRD are intended for external data analysis and visualisation packages, for instance the freely distributed MesoRD Matlab toolbox available from the MesoRD website.

In both the deterministic and the stochastic mode of simulation
the reaction volume is discretised into a large number of small
subvolumes and the state of the system is given by the number of
molecules per subvolume. In the stochastic simulation the number
of molecules per subvolume are discrete. Furthermore, the
reaction and diffusion events that change the number of molecules
are probabilistic, in the sense that the next event in the systems
is sampled from a distribution function. In the deterministic
simulation the state is assumed to be a continuous variable and
the change in the number of molecules per time unit is given by
the average change as defined from the stochastic model. A more
detailed description of the differences between the stochastic and
deterministic way of modelling is given in the theory section
Chapter 6, *
Rates and state changes in MesoRD
*.

One example of a system that can be easily modelled in MesoRD is the one illustrated in the figure below. B-molecules are synthesised by a membrane bound A-molecule. The B-molecules diffuse into the cytoplasm and are degraded or modified in a first order reaction. Some B-molecules reaches an intracellular compartment, where they dimerise into a D molecule, which also can be degraded.

The system has a non-trivial geometry, it is non-homogeneous, and
it may have some interesting stochastic properties. It is
therefore suitable for simulation in
MesoRD. How this model is described in
SBML for MesoRD is described further in
Chapter 7, *
Tutorial
*.

The rest of the introduction includes the section called “ Mission Statement ”, the section called “ System Requirements ”, the section called “ Project Status ”, the section called “ Citing use of MesoRD ”, and the section called “ Funding ”, but maybe you want to start making models.

Constructing models for MesoRD is mainly a question about writing, or generating as it may be, valid SBML [Hucka et al 2008] files. However, there are some special considerations one has to keep in mind when working with MesoRD.

Chapter 3,

*Writing SBML for MesoRD*contains information on how to write SBML files for MesoRD. Note that this documentation by no means is a replacement for the SBML language documentation. If you are not familiar with SBML, [Hucka et al 2008] may be a good starting point.The construction of geometries is discussed separately in Chapter 4,

*Constructive Solid Geometry*. The geometry specification is the largest MesoRD specific addition to the model-files compared to standard SBML. Currently SBML has no support for geometry definitions.Chapter 5,

*The User Interface*describes the user interfaces available to control the launching of simulations. It covers the parameters that are not included in the SBML model definitions and the output file formats.Chapter 6,

*Rates and state changes in MesoRD*contains information on how stochastic and deterministic reaction-diffusion systems are treated in MesoRD.Chapter 7,

*Tutorial*is a small tutorial, giving a full description of how to translate the example from the section called “ An introductory Example ” into valid SBML for MesoRD.

All this assumes that MesoRD has been
successfully installed. Installation is covered in Chapter 2, *
Installation
*. The impatient may as well skip
ahead to any of the above chapters.