Applies To | |
Product(s): | HAMMER |
Version(s): | 08.11.XX.XX and higher |
Area: | Modeling |
Original Author: | Scott Kampa, Bentley Technical Support Group |
This article will explain how to model dynamic valves (PRV, PSV and FCV) that automatically modulate (throttle to maintain a target) during a transient simulation.
Modulating PRVs became available for a transient simulation starting with HAMMER V8i SELECTseries 4 (08.11.04.XX).
Modulating PSVs and FCVs became available starting with HAMMER CONNECT Edition Update 3 (10.03.02.75).
Control valves, such as pressure reducing valves (PRVs), will throttle (open or close) to control pressure or flow in the system. For example, PRVs adjust valve opening position to meet a target outlet pressure. This happens automatically in a steady state or EPS simulation. In HAMMER V8i SELECTseries 3 and earlier, PRVs always maintained a constant valve position throughout a transient analysis, based on the position in the initial conditions. In many cases this assumption is sufficient, in part because most transient events happen so quickly that these types of valves cannot react quickly, or do not contribute significantly to the transient results that are typically of interest (maximum and minimum HGL). Also, with the very small time scale used in a transient simulation (typically on the order of hundredths of a second), the rate at which such a valve can react is a factor and would need to be known to be able to simulate the dynamic modulation.
However, there are instances where modulation of the valve position may need to be accounted for. There are also cases where valve modulation itself can contribute to transient events.
Starting with HAMMER V8i SELECTseries 4, a new PRV property field was included which enables HAMMER to adjust the valve opening dynamically during a transient analysis. This TechNote will cover the steps used in using the new modulating PRV feature.
Note: While it is possible that other types of control valves can also modulate during a transient simulation, the modulating behavior is currently only included for PRVs in HAMMER V8i SELECTseries 4, 5 and 6, and in the CONNECT Edition.
Note: Although the "Modulate Valve During Transient?" option may display for FCVs and PSVs in versions 10.01.00.72 through 10.03.01.08, the feature currently only works for PRVs. FCV and PSV modulation is planned to be available in late 2020. In the meantime, you can use the workaround mentioned below under "Manual Modulation" and here.
Starting with HAMMER V8i SELECTseries 4, the option "Modulate Valve during Transient?" is available in the PRV properties. If this is set to True, two new properties become active: "Opening Rate Coefficient" and "Closure Rate Coefficient." The units for these properties are percent change of the opening per second per foot of HGL difference between the control valve setting and the calculated pressure at the previous time step ("%/sec/ft" or "%/sec/m", for example).
The values used for the opening and closure rate coefficients are highly valve-specific. The closing and opening rates may be different for any given valve. Values will tend to be lower for larger valves, and could be much higher for direct acting valves than they would be for pilot controlled valves. The values should be calibrated based on the use of high speed pressure loggers in the field. If field data or manufacturer documentation is not available, a reasonable initial estimate for the rate coefficient would be on the order of 0.1 %/s/(ft3/s).
When "Modulate Valve during Transient" is set to True, the PRV will start to open when it senses the downstream pressure dropping below the initial pressure setting. It will start to close when it senses the downstream pressure is greater than the initial setting. These changes in pressure can happen as a result of any transient event in the system, such as a pump shutting down or turning on, a valve closing, etc. The rate at which the PRV opens or closes is dictated by the opening rate coefficient and closure rate coefficient.
The calculation method and formulas are different for PRVs, PSVs and FCVs:
When valve outlet pressure Pr is higher than PRV Pressure Setting Ps:
rc = cr * (Pr -Ps ),
rc is Valve closing rate (%/s)
cr (%/s/(ft H2O)) is closing rate coefficient
Valve relative closure Vc = Vp + rc * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
When valve outlet pressure Pr is lower than PRV Pressure Setting Ps :
ro = co * (Ps –Pr ),
ro is Opening rate (%/s)
co (%/s/(ft H2O)) is the opening rate coefficient
Valve relative Closure Vc = Vp – ro * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
When valve inlet pressure Pr is higher than PSV Pressure Setting Ps:
ro = co * (Pr –Ps),
ro is Opening rate (%/s)
co (%/s/(ft H2O)) is the opening rate coefficient
Valve relative Closure Vc = Vp – ro * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
When valve intlet pressure Pr is lower than PRV Pressure Setting Ps :
rc = cr * (Ps - Pr),
rc is Valve closing rate (%/s)
cr (%/s/(ft H2O)) is closing rate coefficient
Valve relative closure Vc = Vp + rc * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
When valve discharge Qr is higher than FCV Discharge Setting Qs:
rc = cr * (Qr - Qs ),
rc is Valve closing rate (%/s)
cr (%/s/( ft3/s)) is closing rate coefficient
Valve relative closure Vc = Vp + rc * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
When valve discharge Qr is lower than PRV Pressure Setting Qs :
ro = co * (Qs –Qr ),
ro is Opening rate (%/s)
co (%/s/( ft3/s)) is the opening rate coefficient
Valve relative Closure Vc = Vp – ro * DT,
where DT (second) is the calculation time step
Vp (%) is the valve relative closure at last time step.
As an example of how Modulating PRV results can be different for different modeling cases, consider the simple model layout below, which you can download from the link at the bottom of this article:
This example illustrates a valve closure on the downstream side of a PRV. The upstream reservoir is at an elevation of 200 ft, the downstream demands at 100 ft and the PRV pressure setting is 170 ft. In the initial conditions, it is partially closed to meet the setpoint pressure. The traditional, default behavior for the PRV is to not modulate during the transient event ( "Modulate Valve during Transient" set to False). In other words, it will maintain the opening position from the initial conditions, which correlates to a specific discharge coefficient.
The screenshots below show the minimum and maximum hydraulic grade along the profile and the trend graph of flow and hydraulic grade on the downstream side of the PRV, as a result of the downstream valve closing in 10 seconds. Several different variations are compared.
In the profile, the black line is the initial hydraulic grade line and the orange line is the hydraulic grade line at the end of the simulation (the final steady state).
No Modulation
In this case, the "Modulate Valve during transient" option is set to False.
Note how after the valve closes, the PRV's downstream HGL increases (to about 195 ft) due to the change in downstream flow. In the profile's orange line (final steady state HGL), you can see that the reduction in flow caused a reduction in headloss through the PRV since it stayed in a fixed position, yielding a downstream HGL higher than the PRV's hydraulic grade setting. Normally a PRV would react to the change in hydraulics and start to close to maintain the 170 ft. setpoint. Since the modulation option was not enabled, this does not happen.
Modulating - Coefficient of 0.1
In this case, the "Modulate Valve during transient" option is set to True and both the open and closure rate coefficients are set to 0.1 %/sec/ft
Note how after the valve closes, the HGL eventually settles back down to the setpoint of 170 ft, due to the modulation of the PRV. In profile you can see how the final steady state HGL (orange line) on the downstream side of the PRV is matching the initial HGL (black line) which is the setpoint of 170 ft. With the rate coefficient of 0.1, the modulation does not appear to cause any transient effects, either. (look at the max HGL red line in profile above the PRV)
Modulating - Coefficient of 0.5
In this case, the "Modulate Valve during transient" option is set to True and both the open and closure rate coefficients are set to a higher value: 0.5 %/sec/ft
As with the previous case with the modulating option enabled, the final steady state HGL (orange line on profile) settles down to the setpoint pressure of 170 ft due to the modulation. However in this case, the modulation may have occurred too quickly, resulting in a significant change in momentum and subsequent surge. This can be seen in the red max HGL line in the profile, above the PRV. The upstream side of the PRV experiences an "upsurge", and the downstream side experiences a "downsurge" (see drop in HGL in the graph).
The Opening Rate Coefficient and Closure Rate Coefficient are not the only variables that can impact the results. The reaction of the Modulating PRV also depends on the minor loss or discharge coefficient entered for the PRV, as well as the valve type. For instance, by changing the Valve Type from "Globe" to "Butterfly," the model results will be different for the same rate coefficient value, since different valve types will see a difference in flow based on the opening of the valve. You can see the calculated relative closure in the PRV properties in the initial conditions.
You can view results of a modulating valve by looking at a graph of hydraulic grade or pressure in the Time History tab of the Transient Results Viewer. For example if the pipe downstream of the PRV is P-4, then you would graph "P-4:PRV".
You can also view the relative closure of the valve in the Extended Node Data tab of the Transient Results Viewer.
For older versions of HAMMER where valves may not be included in the Extended Node Data, you can view the percent closure for the valve over time in a special output file stored in the Windows temporary folder. The default location is: C:\Users\<Username>\AppData\Local\Temp\Bentley\HAMMER\PRVCLOSURE.TXT You can also try typing the following into the address bar of File Explorer: %temp%\Bentley\HAMMER\PRVCLOSURE.TXT
Note: As of version 10.03.05.05, if you look at the relative closure of a PRV in the Extended Node Data tab, the results may display incorrectly and 0% relative closure. The reference for this is 812024. This will be resolved in a future release of HAMMER.
If you set "Modulate Valve during Transient" of False, or if you're using an older version of HAMMER that does not have this feature, it is still possible to adjust valve opening during a transient run by changing the default value for "Operating Rule" from Fixed to an Operational (Transient Valve) pattern created in the Patterns dialog. In these patterns, the relative closure is a function of time (See HAMMER Help topic "Pattern Manager" for more information). Note that a PRV with an operating rule will not dynamically throttle. In other words, if the transient conditions causes a change in pressure downstream of the PRV, it will not automatically throttle (i.e., change its headloss) accordingly. See the "background" above for more information on this.
If you use an Operating Rule to change the valve's position over time, first note the initial calculated relative closure in the PRV properties and use that for the start of your operating rule, so as not to cause an initial surge. If you have difficulties with an operating rule on the PRV itself, consider using a throttle control valve (TCV). For more information on this, please see the articles in the "See Also" section below, "Modeling Existing valves as throttle control valves in HAMMER".
You may have a situation where you want to simulate the PSV/PRV pressure setting or FCV flow setting changing during the transient simulation. For example as a reaction to a pump turning off, a PSV may change its target pressure setting.
It is not currently possible to change the pressure setting of a PSV during a transient simulation. HAMMER will always use the initial pair of flow and headloss from the initial conditions to establish the starting position of the valve. If the Modulation option is selected, it will monitor the pressure as it changes during the transient simulation, and allow the PSV to automatically change positions to meet the initial pressure setting, based on the reaction rate coefficients that you must enter.
With the modulation feature, it always uses the initial pressure setting of the PSV, and you cannot have it change that target value during the transient simulation. Generally speaking HAMMER assumes that changes are happening so quickly during a transient, that things like the pressure setting would not happen (and if it did, the reaction time would be a factor that would need to be accounted for, hence the coefficients required for the modulation feature.) Consider if you actually have a PSV in the real system that would react quickly enough to change its setting in a matter of seconds after the transient event.
If you do need to simulate the change in pressure setting during the transient simulation, this is possible using the TCV element instead of the PSV. You would first compute two steady state simulations using the PSV element, for the two different pressure settings (using the initial pressure setting field). First, run a steady state with the model set up to simulate the desired initial positions (pumps and the PSV setting). Then, run a second steady state with the model set up to represent what will happen at the end of the transient simulation (pump status, new PSV setting, etc) Each time, observe the calculated discharge coefficient in the "Results" section of the properties - these represent the valve position that you are trying to transition the valve between during the transient simulation. Next, morph the PSV instead a TCV by choosing the TCV layout tool and clicking on top of the PSV. You would then need to configure the TCV's user defined valve characteristics curve and operating rule, to transition between the two different discharge coefficients (thereby producing the equivalent of the desired pressure setting change).
This is an advanced technique that requires additional understanding and time to set up, so it is advised that you consider other simpler and conservative assumptions. For example you may want to use a "worst case" design of assuming one pressure setting or the other as being constant, and then try two different transient simulations to see which one produces the worst-case results.
See more: Converting a PRV PSV or FCV to a Throttle Control Valve (TCV) in HAMMER
The below model file corresponds with the example given above, comparing the results between not using the modulation option, and several different variations of using the modulation option.
NOTE: you must be logged in first to download this file. It is saved in V8i SELECTseries 6 format and cannot be opened in earlier versions of HAMMER.
Modeling existing valves as Throttle Control Valves in HAMMER
For additional information on modulating valves in general, please see the following paper:
"Dynamic Modeling of Pressure Reducing Valves" by Simon L. Prescott and Bogumil Ulanicki (Journal of Hydraulic Engineering, October 2003)