Modify the digital terrain model for a 2D model


Modifying the elevation of an existing DTM is a common task when modeling a 1d/2d model in XPSWMM to ensure correct flow paths. For more advanced manipulation of the surface, it is important to review the surface after the changes, you’ll need specialized GIS tools outside of XPSWMM for this task.

  • Install QGIS
  • Install Tuflow QGIS plugin
  • Install Profile QGIS plugin

2D Grid

The 2D engine sees the world as cells (or cubes in 3D). It is a fixed grid with rectangle cells defined by the user, which is very similar to how Minecraft models the world. For more details, refer to the Tuflow Manual. The actual surface your 2D model uses can be very different from your DTM, therefore, you’ll need GIS tools to compare your 2D surface with the DTM for models with more complicated terrain.

  • ZC: the center point of the cell, it represents the bottom of the cell
  • ZU/ZV: controls how water moves between cells, you can use breakline to raise the elevation of the sides of the cell to act like fences


There two types of breaklines,

  • Thin breaklines only changes the elevation of the sides of a cell, for example, level walls.
  • Thick breaklines will raise both the sides and the bottom of the cell, for example elevated wide roads

Data files

Data files can be found in the “data” folder,

  • Aerial_Photo
  • grid: topo data and related shapefiles
  • model: XPSWMM model files



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store