We're currently working on developing an MSX model for Chlorine Decay that can account for wall decay as a factor of Biofilm growth (thus removing the need to specify wall decay for specific pipes throughout the network).
Unfortunately the equation for this relies on the mass transfer coefficient, which is dependent on the type of flow, as explained here: https://docs.bentley.com/LiveContent/web/Bentley%20WaterGEMS%20SS6-v1/en/GUID-D7D70292-50F6-4066-A30E-3B98BBB2BF7B.html.
This is built into the WaterGEMS standard pipe wall reaction calculations, however I need to know whether we can reference this coefficient in MSX, does anyone know whether this is possible? My understanding is that EPANET is capable of this so I assume WaterGEMS is capable as well, I just don’t know how.
For anyone wondering, the equations for Bulk decay are very simple. Below is a copy of what we use currently (no wall decay):
The Wall Decay equations are derived as follows (A&B are constants to be determined by trial and error, kw is what we need from WaterGEMS)
It seems that this is possible to do with MSX using the "TERMS" feature.
Terms can be defined to make writing the various water quality equations easier, by breaking equations up into manageable pieces.
One of the benefits of this feature is that one is able to use various pre-defined variables such as D for pipe diameter, Q for flow and Re for Reynolds number.
The MSX user guide provides the following example for calculating a mass transfer coefficient.
You can then use this value Kf directly in your reaction formulae.
I'm not sure if the example above is directly portable to your case (i.e., without alteration), however, you should be able to do what you need. I encourage you to grab a copy of the EPANET MSX user manual (v1.1) if you don't already have it. WaterGEMS is running a version of MSX that is pretty close to the original US EPA version and thus the vast majority of the help content there should be directly applicable to WaterGEMS also.
I hope this helps.
Ryan, what kind of real world system are you dealing with? For pretty much any water distribution system, you never get into laminar flow. Plus with bends, partly open valves, crosses, tee, etc., you may still be in turbulent flow at low Reynolds numbers.
Bulk reaction rates are usually higher than wall reactions and if wall reactions are that high, it may be that. pipes are very rough and turbulent.
And there is so much uncertainty in wall reaction rates to start with.
What is the practical use case where this really matters?
We're attempting to model Chlorine Decay for the water reticulation network of a town of over 50,000 people and 750 km of water mains.
Certainly, when chlorine residuals and dissolved organic compounds are high Bulk decay far outstrips wall decay. But when the water reaches the outer parts of the system, where the flows overnight are negligible (laminar) and the chlorine residual is below 0.5mg/L Biofilm growth starts to occur.
This Biofilm growth consumes and lowers chlorine, which can lead to more biofilm growth, which leads to faster consumption of chlorine and so forth.
These outer areas with low water flows, low chlorine and biofilm growth are our highest risk areas. We would like to be able to be able to account for that biofilm growth in the Chlorine decay model to provide indicative results that are at least somewhat reasonably reliable.
It would also be great if pipe material and age were terms that could also be referenced in MSX, but you're right about the uncertainty in wall reaction rates for these variables so for the moment our primary concern is Biofilms.
A good article outlining a similar process to what we're attempting can be found here: https://watersource.awa.asn.au/business/assets-and-operations/cost-effective-chlorination-strategies-for-drinking-water/