Discrete Event Simulation - DES - is a powerful technique for tackling bottlenecks and performance issues in systems with queues. By building simplified models of real-world pathways - incorporating realistic variability and resource constraints - it becomes possible to ask what-if questions of your system in a safe environment.
Being able to explore a pathway in this way can help with
- identifying and resolving bottlenecks
- answering questions about the number of resources - such as nurses, rooms, scanners - required at different parts of the pathway to meet demand or tackle an existing backlog within a certain timeframe
- exploring the impact of changes to demand - will your system cope as demand increases or the profile of demand changes?
- optimizing existing resources to find the best possible perfomance without increasing the level of resource available
- understanding how delays in one part of the pathway can impact other parts
- exploring the impact of rota changes or shift pattern alterations
- stress-testing a system to explore how it will cope with a bad day, week, month or year as well as a good one
- providing data-driven support to business cases for investment
- exploring and quantifying the potential return on investment (ROI) for additional equipment or resources
Software
Discrete Event Simulation has historically been tackled with proprietary/paid software soluations. While powerful, there can be limitations to the ability to share models between different organisations if they have invested in a different software on the market, among other reasons.
However, a range of Free and Open Source (FOSS) alternatives exist in Python, R and Julia, allowing simulations to be written in code. Code allows for extreme flexibility in the writing of your models, and also ensures that
Some non-code based free options also exist.
A discrete event process oriented simulation framework (formerly SimJulia) written in Julia inspired by the Python library SimPy. It is helpful for building simulations of pathways and services, allowing 'what-if' questions to be tested.
While it is technically possible to create a discrete event simulation in Excel, it is strongly recommended to not go down this path due to serious limitations with this approach.
Training
DES RAP Book is an open resource and website for building discrete-event simulation (DES) models within a reproducible analytical pipeline (RAP), supporting the healthcare simulation community. DES models are often used for building simulations of pathways and services, allowing 'what-if' questions to be tested. The resource demonstrates practical, code-based workflows and tools to help researchers and practitioners develop, validate, and share DES models in Python (SimPy) and R (simmer), ensuring models are reproducible.
This is a collection of slides, session recordings, code examples, exercises, exercise solutions and solution videos from the discrete event simulation (DES) module of the Health Service Modelling Associates Programme, covering 9 hours of content. It teaches discrete event simulation with the Python SimPy package, assuming no prior knowledge of the package or DES concepts. DES is helpful for building simulations of pathways and services, allowing 'what-if' questions to be tested.
The Discrete Event Simulation (DES) playground is an interactive web application designed to teach the fundamental concepts of DES to absolute beginners. Used to support a range of training sessions, it can also be used as a standalone tool to introduce yourself to why DES is useful, building up from a very simple to a more complex model and allowing you to explore the impact of changing a range of parameters. DES is used for building simulations of pathways and services, allowing 'what-if' questions to be tested.
The Little Book of Discrete Event Simulation (DES) is a free eBook written to accompany the DES module of the Health Service Modelling Associates (HSMA) programme. DES is a technique used for building simulations of pathways and services, allowing 'what-if' questions to be tested. The book takes you from being a complete beginner in DES through to creating complex models with a web interface. This Python resource primarily focusses on the SimPy package, also touching on Streamlit and various supporting packages.
DES projects
Below are some projects making use of DES from across the health service.
Two equivalent repositories implementing a stroke capacity planning model - one using Python (SimPy) and one using R (simmer).