Code to incorporate entrapped air pocket dynamics into SWMM (AirSWMM2.0)

doi: 10.4121/4fde941d-2f99-44b1-add8-50602957c233.v1
The doi above is for this specific version of this dataset, which is currently the latest. Newer versions may be published in the future. For a link that will always point to the latest version, please use
doi: 10.4121/4fde941d-2f99-44b1-add8-50602957c233
Datacite citation style:
Ferreira, João Paulo; Ferras, David; Covas, Didia; Kapelan, Zoran (2024): Code to incorporate entrapped air pocket dynamics into SWMM (AirSWMM2.0). Version 1. 4TU.ResearchData. software.
Other citation styles (APA, Harvard, MLA, Vancouver, Chicago, IEEE) available at Datacite

This code has the implementation of a novel methodology to locate and quantify entrapped air pockets created during pipe-filling events often found in intermittent water supply systems. A new numerical model capable of simulating the air pocket creation, dragging and entrainment has been proposed, AirSWMM, was implemented as an extension of the Stormwater Management Model (SWMM) with stochasticity of air pocket formation reproduced by simulations with different air entrainment rates. The obtained numerical results show that the proposed model, even though based on a single-phase one-dimensional flow, can accurately locate and approximately quantify the entrapped air pocket volumes.

  • 2024-07-08 first online, published, posted
.c, .h
associated peer-reviewed publication
Air entrapment modelling during pipe filling based on SWMM
  • New modelling paradigm for improved intermittent supply system modelling (grant code SFRH/BD/146709/2019) Fundação da Ciência e Tecnologia (FCT)
TU Delft, Faculty of Civil Engineering and Geosciences, Department of Water Management


To access the source code, use the following command:

git clone