Next Article in Journal
Towards Agricultural Water Management Decisions in the Context of WELF Nexus
Previous Article in Journal
How to Improve the Performance Prediction of a Pump as Turbine by Considering the Slip Phenomenon
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Proceeding Paper

A Derivative Free Non-Linear Programming Method for the Optimal Setting of PATs to Be Used in a Hybrid Genetic Algorithm: A Preliminary Work †

1
Department of Civil, Architectural and Environmental Engineering, University of Naples Federico II, 80125 Naples, Italy
2
Department of Engineering, University of Naples Parthenope, Centro Direzionale di Napoli, 80143 Naples, Italy
*
Author to whom correspondence should be addressed.
Presented at the 3rd EWaS International Conference on “Insights on the Water-Energy-Food Nexus”, Lefkada Island, Greece, 27–30 June 2018.
Proceedings 2018, 2(11), 684; https://doi.org/10.3390/proceedings2110684
Published: 31 July 2018
(This article belongs to the Proceedings of EWaS3 2018)

Abstract

:
In recent years, recovering energy while managing excessive pressure in water distribution networks (WDNs) has gradually taken hold through the use of Pumps as Turbines (PATs). Therefore, algorithms commonly used for the optimizations of WDNs require modifications to incorporate these devices. Within this study, an intermediate step toward a new Hybrid Genetic Algorithm (HGA) for the optimal placement and setting of PATs within WDNs is proposed. The described methodology is based on a non-linear optimization algorithm, the Powell Direction Set (PDS) method. For each WDN configuration with PATs, a non-linear univariate function, namely the energy production subjected to pressure and technical constraints, is maximized by the PDS method. The promising capabilities of the algorithm are demonstrated with a case study.

1. Introduction

Water Distribution Networks (WDNs) are commonly considered low efficiency systems due to the high energy required to deliver water to users. In many countries, they represent one of the main cause of energy consumption. In the UK it is estimated to be the fourth most consuming activity [1], while in the US operation and maintenance costs are of about 4 billion dollars per year [2]. A large amount of energy is lost through pumping systems because of water leakages occurring within WDNs. Leakages may cause inefficient energy distribution through the network, wasting energy otherwise available for pumping water, and they may also affect water quality by allowing the introduction of pathogens during low pressure conditions. As a consequence, leakages reduction techniques have attracted the interest of many researchers and practitioners. In the literature, several works have been devoted to leakage reduction through Pressure Management (PM) techniques based on the optimal location of pressure reducing devices [3,4], such as Pressure Reducing Valves (PRV). The use of these devices revealed to be effective, however, in this way, the excess of energy through the WDN is inevitably wasted.
In recent years, the concept of generating energy by exploiting the pressure excesses within WDNs has gradually taken hold. To reduce the excess of pressure and, at the same time, transform the dissipated energy into readily available electric energy, several researches have recently focused their attention on the use of turbines or pumps working as turbines (PATs) as an alternative to PRVs. In particular, PATs have become very attractive because of their lower costs and large scale production.
As shown in [5], few investigations have faced the problem of the optimal location of hydropower devices within WDNs. Indeed, the optimal placement of PATs within WDNs is a complex problem. Its complexity is strictly related to the WDN configuration. Moreover, placing a PAT within a pipe of a WDN characterized by several loops imply the insurgence of a concentrated head loss that can significantly influence the flow rate distribution as well as the available power. In addition, the governing equations of water motion are non-linear, and the number of decision variables involved in the optimization problem can be very large depending on the WDN size.
The afore mentioned problem is usually tackled by means of optimization techniques. In [6], to optimize either pressure reduction or power output potential, a Genetic Algorithm (GA) was used to find the optimal location of a fixed number of turbines, with two different objective functions. in [7], a mixed-integer optimization algorithm was used to perform a two-step optimization: in the first step, under steady average conditions, the optimal location of a fixed number of turbines was found by maximizing the power production, while, in the second step, the turbines were regulated according to the daily demand. Moreover, the governing equations were written as equality constraints of the optimization problem. However, in both [6,7], turbines were simulated as simple head losses. Conversely, in [8], affinity equations were used to simulate the behavior of real turbines within the WDN. The simulated annealing algorithm was used to return the best location of a fixed number of turbines, and the energy production was optimized for a real water network in Lausanne (Switzerland) [8]. In [8] the turbine size in each branch was assigned, while the presence of the turbine was a result of the optimization procedure. The produced power was then computed with reference to the yearly variability of the monthly-averaged daily pattern. In [5], to maximize the power output and reduce leakages, a mixed-integer non-linear programming algorithm was employed to find optimal location, setting, and number of PATs to be installed within a WDN. However, in this last work, the PATs were modeled as a concentrated head loss, and no affinity laws were employed.
The main concept of the present work lies on the following assumption: the optimal setting of a PAT within a WDN can be treated as Deterministic Polynomial Time Problem (P), while the problem of positioning, directing, and selecting the PAT can be treated as a Deterministic Non-Polynomial Hard Problem (NP-Hard). Based on this assumption, a Hybrid GA can be developed. In particular, the GA is assigned the task of finding the best number, position, direction, and type of PAT, while an inner non-linear programming algorithm is demanded to determine the electric regulated PAT optimal setting, in terms of rotational speed.
Therefore, we propose a new method for the optimal setting of variable speed PATs for assigned number, position, direction, and type. This goal is accomplished by means of a derivative free non-linear programming method, the Powell Direction Set (PDS) algorithm [9]. Epanet 2.0 DLLs [10] are used as external solver.

