Developed by the Autonomous Agent Learning Lab (AALL) at Connecticut College.
Requires C++20 and CMake 3.16+. GUI builds also require SDL2; to build without it, configure with -DEVOSIM_ENABLE_GUI=OFF.
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make -j$(nproc)./build/evosim configs/default.tomlAny config parameter can be overridden on the command line:
./build/evosim configs/default.toml \
--seed 15 \
--total-ticks 100000 \
--inner-radius 0 \
--phenotype-traits 0 \
--output-dir results/control_flat \
-qEach run produces:
summary.json— Configuration, metrics, transplant test resultsstats.csv— Per-tick population statisticssector_matrix.csv— N×N reproduction matrix (ring mode)- Console progress (suppressed with
-q)
All parameters can be modified in the configuration file. Key parameters:
| Parameter | Default | Description |
|---|---|---|
grid.width / grid.height |
300 / 300 |
Grid dimensions |
grid.topology |
"ring" |
Topology mode: "rectangular" or "ring" |
ring.inner_radius |
60 |
Inner impassable radius for ring topology |
ring.num_sectors |
32 |
Number of angular sectors used for markers and ring analysis |
food.per_tick |
40500 |
Food generated each tick |
food.gradient_amplitude |
1.0 |
Strength of the ring food gradient (0.0-1.0) |
reproduction.active_phenotype_traits |
4 |
Number of phenotype traits used in mate filtering (0-4) |
reproduction.fixed_phenotype_tolerance |
3 |
Fixed phenotype tolerance override; -1 keeps evolved tolerance |
reproduction.hybrid_fitness_cost |
0.0 |
Per-unit phenotype-distance penalty on child starting energy |
simulation.total_ticks |
50000 |
Total number of simulation ticks |
src/
core/ Grid, agents, chromosomes, food, barriers, config, simulation loop
controller/ Main agent controller
reproduction/ Mate compatibility, crossover, mutation, child placement
analysis/ Speciation tracking (marker matrix, hybrid counting), statistics output
topology/ RectTopology, RingTopology (annular with central obstacle)
viz/ SDL2 visualizer and headless fallback
third_party/
toml.hpp toml++ single-header config parser
doctest.h doctest single-header test framework
tests/
test_main.cpp Unit tests (chromosomes, grid, agent pool, energy, RNG)
configs/
default.toml Example configuration file
cd build && cmake .. -DCMAKE_BUILD_TYPE=Debug && make -j$(nproc) && ./evosim_tests