---
title: "Tutorial 7 - Sanitary Sewer Modeling"
canonical: "https://help.innovyze.com/space/xps/19661408/Tutorial%207%20-%20Sanitary%20Sewer%20Modeling"
format: markdown
---
Models in the application are used to simulate the hydraulics in sanitary and combined sewer systems. Models account for gravity flow in open or closed top conduits, storage in wet wells, pumps, and flow in force mains. Networks may be looped or have multiple outfalls.

Numerous tools are used to develop constant and time series flows and unit rated flows. Daily and weekly variation patterns may be assigned to any flow. Infiltration and wet weather flows are described in [Tutorial 8 - Wet Weather Flows in Sanitary and Combined Systems](https://help-innovyze.atlassian.net/wiki/spaces/xps/pages/19661399). Water quality routing and treatment are described in [Tutorial 9 - Modeling Stormwater Quality Best Management Practices](https://help-innovyze.atlassian.net/wiki/spaces/xps/pages/19661132).

Most sanitary utility managers make use of some form of asset management or GIS software to manage the collection system data. The program has a variety of tools to import such data as background images, GIS layers, or directly as objects in the model. The data used for this exercise has been received from a GIS department and is edited or appended to add additional information. Also, there are some instances where additional information may be needed (for example, conduit shapes, Manning’s n, etc.).

ESRI shape file, MapInfo MID/MIF, Autodesk DWG/DXF files, and georeferenced photographs with extensions of *.ECW, *.SID, *.JPG, *.TIF, *.BMP and others may be added to the models as background images. When shape files are incorporated as background images, the display can be color coded by attribute value.

In Part 1 of this tutorial, you will build a sanitary sewer collection system model by importing data from external databases. Fields in the model will be filled by data from *.dbf, *.shp,and *.xpx files. In Part 2, a Digital Terrain Model (DTM) will be constructed using the manhole (pit) ground elevations.

## Part 1 – Building a Sanitary Sewer Model from External Data

A collection network can be developed in the graphical user interface using a variety of methods. In Part 1, you will learn how to utilize various tools to import GIS and database files to develop a pipe network including dry weather flow data, node data, and conduit data. Global data is added using XPX files.

| **Level** | Novice |
| --- | --- |
| **Objectives** | Introduce the steps required to:<br>- Build a sanitary sewer model using external data
- Load images using Shape files as the background image
- Digitize a network importing all node and conduit data |
| **Time** | 2 hours |
| **Data files** | The model will be developed from data contained in the files listed in Table 1. |


*Table 1 – External data files used to build sanitary sewer model*  
> Macro (inline-media-image)

* *

1. Launch the program:
  1. At the opening dialog, select **New***.*
  2. In Windows Explorer, navigate to the desired folder, and name the file *LMW71*. A file with the default extension (.xp) will be created.
  3. In the **Units** dialog, select **Metric** and then click **OK**.
2. Add the background image:
  1. On the **Layers** Control Panel, check the visible box for **Background Images**. Right-click **Background Images **and select **Add Background Image**.  
> Macro (inline-media-image)
  2. In the dialog, browse for the file *Cadastre.shp*, and then click **Open**. This file is georeferenced so that the width, height, and destination rectangle boxes are read directly from the file and cannot be edited.
  3. Fill in the **ESRI Shape File Attributes** dialog and select **green** color for both field values of **FEATURE_TY**. Click **OK** twice.  
> Macro (inline-media-image)
3. Import the node data from shape file attribute tables.
  1. Go to **File ****> Import/Export Data >** **Import/Export External Databases.**  
> Macro (inline-media-image)
  2. Select **New** to launch the **External Database Wizard** dialog.  
 > Macro (inline-media-image)
  3. Click **Select a File**. In the **Open** dialog, highlight *SanNodes.dbf* and then click **Open**. Click **Next**.> Macro (inline-media-image)
  4. In the **External Database Wizard - Step 2** dialog, select **SanNodes** in the **Tables** field. Click **Next**.> Macro (inline-media-image)
  5. In the **External Database Wizard - Step 3 **dialog, select **Import Data only** and then click **Next**.> Macro (inline-media-image)
  6. In the **External Database Wizard - Step 4 **dialog, select **Create New or Update Existing** from the list. Click **Next**.> Macro (inline-media-image)
  7. In the **External Database Wizard - Step 5 **dialog, fill in the texts as shown in the following. Click **Preview Table Data** to check the data in the table. Click **Next**.> Macro (inline-media-image)
  8. The final steps involve assigning the columns of data in the database to variables in the program. Use the variable selections shown below for the node and link spreadsheets. Highlight one field at a time and select **Set** to get the **Variable Selection: Node Data** screen to show. Choose the XP Variables that describe the Field (for example, **SPILLCREST > Ground Elevation (Spill Crest)**).> Macro (inline-media-image)

> Macro (inline-media-image)
  9. Set the XP Variables for **Ground Elevation**, **Invert**, **Ponding Type**, and **Outfall Flag**. Click **Finish **to exit the **External Database Wizard - Step 6 **dialog.> Macro (inline-media-image)
  10. With **SanNodes** highlighted, click **Import**. A preview table will be displayed. Data may be edited here. After reviewing the data, click **OK**.> Macro (inline-media-image)

> Macro (inline-media-image)
  11. The results of the import are displayed. Click **OK**.> Macro (inline-media-image)
  12. Click **Close** to view imported nodes in the network view.
4. Import Conduit, Pump, and Flow data. The database mappings for the remaining database files are listed in Table 2. For each file, repeat the procedure described in Step 2 for *SanNodes.dbf*. Create a new database connection and follow the steps outlined in the wizard. The figure below shows the layout of the nodes and links of the imported sanitary sewer model.  
> Macro (inline-media-image)
5. Save your file as *LMW72.xp* and close.  
> Macro (inline-media-image)
6. An alternative method to rapidly build a network from shape files:
  1. Reload the file *LMW71.xp* and** Save As ***LMW73.xp*.
  2. On the **Layer **Control Panel, make the nodes and links visible and selectable. Right-click the **Nodes **layer and select **Import From GIS File**.
  3. Next, select *SanNodes.shp* and then click **Open**. In the **Import GIS File** dialog, click **Import**.> Macro (inline-media-image)

> Macro (inline-media-image)
  4. In the **Set Nodes Names From Attribute Data **field, select **NODE_NAME(30 Char) **from the list and then click **OK**. The results of the import are reported.  
> Macro (inline-media-image)

> Macro (inline-media-image)
  5. Right-click the **Links** layer.
  6. Choose **Import From GIS File**. Next, select *SanCond.shp* and then click **Open**.
  7. In the **Import GIS File** dialog, click **Import**.> Macro (inline-media-image)
  8. In the **Link Name** section, check the **Set Links to Attribute Data** radio button and select **LINK_NAME (32 Char)** from the list.
  9. Under **Connectivity Options**, select **User Define** and select **US_NODE (30 Char)** and **DS_NODE (30 Char)**. Click **OK**. The results of the import are reported.  
> Macro (inline-media-image)
7. Import the Nodes’ and Links’ Elevations, Dry Weather Flow Temporal Patterns, and Pump Curves from XPX files.They can be imported by an XPX file which is an efficient method of importing several pieces of data for a number of objects.
  1. On the **File **menu, select **Import/Export Data > ****Import XPX/EPA Data**.
  2. Click **Select** and **Open** the file that is called *Elevations.XPX*.
  3. Click **Import**. Click **OK **on the generic Import Warning Message.  
> Macro (inline-media-image)
  4. Double-click and open the **Node Data** dialog. You will see the **Spill Crest** and **Link Elevation** are imported.
  5. Now, repeat the importing procedure for both the *DWF.xpx* and *PC.xpx* files to import the **Dry Weather Flow Temporal Pattern** and **Pump Curves** to the model.
    **<u>The contents of the DWF.xpx is as follows:</u>**
    <u>**The contents of the Pump Rating Curves XPX file are: **</u>
  6. Now, go to **Configuration > ****Global Data**.
  7. Find **(SH) Temporal Variation **in the left panel and click **Residential DWF **in the right panel.
  8. Click **Edit**.
  9. Review the hourly variation pattern. Click **OK** twice to return to the network view.   
> Macro (inline-media-image)

> Macro (inline-media-image)
  10. Go to **Configuration > ****Global Data**.
  11. Find **(H) Pump Rating Curves **in the left panel and click **FIXPUMP** in the right panel.
  12. Click **Edit**.
  13. Review the pump rating curve. Click **OK** twice to return to the network view.  
> Macro (inline-media-image)
8. Check the Time Control for the Hydraulics Job Control:
  1. Go to **Configuration ****> Job Control > Hydraulics**.
  2. Change to the current date for the start time and three days later for the end time.
9. Define the Outlet control:
  1. Use the **Find **tool** (<Ctrl>+F)** to locate node **88651701**.
  2. Double-click to open the **Node Data** dialog.
  3. Double-click **Outfall **and then click **Type 1, Free Outfall**.   
> Macro (inline-media-image)
  4. Click **Use minimum of Y**<sub>**c**</sub>**_Y**<sub>**n**</sub>. Click **OK** three times to return to the network view.  
> Macro (inline-media-image)
10. The model contains two conduits that have lengths less than the default minimum length (10 m) required for the numerical engine. To avoid warning messages produce during simulation, add a **Configuration Parameter**.
  1. On the **Configuration **menu, select **Configuration Parameters**.
  2. Type **MINLEN=9.0**. Select **Add** and then click **OK. **  
> Macro (inline-media-image)
11. Save your file.
12. Solve the model. Click the** ****Solve **icon > Macro (inline-media-image)

 .

### Questions regarding Importing:  


File extension for the node data table import?                           _____.

File extension for the dry weather flow import?                          _____.

File extension for the Import from GIS file?                                 _____.

### Questions regarding the Pumps:

What is the pump flow rate?                            _____.

What is the pump speed factor?                      _____.

The pump is rated by?                                    _____.


## Part 2 – Building a DTM from Node Ground Elevations

In [Tutorial 2 - Surface Water Hydrology](https://help-innovyze.atlassian.net/wiki/spaces/xps/pages/19661457), you learned how to build a digital terrain model (DTM) by reading a XYZS text file. Part 2 of this tutorial will show you how to build a DTM using imported Node Ground Elevations.

| **Level** | Novice |
| --- | --- |
| ** ****Objectives** | Introduce the steps required to:<br>- Build a DTM using Node Ground Elevations |
| ** ****Time** | 0.5 hours |
| ** ****Data files** | **LMW72.xp** (same as file developed in Part 1) |


1. Build the DTM:
  1. Open the file *LMW72.xp**** ***and** Save As ***LMW74.xp*.
  2. On the **Layers** Control Panel, check the visible box next to **Topography**.
  3. Right-click **DTM Layers** and select **DTM Builder**.  
 > Macro (inline-media-image)
  4. In the **DTM Creator** dialog, click **Read Node Ground Elevations**. Click **Create DTM**.  
> Macro (inline-media-image)
  5. A dialog will open asking for the name of tin file. Type in the name *LMW.xptin* and click **Save.**
2. Adjust the display of the DTM layers:
  1. On the **Layers** Control Panel, right-click the line corresponding to the xptin that was just created.
  2. Select **Properties** from the menu. Click the **Display Properties **tab.
  3. Adjust the display properties to **Show Major Contours **at **2 m **and **Show Minor Contours **at **0.25 m** intervals as indicated in the figure below.
  4. Clear the **Fill Color on Height Range** box.
  5. Select the **Display Legend** option.
  6. Click **OK**.> Macro (inline-media-image)
  7. Right-click the xptin on the **Layer** Control Panel and select **Edit Colors** to open the **DTM Gradient Colors** dialog.
  8. Set the transparency to **Opaque**. Click **OK **twice.> Macro (inline-media-image)
  9. Review the project area in the network view. Note that a Z coordinate is included in the status bar at the bottom. You may clear the **1D Network **layer for a better view of the created DTM. Move the cursor over the network and you will see the Z values for the cursor locations.> Macro (inline-media-image)

### Questions

1. In regards to the DTM used in this exercise, what are the:
  Number of points                              _____
  Minimum elevation                          _____ m
  Maximum elevation                          _____ m
2. On the File menu, select **Properties** and click **Job Statistics**. In the current column what are the number of:  
_____ links
  _____ nodes
  _____ pictures
3. The program can read from ___ different external files to create a DTM.