### Navigation

- index
- previous |
- SWMM5-EA 0.9.3.0 documentation »

# Example 3: Staged Optimization

Staged detention storage planning example.

This example demonstrates the use of SWMM5-EA in staged-optimization problems. The problem goes like this: In order to mitigate flooding in a drainage network five detention storages are planned (The network and detention storage locations are exactly same as Example 1. The planning horizon in 30 years and planning should be done to be implemented in 3 stages (Stage 0: start of the project, Stage 1: 10 years into the future and Stage 2: 20 years into the future). The design goal is the least cost detention storage with no flooding for the design rainstorm given. It is estimated that the impervious fraction in each watershed will increase by 10% during each 10 year stage. For simplicity it is assumed that all other parameters remain same (e.g. no climate change!) [1].

In staging problems, SWMM5-EA handles swmm input files in a very different way from other applications (e.g. Simple Optimization, Calibration). It duplicates the SWMM input file to copies (where is the number of stages). When the Insert Slots button is pressed (to edit place-holders), this process happens automatically and the place-holder dialog is filled with a compound file containing all these copies. Each swmm input file is separated by an entry similar to

> `;;;;;;;; STAGE 2 ;;;;;;;; NOTE: Do not alter this line in anyway! ;;;;;;;;;;;;;;;;;;;;`

Place Holders in SWMM5 input file. This dialog presents a compound text file containing ( number of stages) SWMM input files. SWMM input files are separated by a special entry: `;;;;;;;; STAGE 2 ;;;;;;;; NOTE: Do not ...`

In the parameters pane, in addition to the usual ones, three new parameters are exposed: The number of stages, size of a stage and the discount rate.

Project parameters used.

Note that it is the responsibility of the user to introduce the time value concept when writing the cost function 1 (). The user can use any of the variables used in the left hand pane of the dialog when writing the equations. In this example, we have used the discount rate and stage size like this. Our cost formula is

The cost function 2 () remains simple. It is interpreted as annual flood cost. The SWMM5-EA system will calculate flood cost at each year using this user-provided formula, bring it to the present value and sums it all to calculate the net present cost of flooding.

However, in this example (similar to Example 1,) we do no consider flood as a real cost but as a penalty.

After 100 generations.

[1] | The SWMM5-EA software allows implementing more complex problems where a number of parameters change. However, for this example we use a simple scenario.

### Navigation

- index
- previous |
- SWMM5-EA 0.9.3.0 documentation »