2. Methods

In this section, the optimization method and the objective function are described. The optimization algorithm, based on the PDS method, has several advantages over the classical non-linear programming algorithms: (i) it is derivative free, therefore continuity of the function and of its first derivative is not required; (ii) it does not require the function to be convex as it only requires the objective function to be univariate (i.e., the function must fulfill the condition of having just one maximum or minimum); (iii) it has quadratic convergence; (iv) constraints can be treated as penalty functions; (v) it is not too sensitive to noisy functions (i.e., it is able to find the optimal point even though the function may exhibit several small local spikes).

2.1. The External Hydraulic Solver

Hydraulic simulations were performed using an Extended Period Simulation (EPS) approach. To solve the WDN at the k-th time interval of the day, EPANET 2.0 DLLs [10] were used within the code. In particular PATs were modeled using the General Purpose Valve (GPV) option, thus defining the head loss curve into the input file for each setting of the electric regulated PAT, represented by relative speed Vj, namely the ratio between the setting speed Nj (in rpm) and the characteristic speed Nc,j of the j-th PAT.

2.2. The Powell Direction Set method

The PDS works on the basic principle that to find a minimum/maximum of a n-dimensional function, n-one dimensional minimizations can be executed along n directions [9]. The recursive algorithm works as follows:
  • initialize a set of directions u i = e i (where e i is the unitary vector basis of the n dimensional space) and select a starting point P 0 ;
  • for i = 1 n move P i 1 to a minimum along the direction u i and set P i = P i 1 ;
  • for i = 1 n 1 set u i = u i + 1 ;
  • set u n = P n P 0 ;
  • move P n to the minimum along the u n direction then set P 0 equal to this new point;
  • repeat from step 2 until the convergence criterion is satisfied.
The above described procedure tends to create direction that are linearly dependent. To avoid this, the technique of discarding the direction of largest decrease [11] was employed here.
The line minimization technique employed are the Golden Section Search Method [12] (used to find the interval where the minimum lies) and the Brent method [9] to find the minimum of the function.

2.3. The Objective Function

To use the algorithm described in Section 2.2, a univariate objective function is required. Even though the PSD method does not account for the presence of constraints, this can be easily overcome by adding to the objective function a penalty function accounting for the presence of unfeasible regions. In this work, we propose the following objective function:
f o ( V ) = k = 1 N k P k V f p , k V
where V is the vector (with dimension equal to the number of PATs) of the PAT relative speed (ratio between the speed and the characteristic speed); Nk is the number of time intervals in which the day has been divided; P k V is the power produced by the PATs during the k-th time interval; f p , k V is the penalty function value at the k-th time interval.

2.3.1. Power Estimation

