This repository contains python codes for the articel "Data-driven model reduction of agent-based systems using the Koopman generator" by Jan-Hendrik Niemann, Stefan Klus and Christof Schütte.
https://arxiv.org/abs/2012.07718
There are three models predefined:
- A voter model defined as a Markov jump process,
VoterModel.py
- An extened voter model defined on arbitrary networks,
ExtendedVoterModel.py
- A spatial predator-prey model,
PredatorPreyModel.py
- Create measurements with
demo_data_generation.py
. The script illustrates the procedure using the agent-based model inVoterModel.py
. There are some pre-generated measurements in the directorydata/raw
. - Process the data to obtain point-wise estimates of drift and diffusion. Use gEDMD to learn a global description. The procedure is demonstrated in
demo_post_processing.py
. There are some post-processed measurements in the directorydata/processed
. - The reduced stochastic differential equation can now be simulated. This is demonstrated in
demo_reduced_SDE.py
. - The evaluation is demonstrated in
demo_evaluation.py
.
The codes require the d3s - data-driven dynamical systems toolbox: https://github.com/sklus/d3s