cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can subscribe to a forum, label or individual post and receive email notifications when someone posts a new topic or reply. Learn more! X

Translate the entire conversation x

The 3 Reservoir Problem with a twist

MarkBuckton
10-Marble

The 3 Reservoir Problem with a twist

I have cobbled together a MC 14 template to solve the classic 3 reservoir hydraulic problem. The problem usually assumes that the head pressure at each reservoir is fixed and so the solve block can handle this with ease. However, in this example I have assumed that one of the reservoirs - denoted as Reservoir A has a falling head characteristic (a hydraulic rating or pump discharge curve). In reality this would be say a node on a pumped water main which is supplying water to the other 2 reservoirs for instance. This is described by the function ZA(QA)vector. As you can see the solve block is having trouble with this arrangement. Does anyone know how to setup the solve block to solve such problems? My ultimate goal is to input all 3 reservoirs but I don't want to run before I can walk.

Regards, Mark
9 REPLIES 9

"...I don't want to run before I can walk".
________________________

The problem might be specific to your version ?
That means your *.XMCD restricts the help from lower versions.

jmG

In version 12 and 11 as requested.



Regards, Mark

1. You haven't defined function darcy within the worksheet (nor referenced it, if it exists in a different worksheet).



2. When you do define it, make sure it caters for zero flow to avoid a possible divide by zero error.



3. Because QA is a vector, QA/|QA| doesn't give what you want it to! Either put a vectorising arrow over it, or, preferably, use sign(QA).



stv

Sorry I forgot to explain:

The Darcy fuction (aka coolebrook-white friction factor) is an external user fuction ChEMath.dll � 2003 Javier Fuentes, so lets assume it works. If you are not confident replace the function and use a constant say f:=0.003 or similar . The problem is not with the Darcy fuction as that has been professionally coded but the use of a vector in a Solve Block. How do I use, in this case, a vector of flows and pressures to arrive at a balance point / solution for the system?

Regards, Mark

You will need to add roughness as an argument to hL.

Personally, I'd use Q|Q| in the definition of hL, rather than Q^2, then you don't need all those Q/|Q| later.

You only need a single value of QA as an initial guess, Given ... Find does the rest.

When you call hL within the Given ... Find block you use fixed values of Reynolds number that have been previously calculated. You should define a Reynolds number function earlier in the worksheet (making sure you use |Q| not just Q in its definition) and call hL with Re(QA,dA) rather than ReA etc.

Currently, your ZA function continues its quadratic behaviour for negative values of QA. Is this what you really want, or should ZA return zero if QA is negative?


stv

I have done what you have suggested, but I did not revise the head loss equation as you suggested because I like to change one thing at a time then I know where to look if it breaks. Note I have kept it simple fixed head at the reservoirs but incorporated as suggested the Reynolds fuction in the solve block, note also however that MathCad now fails to arrive at a solution. Why is this?

Use absolute value of Q in Reynolds number definition or you'll get some negative Reynolds numbers, which won't be too useful!



You don't need a separate definition of Re for A, B and C. Just define a single function and call it with (QA, dA), (QB,dB), (QC, dC) as appropriate.



Because I don't have your darcy function to hand, I tested with darcy replaced by the constant 0.02. With the above changes the solve block works ok. The validity of the results is another matter!



stv

Thank you stv; it seems to work now have the 3 seperate functions for the Reynolds seems to have been the problem.


Regards, Mark

The concept is incorrect on several grounds.
You need the piping configuration for isolating all the flow dependencies: singular losses, linear losses, the datum, the level in tanks, the pump curve, the friction formula, valves ... etc. You have many of them but the setup it not logical in too many pages.
Branching "Tees" have great influence.

A single system was easy solving with the TI-58. For a multiple system, Mathcad should do as easily providing it is dressed conveniently with all calculable influences included.

jmG
Announcements

Top Tags