Project Software

In Work Package 5 (WP5) We developed several different computational platforms for simulating collections of communicating cells. These were built in parallel, partly as a risk management strategy, but also to investigate different spatial aspects of cellular behaviour.


DiSCUS (Discrete Simulation of Conjugation Using Springs (code available at http://code.google.com/p/discus/) is a simulation framework designed by us (MMU) to represent bacterial growth, movement and horizontal gene transfer. This simulator is implemented atop an agent-based model approach, with space handled in a continuous fashion. This allows the software to handle each cell individually, and realistically manage physical interactions. This simulator combines the management of intercellular interactions with the operation of intracellular genetic networks. The goal is to better understand and predict the behaviour of bacterial colonies in the biology lab.

DiSCUS represents bacterial cells as rod-shaped objects and implements conjugation. Also, physical forces between cells are modelled as springs. ODEs are introduced inside every cell independently, so each bacterium runs its own copy of the genetic circuit according to its design. Conjugation events occur during the normal growing activity of the cells. The frequency of these events is governed by probability distributions that are tuneable for each cell type. These frequencies can be validated with experimental results and tuned by the user. Another feature that was included in the simulations is the possibility of reshuffling cells in order to obtain new donor-recipient pairs.

DiSCUS is written in Python and uses the physical engine Pymunk to model the physical interactions. DiSCUS is the first platform, to our knowledge, to offer the possibility of simulating conjugation dynamics in rod-shape bacteria. So far, it has been used to study a population-based, reconfigurable logic gate (without conjugation, below left) (Goñi-Moreno & Amos, 2012) and a multicellular comparator (using conjugation, below right) (Goñi-Moreno et al., 2013).

The following movies of DiSCUS in action are available:

  • Dynamics 1: One cell strain grows inside a cross-shaped channel. Cells have a genetic oscillator inside (stochastically simulated).
  • Dynamics 2: Six strains grow inside two square traps (three strains in each). Cells are washed out by the flow in the main channel. Objective: study plasmid loss in multi-strain small consortia.
  • Conjugation 1: Two cell strains (donor and recipient) grow over 9.85 hours. Transconjugants cannot act as new donors.
  • Conjugation 2: Donors carry a genetic oscillator (deterministically simulated) which will be transferred to recipients. Transconjugants act as new donors.


The BactoSIM I and II simulators are spatially explicit individual-based models of bacterial conjugation using a discrete representation of time and space (developed at UPM). Both models share many features. The space is defined as a discrete grid where agents are placed and evolve through their local interactions. Each agent is described as a state vector which is updated according to the model rules that take into account the local agent state and the states of neighbour agents located at adjacent cells. The rules for updating the states of each individual represent metabolic processes such as nutrient uptake, growth, reproduction and conjugation of each bacterial cell in the colony. It also takes into account also non-metabolic processes such as nutrient diffusion. Conjugation rules and the final purpose of both simulators are the main differences between both models. Both simulators are written in Java. BactoSIM I is being developed using the REPAST open source framework for asynchronous execution of the simulations. The code for BactoSIM I and II is at http://www.lia.upm.es/index.php/simulators/bactosim

In order to thoroughly understand how the plasmids are distributed and evolve in a bacterial population, it is necessary to separately identify the different aspects that affect the progression of cell-to-cell transmission and the invasion of the whole population. The final outcome of the process leading to partial or total infection of a bacterial colony can be seen as the sum of a set of contributions due to vertical and horizontal transfers as well as how much the metabolic burden contributes, as a negative feedback loop, to the pace of the conjugative process. At the most elementary level, the rate at which the infection progresses depends on how many times every single cell can spread the plasmid; it also depends on how fast the transmissions from donor cells to recipient cells and further retransmission from transconjugants cells can be accomplished. The latest version of BactoSIM I also incorporates a module to simulate the propagation of bacteriophages in bacterial populations.

iDynoMICS extension

We have also developed two modules for the iDynoMICS open source framework. One that enhances iDynoMICS by incorporating the simulation of rod-shaped bacteria. Initially, iDynoMICS only allows to simulate spherical bacteria. We have also added a new shoving algorithm for rod-shaped bacteria. The second module developed incorporates a conjugation extension to allow the simulation of plasmid propagation in biofilms. These two new modules still require experimental verification and additional parameter fitting to ensure that the conjugation dynamics and bacterial shoving are biologically correct. The code is open source and can be downloaded from the LIA group webpage at http://www.lia.upm.es/index.php/simulators/idynomics

Archive versions

Local backup (archive) versions of all of our WP5 simulators are available as follows:

Other software

Other pieces of software were developed during the course of the project. These include: