Team:BCCS-Bristol/Modelling/BSIM/GUI
From 2010.igem.org
(→Creating Simulations in BSim 2009) |
(→Creating Simulations in BSim 2009) |
||
Line 53: | Line 53: | ||
#The final step requires the user to state how the simulation data should be expressed. This can be in the form of an immediate preview, a recorded movie or image, or as raw data in CSV (Comma Separated Variables) format. | #The final step requires the user to state how the simulation data should be expressed. This can be in the form of an immediate preview, a recorded movie or image, or as raw data in CSV (Comma Separated Variables) format. | ||
+ | ===Creating Simulations using the GUI=== | ||
+ | |||
+ | The figure below shows the process of creating a simulation using the new BSim GUI. Note that, by packaging many of the previous steps together, this new process is cut down to 4 compulsary and 1 optional step. Also, none of the compulsary steps require the user to understand JAVA code. | ||
[[Image:GUI_Process_Diagram.JPG|thumbnail|center|upright=4|Process diagram of the steps a user must go through to produce a simulation using the new GUI]] | [[Image:GUI_Process_Diagram.JPG|thumbnail|center|upright=4|Process diagram of the steps a user must go through to produce a simulation using the new GUI]] | ||
+ | |||
+ | The first step in the process is completed automatically as soon as the GUI is opened, without any further user interaction. The next three compulsary steps are handled through dialog boxes that can be reached via the GUI 'Home' screen. Users are required to enter data in the form of numbers or mathematical equations, and can choose between options using intuitive scroll-down menus. |
Revision as of 09:06, 11 October 2010
iGEM 2010
Contents |
Graphical User Interface (GUI)
This page deals with the features and justification of the new BSim GUI. To download and install your free copy of BSim 2010 and the new BSim GUI, Please see the 'downloads' section. For instructions on how to operate the new GUI, see the 'tutorials' section.
Features
The new GUI supports many of the features of BSim 2009. These include:
- Brownian Motion
- Collisions
- Chemical fields
- Detection
- Chemical emission and consumption
- Colour signalling
- Ordinary Differential Equations (ODEs)
- Variable boundary conditions
- Directed movement (Chemotaxis)
Development
Motivation
The 2009 edition of BSim was written using an object-oriented programming language called JAVA. This was an excellent tool in which to construct BSim, as it made it very easy to produce agent-based models. However, modelling a specific system in BSim required the user to edit JAVA code. We envision a future in which BSim is a widely used and accessible modelling framework. To achieve this we needed to create an interface that allows users unfamiliar with JAVA to create simulations in BSim. This would allow BSim to be utilised by the entire synthetic biology community, rather than just specialist modellers.
Graphical User Interface (GUI) -What's new?
Past iGEM projects at BCCS-Bristol required knowledge of JAVA, mathematics and biochemistry. The 2009 edition of BSim relied heavily on the user’s knowledge of all three. By removing the need for JAVA knowledge, we have opened up BSim to a much wider category of users. The GUI only requires users to be able to express their biological system mathematically; it can then translate the user’s description of a system into JAVA code.
Who is the GUI aimed at?
The GUI is primarily aimed at users without any knowledge of JAVA. However, it is also of use to more advanced programmers, as it writes JAVA files that can be further modified using a text editor. This means advanced users can use the GUI to set a simple simulation which can be further tailored to their needs using JAVA. This saves a lot of time, as setting up a new simulation in BSim 2009 could take dozens of lines of code.
Simplifying BSim 2009
The main aims in creating the GUI were to reduce the time and background knowledge required to produce a BSim Simulation.
Creating Simulations in BSim 2009
The figure below shows the process of writing a simulation in the 2009 edition of BSim. All the steps of this process require knowledge of JAVA, and therefore are not accessible to the synthetic biological community in general. Additionally, there are too many steps in the process; slimming down the number of steps will make BSim easier to use.
The steps in the above process are described in more detail below:
- The first step in the process is the ‘imports’ step. This portion of a JAVA file lists all the other files that should be searched when a function is called. This allows a programmer to call functions defined elsewhere, rather than having to define them explicitly within the main JAVA file.
- Creating a blank simulation, is uniform across whatever type of simulation a user wishes to run. Once a blank simulation is created, it behaves like a workspace into which additional objects and behaviours can be added.
- Setting simulation options allows the user to specify the size and boundary conditions for the simulation.
- Defining bacterial classes involves specifying in detail the behaviour of any species of bacteria required in the simulation. This would also be the stage at which users would specify other objects, such as chemical fields or mesh shapes.
- Once the types of bacteria have been defined, users must specify how many of each type of bacteria they want added to the simulation, and where their initial positions are. BSim can allocate random initial positions if needed.
- The ‘ticker’ is a device that performs all the actions required during each time step. In general, the functions that are performed in each time step are defined before this point, and simply called within the ticker. The ticker also serves as the simulation clock, keeping track of how much time has passed.
- The drawer is where the display properties of objects are described. Once the existence of an object is stated (in step 3), the drawer only needs to be told what colour to display that object in.
- The final step requires the user to state how the simulation data should be expressed. This can be in the form of an immediate preview, a recorded movie or image, or as raw data in CSV (Comma Separated Variables) format.
Creating Simulations using the GUI
The figure below shows the process of creating a simulation using the new BSim GUI. Note that, by packaging many of the previous steps together, this new process is cut down to 4 compulsary and 1 optional step. Also, none of the compulsary steps require the user to understand JAVA code.
The first step in the process is completed automatically as soon as the GUI is opened, without any further user interaction. The next three compulsary steps are handled through dialog boxes that can be reached via the GUI 'Home' screen. Users are required to enter data in the form of numbers or mathematical equations, and can choose between options using intuitive scroll-down menus.