# Optimal Sensor Placement for Leak Location in Water Distribution Networks using Evolutionary Algorithms

^{1}

^{2}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. LSS-Based Leak Location Method

#### 2.1. Leak Magnitude Linear Dependency Approximation

#### 2.2. Leak Signature Space

#### 2.3. Leak Location Method

#### 2.4. Incorporating a Time Horizon Analysis

## 3. Sensor Placement: Problem Formulation

#### 3.1. Considering a Single Time Instant

#### 3.2. Considering a Time Horizon Analysis

## 4. Sensor Placement: Resolution Methods

#### 4.1. Semi-Exhaustive Search Approach

#### 4.2. Stochastic Optimization Approaches

Algorithm 1 Sensor placement based on genetic algorithms or particle swarm optimization. |

Require: the number of sensors n, the number of nodes m, the $s\times m\times m$ three-dimensional matrix R of residuals for the s leak magnitudes modeled and the maximum number of iterations $it$. |

Ensure: a near-optimal sensor configuration ${\mathbf{\text{x}}}_{min}$ with error index ${\u03f5}_{min}$. |

1: Initialize the search with the previous solution. |

2: Set the appropriate restrictions. |

3: Choose the seed size. |

4: for The number of iterations selected do |

5: Build the initial population matrix with rows randomly initialized. |

6: Inputs: The initial solution, restrictions, residuals and sensitivities. //Start GA- or PSO-based search. |

7: while An optimization criterion is not reached do |

8: Get a possible configuration. |

9: Analyze the configuration according to Equation (13). |

10: Evaluate the solution using Equation (16). |

11: end while |

12: Evaluate the found solutions and choose the one with the minimal value. //End GA- or PSO-based search. |

13: end for |

14: Find the best solution ${\mathbf{\text{x}}}_{min}$ with the minimal error index ${\u03f5}_{min}$ between all of the iterations and save it as the near-optimal sensor placement. |

## 5. Experimental Results

**Figure 1.**The Hanoi (

**a**) and Limassol (

**b**) water distribution networks (WDNs) used as benchmarks to evaluate the sensor placement method.

#### 5.1. Semi-Exhaustive Search Application

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s) |
---|---|---|---|---|

2 | 12, 21 | 5 | 93.1 | 11.2 |

3 | 12, 21, 29 | 1 | 98.6 | 181.0 |

4 | 1, 12, 21, 29 | 0 | 100.0 | 1637.5 |

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s $\times {10}^{3}$) |
---|---|---|---|---|

2 | 8, 152 | 253 | 60.6 | $19.8$ |

2 + 1 | 8, 75, 152 | 166 | 72.0 | $19.8$ + 0.54 |

#### 5.2. Application of GA and PSO Approaches

**Figure 2.**Evaluation of the parameters to select for application of GA and PSO. (

**a**) Tuning for the GA in the Hanoi network; (

**b**) tuning for the PSO in the Hanoi network; (

**c**) tuning for the GA in the Limassol network; (

**d**) tuning for the PSO in the Limassol network.

#### 5.2.1. Tests on the Hanoi WDN

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s) | ||||
---|---|---|---|---|---|---|---|---|

GA | PSO | GA | PSO | GA | PSO | GA | PSO | |

2 | 12, 21 | 12, 21 | 5 | 5 | 93.1 | 93.1 | 69.9 | 17.3 |

3 | 12, 21, 27 | 12, 14, 21 | 1 | 1 | 98.6 | 98.6 | 113.9 | 38.0 |

4 | 1, 12, 21, 29 | 1, 12, 21, 24 | 0 | 0 | 100.0 | 100.0 | 119.9 | 57.5 |

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s $\times {10}^{3}$) | ||||
---|---|---|---|---|---|---|---|---|

GA | PSO | GA | PSO | GA | PSO | GA | PSO | |

2 | 12, 21 | 12, 21 | 7 | 7 | 93.5 | 93.5 | $2.2$ | 0.5 |

3 | 12, 14, 21 | 12, 14, 21 | 1.08 | 1.08 | 98.8 | 98.8 | $4.1$ | $1.2$ |

4 | 1, 12, 21, 27 | 1, 12, 21, 27 | 0.08 | 0.08 | 100.0 | 100.0 | $3.7$ | $1.3$ |

