Latest Versions


Stable:
COPASI 4.6 (Build 32)
Development:
COPASI 4.5.31 (development)

VT Tribute

Chapter 7. Methods

1. Time Course Calculation

With the time course simulation, you can calculate the trajectory for the species in your model over a given time interval. There are different methods to calculate such trajectories and depending on your model, one or several of them may be appropriate to do a time course simulation of your model.

COPASI supports three different methodologies to calculate a trajectory. The first method is to do a deterministic time course simulation of your model using the LSODA [Petzold83] algorithm. For systems with small particle numbers, it is sometimes better to do a stochastic simulation rather than a deterministic one. COPASI supports a method for the stochastic calculation of time series, which is called stochastic and uses the next reaction method described by Gibson and Bruck.

Since the deterministic simulation is inappropriate for some systems but on the other hand, the stochastic simulation is too time consuming, there are some methods that try to combine the advantages of both deterministic and stochastic simulation. Most of those methods are termed hybrid methods. COPASI also includes such a hybrid method which in some systems where deterministic simulation would lead to incorrect results will give the correct time series but is still computationally less demanding than a pure stochastic simulation.

1.1. Deterministic Simulation

1.1.1. Deterministic (LSODA)

The default method in COPASI to calculate a time course is LSODA [Petzold83]. LSODA is part of the ODEPACK library [Hindmarsh83]. LSODA was written by Linda R. Petzold and Alan C. Hindmarsh. It solves systems with a dense or banded Jacobian when the problem is stiff, but it automatically selects between non-stiff (Adams) and stiff (BDF) methods. It uses the non-stiff method initially, and dynamically monitors data in order to decide which method to use.

Options for LSODA

Integrate Reduced Model

This parameter is a boolean value to determine whether the integration shall be performed using the mass conservation laws, i.e., reducing the number of system variables or to use the complete model. A value of '1' (the default) instructs COPASI to make use of the mass conservation laws, whereas a value of '0' instructs COPASI to determine all variables through ODEs.

Relative Tolerance

This parameter is a numeric value specifying the desired relative tolerance the user wants to achieve. A smaller value means that the trajectory is calculated more accurate. The default value is . Please note that best achievable relative tolerance is approximately .

Absolute Tolerance

This parameter is a positive numeric value specifying the desired absolute tolerance the user wants to achieve. Please note that for species the absolute tolerance is applied to the concentration value. The default value is .

Adams Max Order

This parameter is a positive integer value specifying the maximal order the non-stiff Adams integration method shall attempt before switching to the stiff BDF method. The default and maximal order is '12'.

BDF Max Order

This parameter is a positive integer value specifying the maximal order the stiff BDF integration method shall attempt before switching to smaller internal step sizes. The default and maximal order is '5'.

Max Internal Steps

This parameter is a positive integer value specifying the maximal number of internal steps the integrator is allowed to take before the next desired reporting time. The default value is '10000'.

1.2. Stochastic Simulation

1.2.1. The Next-Reaction-Method

This stochastic simulation method utilizes the algorithm developed by Gibson and Bruck (see [Gibson00] for details). For each reaction a putative stochastic reaction time is calculated and the reaction with the shortest reaction time will be realized. The set of reactions is organized in a priority queue to allow for the efficient search for the fastest reaction. In addition, by using a so-called dependency graph only those reaction times are recalculated in each step, that are dependent on the reaction, which has been realized. This simulation method requires all the reactions to be irreversible. However, COPASI provides a tool, that converts all reversible reactions into irreversible ones. Because the algorithm internally works on discrete particle numbers rather than concentrations, the particle numbers in the system must not exceed a value of approximately .

Caution

The current implementation of the Next Reaction Method is very inefficient when the model contains assignment rules, which leads to extended calculation times.

There is a restriction regarding global quantities: If a differential equation is provided for a global quantity (the quantity is of type "ode") the model cannot be simulated stochastically with the current version of COPASI. If the global quantity is of type "assignment" stochastic simulation is possible but not as efficient as for models without assignments. No restrictions apply for "fixed" global quantities.

Options for Stochastic (Gibson + Bruck)

Max Internal Steps

This parameter is a positive integer value specifying the maximal number of internal steps the integrator is allowed to take before the next desired reporting time. The default value is '1000000'.

Subtype

This parameter is ignored in the current version of COPASI.

Use Random Seed

This flag can be '0' or '1' and determines if the user-defined random seed should be used for the calculation. The default is '0' meaning that the random seed is set to a random value before each run and consecutively calculated trajectories will be different. If the value of this flag is set to '1', the user-defined random seed will be used and each calculated trajectory will be the same for the same value of the given random seed.

Random Seed

This unsigned integer is used as random seed in the calculations, if the flag Use Random Seed is set to '1'. The default value is '1'.

1.3. Hybrid Simulation

1.3.1. Hybrid (Runge-Kutta)

This hybrid simulation method developed by us combines a deterministic numerical integration of ODEs with a stochastic simulation algorithm. The whole biochemical network is partitioned into a deterministic and a stochastic subnet internally. The deterministic subnet contains all reactions, in which only species with high particle numbers take part. All reactions with at least one low-numbered species are in the stochastic subnet, because here stochastic effects are expected. Which particle numbers are considered low or high can be specified by the user with the Lower Limit and the Upper Limit parameters (Species with particle numbers between those limits do not change their status. This leads to a hysteresis-like behavior and avoids many unnecessary swaps, if the particle numbers fluctuate in the middle range). The partitioning of the biochemical network can change dynamically during the simulation. After a certain number of steps, which the user can define using the parameter Partitioning Interval, the partitioning is recalculated using the current particle numbers in the system. During one run the deterministic subnet and the stochastic subnet are simulated in parallel. A 4th-order Runge-Kutta method is used to numerically integrate the deterministic part of the system. For the stochastic part the simulation method by Gibson and Bruck ([Gibson00]) is utilized. The reaction probabilities of the stochastic subnet are approximated as constant during one stochastic step, even though in theory they can change due to the effects of the deterministic subnet.

Caution

The current implementation of the Hybrid Runge Kutta Method is very inefficient when the model contains assignment rules, which leads to extended calculation times.

Options for Hybrid (Runge-Kutta)

Max Internal Steps

This parameter is a positive integer value specifying the maximal number of internal steps the integrator is allowed to take before the next desired reporting time. The default value is '1000000'.

Lower Limit

This parameter is a double value specifying the lower limit for particle numbers. Species with a particle number below this value are considered as having a low particle number. The lower limit cannot be higher than the upper limit. The default value is '800'.

Upper Limit

This parameter is a double value specifying the upper limit for particle numbers. Species with a particle number above this value are considered as having a high particle number. The upper limit cannot be lower than the lower limit. The default value is '1000'.

Runge Kutta Stepsize

This positive double value is the step size of the Runge-Kutta solver for the integration of the deterministic part of the system. The default value is '0.001'.

Partitioning Interval

This positive integer value specifies after how many steps the internal partitioning of the system should be recalculated. The default is '1', i.e. after every step the partitioning of the system is checked.

Use Random Seed

This flag can be '0' or '1' and determines if the user-defined random seed should be used for the calculation. The default is '0' meaning that the random seed is set to a random value before each run and consecutively calculated trajectories will be different. If the value of this flag is set to '1', the user-defined random seed will be used and each calculated trajectory will be the same for the same value of the given random seed.

Random Seed

This unsigned integer is used as random seed in the calculations, if the flag Use Random Seed is set to '1'. The default value is '1'.