Software #1 Logic - Biological Logic Gate Construction Simulation Software

Introduction

Logic Diffusion Simulator is a Godot-based software designed to simulate, on a computer, the experimental process of placing engineered bacterial colonies on an agar plate to construct biological logic gates.

This simulator provides researchers with inspiration for colony spatial arrangement and new logic gate design, and also serves educational purposes—helping the public better understand how engineered colonies can be used to build biological logic gates, and allowing users to try constructing their own logic gates digitally.

Mathematical Simulation

With the aid of precise computational modeling, this project establishes a simplified mathematical model suitable for dynamic interactive simulations. We adopt the Gaussian solution of the diffusion equation and propose the following formulation:

\[C(r,t) = C_0 e^{-kt} \exp\left(- \frac{r^2}{4D(t + t_0)}\right)\]

  • \(C_0\): Initial central concentration (reference value at the instant of the event).
  • \(\lambda\): Central first-order decay rate (unit: per hour).
  • \(D\): Diffusion coefficient (related to diffusion rate, unit: distance²/time).
  • \(t_0\): Time difference between system start and the actual onset of diffusion.
  • \(r\): Spatial distance.

By taking the derivative of the function with respect to $t$ at a fixed $r$, we can determine the time and magnitude of the peak concentration at distance $r$ from the source:

\[t^* = \frac{r}{2\sqrt{Dk}} - t_0\]

\[C_0 \exp(kt_0) \exp\left(- r\sqrt{\frac{k}{D}}\right)\]

In the program, diffusion begins simultaneously with simulation start, so $t_0 = 0$, meaning there is no time offset. The equation thus simplifies to:

\[t^* = \frac{r}{2\sqrt{Dk}}\]

\[ C_{\text{max}}(r) = C_0 e^{kt_0} e^{-r\sqrt{k/D}} \xrightarrow{t_0 = 0} C_0 e^{-r\sqrt{k/D}} \]

This yields a set of computationally efficient simplified models suitable for large-scale numerical operations, forming the foundation for building fast, interactive, and complex game-like simulation software.

User Guide

Launching the Program

Run Logic.exe to enter the home page:

Home Page

Click Settings to adjust configurations, or click New Game to start a new experiment. If a save file exists, click Continue to resume from the last saved experiment.

Placing Colonies

Click the three circular colony buttons on the top left to enter High-Pass, Band-Pass, and Input Source placement modes, respectively.

In these modes, left-click on the screen to place colonies.

If the colony position is unsatisfactory, drag it to reposition.

Placing Colonies

After finishing placement, click Start to begin diffusion simulation. The colonies will then respond according to their properties.

(Note: The diffusion animation is only a visual cue; for actual diffusion results, refer to the section below.)

Peak Display Mode

Click Peak Page to enter peak display mode.

In this mode, the software renders the peak signal concentrations at different distances from the input source:

  • In the blue region, high-pass colonies respond.
  • In the green region, band-pass colonies respond.
  • In other regions, no colonies respond.
Peak Display Mode

Distance Display Mode

Right-click a colony to select it (the selected colony will be highlighted).

Then click Show Distance to enter distance display mode, where the Manhattan distances between colonies are shown.

You can drag colonies during this mode, and the displayed distances will update dynamically.

Distance Display Mode

Half Adder Mode

Click Half Adder to enter the half-adder placement mode.

You can place a preconfigured half-adder logic gate model.

Left-click to choose the placement position, then drag to set the orientation.

Click Confirm to finalize the placement.

Additionally:

  • Press Ctrl+Z or click Withdraw to undo your last placement
  • Click Delete to clear all colonies on screen.
  • Click the Speed button at the top right to switch between 1× and 2× simulation speed.
Half Adder Mode

Pause and Restart

Click the Pause button to enter the pause page.

  • Restart: Return to the initial arrangement of this experiment (if loaded from a previous save, it restores that saved state).
  • Continue or the top-right icon: Resume the experiment.
  • Home: Save the current experiment and return to the home page.