#### 5.2.2. Tests on the Limassol WDN

**Table 5.**Sensor placement in the Limassol WDN using stochastic approaches and a single time instant.

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s $\times {10}^{3}$) | ||||
---|---|---|---|---|---|---|---|---|

GA | PSO | GA | PSO | GA | PSO | GA | PSO | |

2 | 8, 152 | 8, 152 | 253 | 253 | 60.6 | 60.6 | $11.0$ | $3.3$ |

3 | 75, 120, 152 | 76, 115, 152 | 145 | 151 | 74.1 | 74.0 | $19.6$ | $6.0$ |

4 | 76, 82, 120, 152 | 69, 82, 119, 152 | 114 | 131 | 78.0 | 76.2 | $31.2$ | $15.1$ |

5 | 75, 82, 120, 126, 152 | 70, 115, 125, 152, 188 | 106 | 122 | 79.0 | 77.4 | $36.8$ | $17.4$ |

**Table 6.**Sensor placement in the Limassol WDN using stochastic approaches and a time horizon analysis.

Sensors | Node Indexes | Overlaps | Efficiency (%) | Time (s $\times {10}^{3}$) | ||||
---|---|---|---|---|---|---|---|---|

GA | PSO | GA | PSO | GA | PSO | GA | PSO | |

2 | 124, 153 | 124, 153 | 424.8 | 424.8 | 77.7 | 77.7 | 32.3 | 27.5 |

3 | 76, 133, 169 | 75, 122, 117 | 289.8 | 306.2 | 84.9 | 84.8 | $82.4$ | $66.4$ |

#### 5.3. Optimization Criterion and Leak Detection Efficiency

**Figure 3.**Efficiency in leak location according to the number of overlaps in the configuration for the Limassol network.

## 6. Conclusions

## Acknowledgments

## Author Contributions

## Conflicts of Interest

## References

