Three flagella assembly simulations wrapped as process-bigraph Processes using BioNetGen/NFSim network-free stochastic simulation. Each configuration demonstrates a distinct assembly scenario with interactive visualization.
The bacterial flagellum is assembled from ~30 different proteins through seven sequential complexation reactions. Multi-subunit assembly (up to 120 copies of FlgE for the hook) is modeled using a scaffold-with-counters strategy that generates 237 reaction rules from 7 biological reactions.
| # | Product | Subunits | Total |
|---|---|---|---|
| 1 | flhDC | 4× flhD + 2× flhC | 6 |
| 2 | flagellar motor switch | 26× fliG + 34× fliM + fliN | 61 |
| 3 | flagellar export apparatus subunit | flhA + flhB + fliO + fliP + fliQ + fliR + fliJ + 6× fliI | 13 |
| 4 | flagellar export apparatus | flagellar export apparatus subunit + 12× fliH | 13 |
| 5 | flagellar motor | flagellar motor switch + 2× fliL + flgH + motA + motB + flgB + flgC + flgF + flgG + flgI + fliF + fliE | 13 |
| 6 | flagellar hook | 120× flgE | 120 |
| 7 | flagella | flagellar export apparatus + flagellar motor + fliC + flgL + flgK + 5× fliD + flagellar hook | 11 |
NFSim simulates these rules efficiently without enumerating the species space, using a network-free stochastic approach that scales well for large rule sets.
Fixed monomer pool, hierarchical flagella assembly
Starting with enough monomers for 5 flagella (N=5), NFSim simulates 500 seconds of stochastic rule-based assembly. Complexes form hierarchically: FlhDC first (smallest, 6 subunits), then motor switch (61 subunits), export apparatus, motor, the 120-subunit hook, and finally complete flagella. This demonstrates the NFSimProcess bridge pattern running standalone.
Continuous monomer production + complexation via process-bigraph
Two processes composed via process-bigraph wired to shared state: MonomerProduction adds monomers every 1s at gene-expression rates (~1 flagellum worth per 100s), while NFSimProcess runs NFSim every 50s to assemble accumulated monomers. Monomer pools show sawtooth dynamics as production accumulates them between complexation steps. This is the core workflow demonstrating process composition.
Accelerated monomer production for rapid assembly
Same composed workflow but with 3x monomer production rate, simulating overexpression of flagellar genes. The higher supply rate leads to faster assembly kinetics and larger monomer pools between complexation steps. Compare with the steady production configuration to see how production rate affects assembly yield.