Skip to main content

A Python package for System Dynamics Modeling

Project description

asdm

Agile System Dynamics Modelling

ASDM is a python library that enables its users to create and simulate System Dynamics (SD) models. It can also simulate SD models saved in the XMILE format, including advanced features such as arrays and conveyors. The support is being continuously improved.

In the library:

  • asdm/asdm.py consists of the main functionalities, including the lexer, parser, and interpreter.

  • asdm/utilities.py provies a data visualisation tool.

  • asdm/Inference consists of tools for model calibration.

Installation

Install from PyPi

pip install asdm

ASDM and its required dependencies will be automatically installed.

Import

At any path, execute the following code in the interactive Python environment or as a part of a script:

from asdm import sdmodel

'sdmodel' is the class for System Dynamics models.

Functionalities

Please refer to Documentation for the commonly used functions.

Tutorial Jupyter Notebooks

We also use Jupyter Notebooks to provide demoes of ASDM's functionalities.

SD Modelling

  • Creating an SD model from scratch
    • Adding stocks, flows, auxiliaries
    • Support for nonlinear functions (MIN, MAX, etc.)
    • Support for stochastic functions (random binomial trial, etc.)
  • Running simulations
  • Exporting and examing simulation outcomes
  • Displaying simulation outcomes as graph

Support for .stmx models

  • Load and simulate .stmx models
  • Support for arrays
  • Simulate .stmx models with modified equations

We will add more tutorial notebooks.

You are welcomed to share your own tutorial notebooks through a pull request. When sharing notebooks, please make sure it does not contain sensitive data.

Licence

ASDM is made public under the MIT licence.

Contributors

Wang Zhao main author

PhD candidate & research assistant at University of Strathclyde, UK

Wang has given multiple talks on ASDM at different gatherings and conferences of modellers, operational researchers, and healthcare experts. This is the YouTube link to one of the talks.

Wang can be reached at wang.zhao@strath.ac.uk.

Matt Stammers contributor

Consultant Gastroenterologist & open-source software developer at University Hospital Southampton, UK

Matt created a webapp using streamlit to allow users to interact with a simulation dashboard in their web browsers or on smartphones, such as in this demo. The simulation of the SD model in the backend is powered by ASDM. This is a part of an initiative Really Useful Models.

Matt's GitHub Homepage

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

asdm-0.3.0.tar.gz (34.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

asdm-0.3.0-py3-none-any.whl (32.7 kB view details)

Uploaded Python 3

File details

Details for the file asdm-0.3.0.tar.gz.

File metadata

  • Download URL: asdm-0.3.0.tar.gz
  • Upload date:
  • Size: 34.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.3

File hashes

Hashes for asdm-0.3.0.tar.gz
Algorithm Hash digest
SHA256 e3b1186ec294b389e46fd021e47017c3be19baa34b221e455fa996a171d6d22d
MD5 ce8c3649671e6ffcd7b3b5c57a7b1ab7
BLAKE2b-256 1abfeb4efa34637c3441ed02aa87cafbbbc47603e84f77614b08bb54abbb2fad

See more details on using hashes here.

File details

Details for the file asdm-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: asdm-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 32.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.3

File hashes

Hashes for asdm-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cac35c019a974a4d6008445a9713f92ea7c8a14a9c32aec1c3aa958302f1fe9f
MD5 189a84d81dc14313ab369b2a1109a574
BLAKE2b-256 d448608b912cb40b87ff6910a4970f53e753564d3f3706c213fad13b1e6e1566

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page