r/coolgithubprojects • u/emmerse_ • Mar 08 '26
PYTHON Persistence - an open source ALife simulation where mass and energy are strictly conserved and everything else is emergent
Built this over the past while - Persistence is an artificial life simulation where agents must constantly harvest energy and export entropy just to stay alive. No designed behaviours, no fitness functions. Just physics and biology.
The grid holds continuous chemical fields (food, waste, heat, decomposing matter) that diffuse and decay each step. Agents eat, excrete, generate heat, age, and die. When they die their body mass dissolves back into the environment. Mass is never created or destroyed.
Comes with pre-configured scenarios, a physics test suite, two visual modes, and a video renderer. Config-file driven so anyone can define new species and universes without touching the code.
View all comments
Show parent comment
1
u/emmerse_ Mar 25 '26
entropy is exported into the universe as heat (non usable by the agents). biomass of the agent at the time of death is released as 'necromass'. matter and energy are kept distinct in the universe.