The power produced during the k-th time interval is equal to
P k V = j = 1 N P A T η V j Q V j Δ H V j
where Vj is the relative speed of the j-th PAT; η V j is the efficiency of the j-th PAT; Q V j is the discharge flowing through the j-th PAT; Δ H V j is the head loss a-th the j-th PAT.
In particular, the head loss curve is estimated at the characteristic speed with the method proposed in [13].
η c Q c η t b = 4 10 3 Q c Q t b 3 1.386 Q c Q t b 2 0.390 Q c Q t b 1 . 0283 Q c Q t b 3 0.5468 Q c Q t b 2 + 0.5314 Q c Q t b
while, for the different relative speeds, the affinity law proposed in [14] is employed
η V j = 1 1 η c Q c V j 0.1
In Equations (2) and (3), Qc represents the discharge at the characteristic speed; Qtb and ηtb are the discharge and the efficiency at the Best Efficiency Point (BEP) of the pump in inverse mode, and are computed from the BEP of the Pump by means of the formula proposed in [15].
The head loss curve at the PAT is computed using the affinity law proposed in [16]
Δ H V j H t b = 1.0283 Q V j Q t b 2 0.5468 Q V j Q t b + 0.5314
In Equation (5), the discharge at the relative speed Vj is computed by the classical linear affinity law Q V j = Q c V j , while Htb, the jump at the best efficiency point, is evaluated with the formula proposed by Yang et al. (2012).
To simulate the bypass of the PAT, the setting Vj = 0 is allowed. When this occurs, Equation (5) is modified by substituting Q 0 = Q c and setting Δ H 0 = 0 . In this way, any flow rate can by conveyed without concentrated head loss, as no PAT was present.

2.3.2. Penalty Function

To deal with the problem constraints, the following penalty function is proposed
f p , k V = j N p a t P Q , k Q j + P η , k η j + P V , k V j + P Δ H , k V j + P H min , k V j
where
P Q , k Q j = 0 ; Q j 0 α Q V j Q j 2 ; Q j < 0
is a penalty function activated when the PAT is oriented opposite to the flow direction;
P η , k η j = 0 ; η j 0 α η V j η j 2 ; η j < 0
is a penalty used to discard the settings where Equations (3) or (4) return negative values;
P V , k V j = 0 ;       V min V j 1 α V V j 2 ;   V j , V min 1 ,
is a penalty function that allows the PDS method to choose solutions within the feasible region of settings, while Vmin is the minimum relative speed at which the PAT can operate, specified in Section 3;
P Δ H , k Δ H j = 0 ; Δ H 0 α Δ H V j Δ H j 2 ; Δ H > 0
is a penalty function used to penalize the settings Vj not compatible with the discharge flowing through the pipes, because the external hydraulic solver (EPANET 2.0) gives unphysical results with those settings (i.e., PATs act like pumps to balance the equations of motion);
P H min , k H i = i N d α H V j min 0 ,   H i H i , min 2
is the penalty function related to the violation of the minimum head a the i-th demand node of the network, where Hi is the head at the i-th demand node, Hi,min is the minimum head required to fully deliver the user demand, and Nd is the number of demand nodes within the network.
In Equations (7)–(11) the coefficients α Q , α η , α V , α Δ H and α H are penalty coefficients. In the present work, the following values were considered: α Q = α η = α Δ H = 10 6 , α V = 10 12 and α H = 10 4 .

3. Application of the Proposed Methodology

In this section, the algorithm described in Section 2 is applied to a case study, and the results are discussed.

3.1. The Case Study

The case study is a WDN with a simple layout (Figure 1). Nodes and pipes characteristics are reported in Table 1.
Fictitious nodes and pipes have been inserted in the middle of each pipe to locate the PAT. The daily demand coefficient pattern is reported in Table 2. The PAT considered in this work is the horizontal axis PAT described in [13] with Vmin = 0.103 (corresponding to 300 RPM [13]).The maximum discharge circulating within the WDN during the day is 68 l/s, while, in other pipes, the flow is much lower.
Even though the case study is simple, it becomes handy when verifying the capabilities of the algorithm to choose the best rotational speed of the PAT, and to simulate the bypass of the PAT when its use is not recommended.

3.2. Application and Results

The algorithm (Section 2) was applied to the previously described case study for all the possible positions and directions of the single PAT considered. For the sake of brevity and clarity, we selected only the three most relevant scenarios to discuss. By inspection of Figure 1a and Table 1, it is evident that the best location to install a PAT in the pipe from node 1.1 to node 1.2. As a matter of fact, the application of the algorithm to this case returned a solution where the total energy produced is of about 53.97 kWh (Table 2). Conversely, installing the PAT on the same branch but in the opposite direction, the algorithm returned a null setting for each hour of the day (therefore, the PAT was bypassed). By Installing the PAT from node 2.1 to node 2.2, the energy produced during the day was of about 0.665 kWh (Table 2). By installing the PAT in the remaining pipes of the network (in both directions), the algorithm always returned a null setting for every hour of the day. Finally, the PDS was tested with two PATs, and, as expected, the only combination returning settings different from 0 was with PATs installed from node 1.1 to 1.2 and 2.1 to 2.2, with a produced energy of about 54.09 kWh. It is worth noticing that this last outcome is not the simple sum of the energy computed in Scenarios 1 and 2, since the presence of two PATs modifies the flow distribution. In particular, the settings V of the valve from 2.1 to 2.2 are different from those of Scenario 2. Adding a third valve returned null setting in all positions. However, the energy produced by adding an additional PAT in Scenario 1, from 2.1 to 2.2, does not produce more energy. Therefore, the best solution is achieved with only one PAT from node 1.1 to node 1.2.

