diff --git a/src/enumstxt.h b/src/enumstxt.h index 339dc40..fdb9311 100755 --- a/src/enumstxt.h +++ b/src/enumstxt.h @@ -7,7 +7,7 @@ Authors: see AUTHORS Copyright: see AUTHORS License: see LICENSE - Last Updated: 11/27/2018 + Last Updated: 06/20/2019 ****************************************************************************** */ @@ -38,7 +38,8 @@ char *StatTxt[] = {t_XHEAD, t_XFCV, t_XPRESSURE, t_FILLING, - t_EMPTYING}; + t_EMPTYING, + t_OVERFLOWING}; char *FormTxt[] = {w_HW, w_DW, diff --git a/src/report.c b/src/report.c index 71a98d1..d9d67bb 100644 --- a/src/report.c +++ b/src/report.c @@ -7,7 +7,7 @@ Authors: see AUTHORS Copyright: see AUTHORS License: see LICENSE - Last Updated: 05/15/2019 + Last Updated: 06/20/2019 ****************************************************************************** */ @@ -370,8 +370,13 @@ void writehydstat(Project *pr, int iter, double relerr) n = net->Tank[i].Node; NodeDemand = hyd->NodeDemand; if (ABS(NodeDemand[n]) < 0.001) newstat = CLOSED; - else if (NodeDemand[n] > 0.0) newstat = FILLING; else if (NodeDemand[n] < 0.0) newstat = EMPTYING; + else if (NodeDemand[n] > 0.0) + { + if (Tank[i].A > 0.0 && ABS(hyd->NodeHead[n] - Tank[i].Hmax) < 0.001) + newstat = OVERFLOWING; + else newstat = FILLING; + } else newstat = hyd->OldStatus[net->Nlinks + i]; if (newstat != hyd->OldStatus[net->Nlinks + i]) { diff --git a/src/text.h b/src/text.h index 9d25813..2ce73da 100755 --- a/src/text.h +++ b/src/text.h @@ -7,7 +7,7 @@ Authors: see AUTHORS Copyright: see AUTHORS License: see LICENSE - Last Updated: 11/27/2018 + Last Updated: 06/20/2019 ****************************************************************************** */ @@ -282,6 +282,7 @@ #define t_XPRESSURE "open but cannot deliver pressure" #define t_FILLING "filling" #define t_EMPTYING "emptying" +#define t_OVERFLOWING "overflowing" #define t_ELEV "Elevation" #define t_DEMAND "Demand" diff --git a/src/types.h b/src/types.h index fe7142e..c07d4aa 100755 --- a/src/types.h +++ b/src/types.h @@ -7,7 +7,7 @@ Authors: see AUTHORS Copyright: see AUTHORS License: see LICENSE - Last Updated: 05/15/2019 + Last Updated: 06/20/2019 ****************************************************************************** */ @@ -200,7 +200,8 @@ typedef enum { XFCV, // FCV cannot supply flow XPRESSURE, // valve cannot supply pressure FILLING, // tank filling - EMPTYING // tank emptying + EMPTYING, // tank emptying + OVERFLOWING // tank overflowing } StatusType; typedef enum {