Page 92 - ExtendSim User Guide
P. 92

66
Tutorial
Removing overflow from the Holding Tank
The Tutorial module showed how to build the Reservoir model. This chapter illustrates some additional modeling techniques to enhance that model:
• RemovingcontentfromaHoldingTankblockifitexceedsaspecifiedlimit • Using the Equation block to replace the functionality of several blocks
• Adjusting delta time (dt) for more accurate simulation results
If you haven’t already done so, it is recommended that you go through the chapters in the Tuto- rial module (starting on page 13) to familiarize yourself with the basic techniques for building models and running simulations.
☞ Example models for comparison to the Overflow model you will build in this chapter are located in the ExtendSim9\Examples\Tutorials\Continuous folder. Reservoir 2 shows a series of blocks that calculate and remove the overflow and Reservoir 3 is the same model using an Equation block to perform the calculations.
Removing overflow from the Holding Tank
The Tutorial chapter “Building a Model” on page 23 assumed that the reservoir had an infinite capacity. In this chapter, the model is modified so that there is a limit on how much water the reservoir can hold and overflow is removed. To do this you need to add model elements to:
• Establish a maximum reservoir capacity
• Comparethecontentsofthereservoirtothemaximumlimit
• Determine if and when the contents exceed the limit
• Calculate the amount to remove if there is any excess
• Remove the excess water
With these changes, the reservoir would behave more like an actual reservoir with a dam where water spills over if it reaches the top.
Setting the maximum capacity
From the \Examples\Tutorials folder, open the model Reservoir 1.
So that you don’t overwrite the original model, give the command File > Save Model As and save the model as “Overflow”.
In the Overflow model, add a Constant block (Value library) at the bottom left of the model.
This block will represent the overflow limit for the reservoir, in this case, 50 inches.
Constant block added to Overflow model
Continuous


































































































   90   91   92   93   94