Settings Page

Settings Page

In the Settings page, you can change the window format or adjust the diffusion coefficient and colony response thresholds as needed.

  • Enter new numerical values in the input fields and press Enter.
  • Click Confirm to apply changes.
  • Click Default to restore initial values (you must still click Confirm afterward).
  • Click Close to return to the home page.
Settings Page

Diffusion Real-Time Tracking Display

After pressing the Start button and entering the Peak Page, you can monitor the real-time concentration of each point at the current moment (indicated by color brightness).

The display principle remains the same as before:

  • Blue indicates regions capable of activating high-pass gates.
  • Green indicates regions capable of activating band-pass gates.
Diffusion Real-Time Tracking Display
Diffusion Real-Time Tracking Display

Note:Please do NOT return to the main menu before pressing Stop to halt the logic gate operation, as this may cause the Peak Page mode to malfunction. If this occurs, simply restart the software to restore normal functionality.

Software #2: Logic - Enhanced Biological Computer Simulator

To facilitate the design, optimization, and testing of our LOGIC biological computing system, we developed an interactive computational simulator. This software tool allows researchers to visualize molecule diffusion patterns, predict system behavior, and optimize component placement before conducting wet-lab experiments. The simulator provides real-time visualization of AHL (Acyl-Homoserine Lactone) molecule diffusion and enables precise control over molecule-specific physics parameters.

Key Features

Interactive Biological Computer Simulation

Our simulator models a complete 7-component biological computing system that performs binary addition operations:

  • Cell - Half Adder Carry: Implements AND logic for carry generation
  • Cell - Half Adder Sum: Implements XOR logic for sum calculation
  • Cell - Signal Amplifier: Amplifies carry signals between stages
  • Cell - Full Adder Sum: Computes sum output for full addition
  • Cell - Full Adder Carry: Generates carry output for full addition
  • Cell - Result Display S: Visualizes sum output through fluorescence
  • Cell - Result Display C: Visualizes carry output through fluorescence

Molecule-Specific Diffusion Control

The software implements sophisticated physics modeling for four distinct AHL molecules, each with customizable parameters:

  • AHL1: Generic input signal molecule
  • 3-oxo-C12-HSL: Carry signal propagation
  • C4-HSL: Sum signal transmission
  • C6-HSL: Display signal molecule

Each molecule type features independently adjustable diffusion coefficients, decay rates, and release multipliers for fine-tuning system behavior.

Real-Time Molecule Detection

A novel detection system allows users to probe local molecule concentrations at any point in the simulated petri dish, visualize concentration gradients with adjustable detection radius, monitor individual molecule distributions in real-time, and track total system concentrations across all AHL types.

Component Configuration Panel

The configuration interface provides comprehensive control over input sources, logic gates, display components, and system parameters through an intuitive graphical interface.

Implementation Architecture

Diffusion Simulation Engine

The core simulation engine implements the reaction-diffusion equation using a finite difference method on a discretized grid. The algorithm accounts for molecule-specific diffusion rates, decay kinetics, and boundary conditions to accurately model spatial concentration distributions.

Logic Gate Processing

Each logic gate component processes local AHL concentrations to generate appropriate outputs based on threshold-based activation functions. AND gates activate when total input concentration exceeds a high threshold, XOR gates activate within specific concentration bands, and amplifiers proportionally enhance input signals with saturation limits.

Visualization System

The software provides multiple synchronized views including a main display showing component positions and concentration fields, molecule analysis charts, real-time detection displays, and system status panels.

Applications

The simulator serves multiple purposes in our project: system design optimization for testing component arrangements and predicting signal propagation, parameter tuning for optimizing release rates and detection thresholds, and as an educational tool for teaching principles of diffusion-based biological computation.

User Manual

Software #3: Logic - Bacterial Fluorescence Prediction System

This integrated software suite enables researchers to analyze and predict bacterial fluorescence.

More information can be found on our Measurement Page.