- Brothers, K.J. A practical approach to water loss reduction. Water 21 IWA Task Force
**2003**, 1, 54–55. [Google Scholar] - World-Health-Organization; UNICEF. Accounting for Water Loss. In Global Water Supply and Sanitation Assessment 2000 Report; World-Health-Organization, UNICEF: New York, NY, USA, 2000; p. 80. [Google Scholar]
- Hamilton, S.; Charalambous, B. Leak detection technologies. Leak Detect.: Technol. Implement.
**2013**, 1, 104. [Google Scholar] - Puust, R.; Kapelan, Z.; Savic, D.A.; Koppel, T. A review of methods for leakage management in pipe networks. Urban Water J.
**2010**, 7, 25–45. [Google Scholar] [CrossRef] - Wu, Z.Y.; Farley, M.; Turtle, D.; Dahasahasra, S.; Mulay, M.; Boxall, J.; Mounce, S.; Kleiner, Y.; Kapelan, Z. Water Loss Reduction. In Water Modeling and Water Loss Management; Bentley Systems: Pennsylvania, PA, USA, 2011. [Google Scholar]
- Colombo, A.F.; Lee, P.; Karney, B.W. A selective literature review of transient-based leak detection methods. J. Hydro-Environ. Res.
**2009**, 2, 212–227. [Google Scholar] [CrossRef] - Pudar, R.S.; Liggett, J.A. Leaks in Pipe Networks. J. Hydraul. Eng.
**1992**, 118, 1031–1046. [Google Scholar] [CrossRef] - Pérez, R.; Puig, V.; Pascual, J.; Quevedo, J.; Landeros, E.; Peralta, A. Methodology for leakage isolation using pressure sensitivity analysis in water distribution networks. Control Eng. Pract.
**2011**, 19, 1157–1167. [Google Scholar] [CrossRef] - Perez, R.; Sanz, G.; Puig, V.; Quevedo, J.; Cuguero Escofet, M.; Nejjari, F.; Meseguer, J.; Cembrano, G.; Mirats Tur, J.; Sarrate, R. Leak Localization in Water Networks: A Model-Based Methodology Using Pressure Sensors Applied to a Real Network in Barcelona [Applications of Control]. Control Syst. IEEE
**2014**, 34, 24–36. [Google Scholar] [CrossRef] - Casillas, M.V.; Garza-Castañón, L.; Puig, V. Extended-Horizon Analysis of Pressure Sensitivities for Leak Detection in Water Distribution Networks. In Proceedings of the 8th IFAC Symposium on Fault Detection, Supervision and Safety of Technical Processes, Mexico City, Mexico, 29–31 August 2012; pp. 570–575.
- Casillas, M.V.; Garza-Castañón, L.; Puig, V. Model-based Leak Detection and Location in Water Distribution Networks considering an Extended-horizon Analysis of Pressure Sensitivities. J. Hydroinform.
**2014**, 16, 649–670. [Google Scholar] [CrossRef] - Worden, K.; Burrows, A. Optimal sensor placement for fault detection. Eng. Struct.
**2001**, 23, 885–901. [Google Scholar] [CrossRef] - Yassine, A.; Ploix, S.; Flaus, J.M. A Method for Sensor Placement Taking into Account Diagnosability Criteria. Int. J. Appl. Math. Comput. Sci.
**2008**, 18, 497–512. [Google Scholar] [CrossRef] - Krysander, M.; Frisk, E. Sensor Placement for Fault Diagnosis. Syst. Man Cybernetics Part A: Syst. Hum. IEEE Trans.
**2008**, 38, 1398–1410. [Google Scholar] [CrossRef] - Krause, A.; Leskovec, J.; Guestrin, C.; Vanbriesen, J.; Faloutsos, C. Efficient sensor placement optimization for securing large water distribution networks. J. Water Resour. Plan. Manag.
**2008**, 134, 516–526. [Google Scholar] [CrossRef] - Aral, M.; Guan, J.; Maslia, M. Optimal Design of Sensor Placement in Water Distribution Networks. J. Water Resour. Plan. Manag.
**2010**, 136, 5–18. [Google Scholar] [CrossRef] - Multiobjective Sampling Design for Water Distribution Model Calibration. J. Water Resour. Plan. Manag.
**2003**, 129, 466–479. [CrossRef] - Sanz, G.; PÃl’rez, R. Sensitivity Analysis for Sampling Design and Demand Calibration in Water Distribution Networks Using the Singular Value Decomposition. J. Water Resour. Plan. Manag.
**2015**, 141, 04015020. [Google Scholar] [CrossRef] - Sarrate, R.; Nejjari, F.; Rosich, A. Sensor Placement for Fault Diagnosis Performance Maximization in Distribution Networks. In Proceedings of the 18th Mediterranean Conference on Control and Automation (MED), Barcelona, Spain, 3–6 July 2012; pp. 1–6.
- Christodoulou, S.; Gagatsis, A.; Xanthos, A.; Kranioti, S.; Agathokleous, A.; Fragiadakis, M. Entropy-Based Sensor Placement Optimization for Waterloss Detection in Water Distribution Networks. Water Resour. Manag.
**2013**, 27, 4443–4468. [Google Scholar] [CrossRef] - Casillas, M.V.; Puig, V.; Garza-Castañón, L.E.; Rosich, A. Optimal Sensor Placement for Leak Location in Water Distribution Networks Using Genetic Algorithms. Sensors
**2013**, 13, 14984–15005. [Google Scholar] [CrossRef] [PubMed] [Green Version] - Casillas, M.V.; Garza-Castañón, L.E.; Puig, V.; Vargas-Martinez, A. Leak Signature Space: An Original Representation for Robust Leak Location in Water Distribution Networks. Water
**2015**, 7, 1129–1148. [Google Scholar] [CrossRef] [Green Version] - Todini, E.; Pilati, S. Computer applications in water supply: volume 1—systems analysis and simulation. In Chapter A Gradient Algorithm for the Analysis of Pipe Networks; Research Studies Press Ltd.: Taunton, UK, 1988; pp. 1–20. [Google Scholar]
- Rossman, L. EPANET 2 User’s Manual; United States Envionmental Protection Agency: Cincinnati, OH, USA, 2000. [Google Scholar]
- Goldberg, D. Genetic Algorithms in Search, Optimization, and Machine Learning; Addison-Wesle: Reading, MA, USA, 1989. [Google Scholar]
- Koza, J.R. Survey of Genetic Algorithms and Genetic Programming. In Proceedings of the Wescon 95—Conference Record: Microelectronics, Communications Technology, Producing Quality Products, Mobile and Portable Power, Emerging Technologies, San Francisco, CA, USA, 7–9 November 1995; pp. 589–594.
- Elsayed, S.M.; Sarker, R.A.; Essam, D.L. A new genetic algorithm for solving optimization problems. Eng. Appl. Artif. Intell.
**2014**, 27, 57–69. [Google Scholar] [CrossRef] - Chipperfield, A.; Fleming, P.; Pohlheim, H.; Fonseca, C. Genetic Algorithm TOOLBOX For Use with MATLAB; Technical Report; Department of Automatic Control and Systems Engineering, University of Sheffield: South Yorkshire, UK, 1994. [Google Scholar]
- Kennedy, J.; Eberhart, R. Particle swarm optimization. In Proceedings of the IEEE International Conference on Neural Networks, Perth, Australia, 27 November–1 December 1995; Volume 4, pp. 1942–1948.
- Poli, R.; Kennedy, J.; Blackwell, T. Particle swarm optimization. Swarm Intell.
**2007**, 1, 33–57. [Google Scholar] [CrossRef] - Kuila, P.; Jana, P.K. Energy efficient clustering and routing algorithms for wireless sensor networks: Particle swarm optimization approach. Eng. Appl. Artif. Intell.
**2014**, 33, 127–140. [Google Scholar] [CrossRef] - Chang, B.M.; Tsai, H.H.; Shih, J.S. Using fuzzy logic and particle swarm optimization to design a decision-based filter for cDNA microarray image restoration. Eng. Appl. Artif. Intell.
**2014**, 36, 12–26. [Google Scholar] [CrossRef] - Chen, S. Another Particle Swarm Toolbox; MATLAB Central File Exchange. Available online: http://www.mathworks.com/matlabcentral/fileexchange/25986-another-particle-swarm-toolbox (accessed on 29 October 2015).
- Fujiwara, O.; Khang, D.B. A two-phase decomposition method for optimal design of looped water distribution networks. Water Resour. Res.
**1990**, 26. [Google Scholar] [CrossRef] - Bolognesi, A.; Bragalli, C.; Marchi, A.; Artina, S. Genetic Heritage Evolution by Stochastic Transmission in the optimal design of water distribution networks. Adv. Eng. Softw.
**2010**, 41, 792–801. [Google Scholar] [CrossRef] - Zheng, F.; Zecchin, A.; Simpson, A. Self-Adaptive Differential Evolution Algorithm Applied to Water Distribution System Optimization. J. Comput. Civ. Eng.
**2013**, 27, 148–158. [Google Scholar] [CrossRef] [Green Version] - Effinet-project. EFFINET. Available online: http://effinet.eu/ (accessed on 29 October 2015).
- Perez, R.; Behdinan, K. Particle swarm approach for structural design optimization. Comput. Struct.
**2007**, 85, 1579–1588. [Google Scholar] [CrossRef] - Kennedy, J.; Eberhart, R. A discrete binary version of the particle swarm algorithm. Systems, Man, and Cybernetics, 1997. In Proceedings of the 1997 IEEE International Conference on Computational Cybernetics and Simulation, Orlando, FL, USA, 12–15 October 1997; Volume 5, pp. 4104–4108.

© 2015 by the authors; licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Casillas, M.V.; Garza-Castañón, L.E.; Puig, V.
Optimal Sensor Placement for Leak Location in Water Distribution Networks using Evolutionary Algorithms. *Water* **2015**, *7*, 6496-6515.
https://doi.org/10.3390/w7116496

**AMA Style**

Casillas MV, Garza-Castañón LE, Puig V.
Optimal Sensor Placement for Leak Location in Water Distribution Networks using Evolutionary Algorithms. *Water*. 2015; 7(11):6496-6515.
https://doi.org/10.3390/w7116496

**Chicago/Turabian Style**

Casillas, Myrna V., Luis E. Garza-Castañón, and Vicenç Puig.
2015. "Optimal Sensor Placement for Leak Location in Water Distribution Networks using Evolutionary Algorithms" *Water* 7, no. 11: 6496-6515.
https://doi.org/10.3390/w7116496