4. Conclusions

A non-linear programming algorithm for the optimal setting of a PAT was presented. The results showed that the proposed method is able to maximize the energy produced by the PATs installed within a WDN, given their direction, position, and type. In addition, the proposed algorithm was also able to simulate bypass when the PAT position and/or direction was inadequate. The results are promising and the proposed algorithm represents a first step toward the construction of a complete Hybrid Genetic Algorithm able to give back the optimal number, position, direction, type, and setting of PATs to install within a Water Distribution Network to maximize energy production and minimize leakages.

Author Contributions

L.C. conceived the method, developed the numerical code, and performed the computations; A.D., L.C. and D.P. wrote the paper.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Ainger, C.; Butler, D.; Caffor, I.; Crawford-Brown, D.; Helm, D.; Stephenson, T. A Low Carbon Water Industry in 2050; Technical Report; UK Environment Agency: Bristol, UK, 2009. [Google Scholar]
  2. Zilberman, D.; Sproul, T.; Rajagopal, D.; Sexton, S.; Hellegers, P. Rising energy prices and the economics of water in agriculture. Water Policy 2008, 10, 11–21. [Google Scholar] [CrossRef]
  3. Covelli, C.; Cimorelli, L.; Cozzolino, L.; Della Morte, R.; Pianese, D. Reduction in water losses in water distribution systems using pressure reduction valves. Water Sci. Technol. Water Supply 2016, 16, 1033–1045. [Google Scholar] [CrossRef]
  4. Covelli, C.; Cozzolino, L.; Cimorelli, L.; Della Morte, R.; Pianese, D. Optimal location and setting of PRVs in WDS for leakage minimization. Water Resour. Manag. 2016, 30, 1803–1817. [Google Scholar] [CrossRef]
  5. Fecarotta, O.; McNabola, A. Optimal Location of Pump as Turbines (PATs) in Water Distribution Networks to Recover Energy and Reduce Leakage. Water Resour. Manag. 2017, 31, 5043–5059. [Google Scholar] [CrossRef]
  6. Giugni, M.; Fontana, N.; Ranucci, A. Optimal Location of PRVs and Turbines in Water Distribution Systems. J. Water Resour. Plan. Manag. 2014, 140, 06014004. [Google Scholar] [CrossRef]
  7. Corcoran, L.; McNabola, A.; Coughlan, P. Optimization of water distribution networks for combined hydropower energy recovery and leakage reduction. J. Water Resour. Plan. Manag. 2015, 142, 04015045. [Google Scholar] [CrossRef]
  8. Samora, I.; Franca, M.J.; Schleiss, A.J.; Ramos, H.M. Simulated annealing in optimization of energy production in a water supply network. Water Resour. Manag. 2016, 30, 1533–1547. [Google Scholar] [CrossRef]
  9. Brent, R.P. Algorithms for Minimization without Derivatives; Prentice-Hall: Englewood Cliffs, NJ, USA, 1973. [Google Scholar]
  10. Rossman, L.A. EPANET 2 Users’ Manual; U.S. Environmental Protection Agency: Cincinnati, OH, USA, 2000. [Google Scholar]
  11. Press, W.H.; Teukolsky, S.A.; Vetterling, W.T.; Flannery, B.P. Numerical Recipes in Fortran 90; Cambridge University Press: New York, NY, USA, 1996; Volume 2, pp. 402–408. [Google Scholar]
  12. Kiefer, J. Sequential minimax search for a maximum. Proc. Am. Math. Soc. 1953, 4, 502–506. [Google Scholar] [CrossRef]
  13. Pugliese, F.; De Paola, F.; Fontana, N.; Giugni, M.; Marini, G. Experimental characterization of two pumps as turbines for hydropower generation. Renew. Energy 2016, 99, 180–187. [Google Scholar] [CrossRef]
  14. Sârbu, I.; Borza, I. Energetic optimization of water pumping in distribution systems. Period. Polytech. Ser. Mech. Eng. 1998, 42, 141–152. [Google Scholar]
  15. Yang, S.S.; Derakhashan, S.; Kong, F.Y. Theoretical, numerical and experimental prediction of pump as turbine. Renew. Energy 2012, 48, 507–513. [Google Scholar] [CrossRef]
  16. Derakhshan, S.; Nourbakhsh, A. Experimental study of characteristic curves of centrifugal pumps working as turbines in different specific speeds. Exp. Therm. Fluid Sci. 2008, 32, 800–807. [Google Scholar] [CrossRef]
