Genetics & Evolution — 3D Simulations
🧬

Genetics & Evolution

Mutation, selection, crossover — the same forces that shaped all life on Earth, now running at millions of generations per second in your browser. Watch populations adapt, compete, and collapse.

6 simulations Canvas 2D · WebGL GA · Lotka-Volterra · Emergence

Category Simulations

Digital organisms, evolving populations and predator-prey ecosystems

Evolution is an algorithm — a search through fitness landscapes guided by random variation and non-random selection. Genetic algorithms borrow exactly this logic to solve optimisation problems. Predator-prey models show how populations oscillate without any central controller, driven purely by local interactions.

🔀
★★☆ Moderate
Genetic Algorithm
A population of candidate solutions evolves via tournament selection, single-point crossover and bit-flip mutation. Watch fitness converge toward a target — adjust population size, mutation rate and crossover probability live.
Canvas 2D GA Selection Crossover
🐇
★☆☆ Beginner
Fox & Rabbits
Agent-based Lotka-Volterra: individual foxes hunt rabbits on a 2D grid. Tune birth rates, energy and carrying capacity; watch the classic predator-prey oscillation emerge from thousands of individual decisions.
Canvas 2D Agent-Based Lotka-Volterra Ecology
📉
★☆☆ Beginner
Prey-Predator ODE
The original Lotka-Volterra ODEs solved in real time with RK4. Phase-space portrait shows the closed orbit; tune α, β, γ, δ and watch the population cycle grow, shrink or collapse toward extinction.
Canvas 2D ODE Phase Space RK4
♟️
★☆☆ Beginner
Conway's Game of Life
Classic cellular automaton in which four birth/survival rules drive complex emergent behaviour — gliders, oscillators, guns. Load RLE patterns from a built-in library or draw your own.
Canvas 2D Cellular Automaton Emergence Turing Complete
🌱
★★☆ Moderate
Natural Selection
Population of creatures with heritable speed, sense-radius and camouflage. Predators hunt; survivors breed. Watch traits shift toward an ESS across hundreds of generations on a live fitness histogram.
Canvas 2D Heritable Traits ESS
🎲
★★☆ Moderate
Evolutionary Game Theory
Hawk-Dove, Prisoner’s Dilemma and Rock-Paper-Scissors on a spatial grid. Replicator dynamics drives strategy frequencies; watch mixed-strategy Nash equilibria and ESS emerge in real time.
Canvas 2D Replicator Dynamics Nash Equilibrium
🧬
★★☆ Moderate New
Mendelian Genetics
Interactive Punnett squares for monohybrid and dihybrid crosses. Hardy-Weinberg equilibrium with allele frequency charts and Monte-Carlo offspring simulation.
Canvas 2D Punnett Square Hardy-Weinberg
🧬
New ★★ Intermediate
DNA Transcription
RNA polymerase unwinds the double helix, reads the template strand and synthesises a complementary mRNA molecule base by base. Watch the transcription bubble open and close, and see codons form.
RNA Polymerase mRNA Codon

Key Concepts

Mathematics of evolution and population dynamics

Genetic Algorithm
Encode candidates as chromosomes (bit-strings, permutations, trees). Evaluate fitness. Select fitter individuals more likely for reproduction (tournament, roulette). Crossover recombines two parent chromosomes. Mutation flips bits with probability p_m. Schema theorem: building blocks with above-average fitness grow exponentially.
Lotka-Volterra ODEs
dx/dt = αx − βxy (prey); dy/dt = δxy − γy (predator). Closed orbits in phase space: populations perpetually oscillate. Adding carrying capacity (logistic prey) allows stable spirals. Stochastic ABM version adds demographic noise — populations can go extinct.
Fitness Landscape
Map from genotype space → fitness value. Smooth landscapes are easy for gradient methods; rugged (Kauffman NK) landscapes require exploration. Evolution climbs hills but can get stuck; sexual recombination leaps across valleys. Understanding the landscape topology guides algorithm design.
Cellular Automaton
Grid of cells, each with a finite state (alive/dead). Every step: each cell counts live neighbours and applies the rule (B3/S23 for Conway). Local rules → global complexity. Wolfram classification: CA range from fixed points (Class I) to complex life-like behaviour (Class IV) to chaos (Class III).

Learning Resources

Articles on evolution and population dynamics

About Genetics & Evolution Simulations

DNA, natural selection, genetic drift, and fitness landscapes — modelled

Genetics and evolution simulations model the mechanisms that drive biological diversity. Genetic algorithm simulations encode candidate solutions as binary chromosomes and apply selection, crossover, and mutation operators, allowing you to watch fitness scores improve generation by generation. Population genetics models track allele frequencies over time under selection pressure, mutation rates, and genetic drift, reproducing Hardy–Weinberg equilibrium and its violations.

Evolutionary simulation environments place digital organisms in a resource landscape where hereditary variation and differential reproduction drive adaptation. L-system plant-growth simulations demonstrate how a handful of morphogenetic rules can generate the entire diversity of botanical branching patterns. These models connect computational biology with evolutionary theory, showing how random variation and selection pressure together produce extraordinary complexity without any guiding intelligence.

Genetics simulations illuminate the mathematics of evolution. Population genetics equations, developed by Fisher, Haldane, and Wright in the 1920s-30s, predicted the molecular mechanisms of evolution decades before the discovery of DNA. Today these same equations model COVID-19 variant evolution, cancer clonal dynamics, and crop improvement programmes. Understanding them through simulation provides a quantitative foundation for biology, medicine, and conservation science.

Key Concepts

Topics and algorithms you'll explore in this category

Hardy-Weinberg EquilibriumAllele frequency stability under ideal conditions
Genetic DriftRandom allele frequency changes in finite populations
Natural SelectionDifferential reproduction based on fitness
Mutation RateProbability of base-pair substitution per replication
Crossover / RecombinationExchange of genetic material between homologues
Population GeneticsAllele frequency trajectories over generations

🧬 Test Your Genetics Knowledge

Five quick questions to check your understanding of genetics and DNA

Genetics Quiz

Frequently Asked Questions

Common questions about this simulation category

What is the Hardy-Weinberg equilibrium?
In an infinitely large, randomly mating population with no selection, mutation, or migration, allele frequencies remain constant across generations. The equilibrium predicts genotype frequencies: p² (AA) + 2pq (Aa) + q² (aa) = 1. Deviations reveal evolutionary forces at work.
How does genetic drift differ from natural selection?
Genetic drift is random — allele frequencies fluctuate by chance due to finite population size, potentially fixing or eliminating alleles regardless of fitness. Natural selection is directional — beneficial alleles increase in frequency because carriers reproduce more. Both operate simultaneously in real populations.
Can I simulate evolution of antibiotic resistance?
Yes — the simulation models a bacterial population with random mutation rates and selectable resistance genes. Applying antibiotic 'pressure' shows how quickly resistance sweeps to fixation. This directly models the evolutionary dynamics underlying the global antibiotic resistance crisis.

Other Categories