Team:Newcastle/Modeling/Population/Pseudo/Bacteria Code

From 2009.igem.org

Revision as of 02:14, 22 October 2009 by TubularWorld (Talk | contribs)


Contents

Cells Pseudo code

This will give a brief outline of what our simulated bacterial cells will do throughout their 'lives'. The life cycles shown here loop continuously, until it has a reason to stop (eg if it is dead).

This will also give a brief description of the methods which are called during the life cycle. Methocs and variables are inherited from the superclass.

Cell (Superclass, common features)

Methods

  • takeTurn - allow the cell's states to run their life cycles.
  • hasSufficentFood - check if there is enough food to duplicate.
  • importCadmium - import cadmium from the environment (MntH)
  • exportCadmium - export cadmium to the environment (CadA)
  • importFood - import nutrients from the environment.
  • isLiving - checks to see if it is alive, and using CPU power.
  • log - write timestamped log data to the database.
  • run - run as a thread (ie looping).
  • setState - set a textual representation of the current state of the cell.
  • suicide - death of a cell - makes the thread inactive.

Subtilis (Vegetative Cell)

Life Cycle

  • Checks if the current run has been ended.
  • Checks if the cell is going to die from an overdose of cadmium.
  • Imports some nutrients and cadmium, etc from the environment.
  • Checks to see if cadmium has been detected inside the cell.
    • If detected, it will make a decision to be a metal sequestering cell, or not.
      • Runs a JSim instance using parameters from the cell and runs the Sin Operon CellML model.
  • If it is in the 'sporulating' state, advance closer to sporulating.
  • If there is not sufficient nutrients, size, etc to duplicate, it may decide to enter other states such as Biofilm, Motile or Spore.
  • If there is sufficient nutrients, size, etc to duplicate, make a daughter cell
    • Creates a database request that in turn makes Microbase create a new 'job' (cell).

Methods

  • taketurn - perform one loop of life cycle.
  • findSpace - try to find a space to divide into.
  • getSet - various sequestering and sporulating checks.
  • hasCadmiumOD - checks if there is an amount of cadmium in the cell that would kill it.
  • isSequestering - checks if it is going to be sequestering.
  • isSporulating - checks if it is sporulating.
  • isRunOver - checks the database to bee if the run has been terminated.
  • sporulatingTurn - advances through sporulation.
  • willSequester - decides if it is going to sequester cadmium.
  • willSporulate - decides if it will sporulate this turn currently runs JSim model.

Motile

Life Cycle

  • Checks if the current run has been ended.
  • It may decide to become change back into the vegetative state.

Methods

  • taketurn - perform one loop of life cycle. Decide to vegetate.

Biofilm

Life Cycle

  • Checks if the current run has been ended.
  • It may decide to become change back into the vegetative state.

Methods

  • taketurn - perform one loop of life cycle. Decide to disperse the cells.

Spore

Life Cycle

  • Checks if the current run has been ended.
  • If it is able to germinate (ie not a cadmium sequestering spore) and correct conditions.
    • Advance through a germination step.
    • If all germination steps have taken place, change back into the vegetative state.

Methods

  • taketurn - perform one loop of life cycle.
  • isCanGerminate - Checks if the spore can germinate (not a metal sequester spore).
  • willGerminate - Determines if it is to germinate on this turn.



News

Events

Social Net

  • Newcastle iGEM Twitter
  • [http://www.facebook.com/home.php#/group.php?gid=131709337641 Newcastle on Facebook]
  • [http://www.youtube.com/user/newcastle2009igem Newcastle Youtube Channel]