Figure 1. (a) Network layout (EPANET 2.0). (b) Daily demand coefficients DCk pattern.
Figure 1. (a) Network layout (EPANET 2.0). (b) Daily demand coefficients DCk pattern.
Proceedings 02 00684 g001
Table 1. Nodes and pipes data of the specified WDN.
Table 1. Nodes and pipes data of the specified WDN.
NodesPipes
Node IDElevation [m]Demand [l/s]Node 1Node 2Length [m]Diameter [mm]Manning coeff.
18002.23502000.01
216022.1502000.01
315724.1601500.01
41474.24601500.01
513725.1501500.01
2.117.505.25501500.01
2.217.5055.3501000.01
4.11705.44501000.01
4.217043.2501000.01
5.116.503.13501000.01
5.216.5011.13002500.01
3.114.501.2212500.01
3.214.503.13.211000.01
5.313.505.15.211500.01
5.413.504.14.211500.01
1.11602.12.212000.01
1.21601.11.212500.01
5.35.411000.01
Table 2. Results of the three selected scenarios.
Table 2. Results of the three selected scenarios.
HourScenario 1 Scenario 2 Scenario 3
n.V (1.1 to 1.2)kWhV (2.1 to 2.2)kWhV (1.1 to 1.2)V (2.1 to 2.2)kWh
10.1030.0028000.10300.0028
20.1030.0028000.10300.0028
30.1690.0286000.16900.0286
40.2290.0704000.22900.0704
50.3750.251000.37500.251
60.8071.67380.1030.010.8070.1031.6831
70.9759.80450.1720.070.97509.8042
80.32.99920.280.290.303.0006
90.93610.3440.1770.070.9360.46710.344
100.8071.67380.1030.010.8070.1031.6831
1113.59640.120.0210.1143.6166
120.5419.0360.2070.120.5410.5459.0372
130.9572.84470.1110.020.9570.1062.8608
140.9631.0350.1030.010.9630.1031.0415
150.4440.4073000.4440.1030.4088
160.3070.1415000.30700.1415
170.2290.0704000.22900.0704
180.4440.4073000.4440.1030.4088
190.9631.0350.1030.010.9630.1031.0415
2017.49980.1550.0510.1457.5437
210.5850.8969000.5850.1030.9013
220.3070.1415000.30700.1415
230.1030.0028000.10300.0028
240.1030.0028000.10300.0028
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Cimorelli, L.; D’Aniello, A.; Cozzolino, L.; Pianese, D. A Derivative Free Non-Linear Programming Method for the Optimal Setting of PATs to Be Used in a Hybrid Genetic Algorithm: A Preliminary Work. Proceedings 2018, 2, 684. https://doi.org/10.3390/proceedings2110684

AMA Style

Cimorelli L, D’Aniello A, Cozzolino L, Pianese D. A Derivative Free Non-Linear Programming Method for the Optimal Setting of PATs to Be Used in a Hybrid Genetic Algorithm: A Preliminary Work. Proceedings. 2018; 2(11):684. https://doi.org/10.3390/proceedings2110684

Chicago/Turabian Style

Cimorelli, Luigi, Andrea D’Aniello, Luca Cozzolino, and Domenico Pianese. 2018. "A Derivative Free Non-Linear Programming Method for the Optimal Setting of PATs to Be Used in a Hybrid Genetic Algorithm: A Preliminary Work" Proceedings 2, no. 11: 684. https://doi.org/10.3390/proceedings2110684

APA Style

Cimorelli, L., D’Aniello, A., Cozzolino, L., & Pianese, D. (2018). A Derivative Free Non-Linear Programming Method for the Optimal Setting of PATs to Be Used in a Hybrid Genetic Algorithm: A Preliminary Work. Proceedings, 2(11), 684. https://doi.org/10.3390/proceedings2110684

Article Metrics

Back to TopTop