Tutorial 15: Water Hammer Simulation


This exercise will walk the user through building a water hammer model. The user will learn how to:

  • Edit chamber properties
  • Edit element properties
  • Check the model
  • Run the model
  • Post-process the model
  • Chamber Types: Plenum, Momentum
  • Element Types: Elastic Pipe, Valve, Controller
  • Fluid: Water

Step 1: Examine the system and create plan

  1. The user will be creating a model for a piping system as shown in figure 1.01. The tank will provide the fluid to the elastic pipe when the valve is open and if the valve is closed, there will be pressure waves in the pipe. This is an example model of how to generate a water hammer model.

    Figure 1.01: pipe connection between a tank and a valve

    Figure 1.02: Flow Simulator Model

  2. The tank has constant pressure and temperature; thus, it can be modeled as plenum chamber.
  3. To model a piping system, the user will be making use of elastic tube, valve and controller elements.

Step 2: Building Model

  1. Plan model setup based on what is known about the geometry
  2. Drag and Drop 2 Boundary Plenum chambers
    1. Inlet Plenum Boundary
      1. Ps = 3.42 bar
      2. Tt = 23.3C
    2. Exit Plenum Boundary
      1. Ps = 1 bar
      2. Tt = 23.3C
  3. Drag and Drop elastic pipe under Incompressible Liquid Elements section.
    1. Total Length = 36m
    2. Number of Stations = 20
    3. Diameter = 0.01905 m
    4. Wave Speed = 4000
    5. Roughness = 0.02999 mm
  4. And connect Ball Valve between elastic pipe and plenum chamber
    1. Pipe Diameter = 0.01905 m
    2. Valve Position(%Open) = 100
  5. Define Mission table for the controller (RUN → Analysis Setup → Cycle/Mission)

  6. Drag and Drop Mission BC Controller to control Valve opening/closing through python script
    1. GAUGE Variable is TIME
    2. GAUGE Variable Item Type is Mission
    3. GAUGE Variable Property is TIME
    4. MANIPULATED VAR. LIST Variable is VP
    5. MANIPULATED VAR. LIST Item Type is Valve Element
    6. MANIPULATED VAR. LIST Property is Valve Opening
    7. DEFINE Python Script to control Valve Opening base on TIME

  7. Select Analysis Type
    • Run → Analysis Setup → Water Hammer Simulation
  8. Run Control Parameters
    1. Specify Run Start/Stop Time
    2. Time Stepping (if «Specify Material Properties» is selected as Water Hammer Input, Wave Speed Estimation should be given)
  9. Solver Convergence
    1. Unselect Tol1
    2. Select Tol3 with a value of 0.01

Step 3: Check Model and Run

  1. Select checkmark icon from the top toolbar to check the model for warnings/errors.
    • An error should populate stating that the internal chamber has not been initialized
  2. Select the initialization icon from the toolbar, and pick Start. Accept values once flow solver has converged.
  3. Select run icon from toolbar. Run Flow Simulator.

Step 4: Post-process

Will Be updated Soon. Interim Solution

Figure 5.02: Change in the Exit Pressure of the Elastic Pipe with time