Control rules

51 views
Skip to first unread message

Elizabeth

unread,
Apr 18, 2012, 9:13:40 PM4/18/12
to Epanet and Development
Hi

I would apreciatte some help to do control rules to turn on pumps one
by one in a system. Thanks

Lucas Vasconcelos

unread,
Jul 16, 2012, 8:19:34 AM7/16/12
to epa...@googlegroups.com
Pump OPEN turns on the pump. CLOSED turns it off.

This the syntax for the control based rules:

RULE (name)
IF (object) (object name) (object characteristic) (>, < OR =) (value, you can't use an other object's characteristic)
AND (optional, everything again)
THEN (object) (object characteristic) IS (value, you can't an use other object's characteristic)
AND (optional, everything again)
PRIORITY (higher imposes over lower)

Here are a couple working rules from an old model...

RULE BOOSTERNIVEIS
IF NODE RESrepublica PRESSURE < 1.5
THEN PUMP BOOSTER1 STATUS IS OPEN
PRIORITY 1

RULE BOOSTERNIVEIS2
IF NODE RESrepublica PRESSURE > 2.99
THEN PUMP BOOSTER1 STATUS IS CLOSED
PRIORITY 1

Just some more notes:
-In the manual it says priority is optional, but I just can't make rules work without them...
-If you forget to close the pump and the tank closes, the pump will close either way and consume no energy as the flow is 0, but epanet's medium efficiency seems to be calculated as (summation of efficiency in this moment)/(total time), and in these moments the efficiency will be 0%, deeply masking your efficiency results.


Hope it helps!
Message has been deleted

Lucas Vasconcelos

unread,
Jul 16, 2012, 12:24:46 PM7/16/12
to epa...@googlegroups.com
I forgot something!!

You can also use ELSE! It is quite useful to handle opening and closing pumps in a single rule!

RULE (name)
IF (object) (object name) (object characteristic) (>, < OR =) (value, you can't use an other object's characteristic)
AND (optional, everything again)
THEN (object) (object characteristic) IS (value, you can't an use other object's characteristic)
AND (optional, everything again)
ELSE (object) (object name) (object characteristic) (>, < OR =) (value, you can't use an other object's characteristic)
AND (everything again)
PRIORITY (higher imposes over lower)

For instance,

RULE CONTROLMYPUMP
IF NODE MYTANK PRESSURE < 1
AND NODE MYOTHERTANK PRESSURE < 1
AND NODE MYTANK PRESSURE < 2.99
AND NODE MYOTHERTANK PRESSURE < 2.99
THEN PUMP MYPUMP STATUS IS OPEN
ELSE PUMP MYPUMP STATUS IS CLOSED
PRIORITY 1

This will turn on your pump whenever the level in a tank (mytank or myothertank) is between 1 and 2.99. Remember that no matter what is the decimal marker you use, epanet only uses dot.
Reply all
Reply to author
Forward
0 new messages