Revert "Replaced status checking for pumps & FCVs"

This reverts commit 3ee30ce019.
This commit is contained in:
Lew Rossman
2020-02-09 17:25:33 -05:00
parent a3537b767a
commit a9ab376aa7
5 changed files with 73 additions and 61 deletions

View File

@@ -7,7 +7,7 @@ Description: updates hydraulic status of network elements
Authors: see AUTHORS
Copyright: see AUTHORS
License: see LICENSE
Last Updated: 02/07/2020
Last Updated: 05/15/2019
******************************************************************************
*/
@@ -141,6 +141,18 @@ int linkstatus(Project *pr)
hyd->LinkStatus[k] = cvstatus(pr, hyd->LinkStatus[k], dh,
hyd->LinkFlow[k]);
}
if (link->Type == PUMP && hyd->LinkStatus[k] >= OPEN &&
hyd->LinkSetting[k] > 0.0)
{
hyd->LinkStatus[k] = pumpstatus(pr, k, -dh);
}
// Check for status changes in non-fixed FCVs
if (link->Type == FCV && hyd->LinkSetting[k] != MISSING)
{
hyd->LinkStatus[k] = fcvstatus(pr, k, status, hyd->NodeHead[n1],
hyd->NodeHead[n2]);
}
// Check for flow into (out of) full (empty) tanks
if (n1 > net->Njuncs || n2 > net->Njuncs)