Analysis of water distribution networks using MATLAB and Excel spreadsheet: h‐based methods

The need for computer application for solving water distribution networks (WDNs) is inevitable for both educational and practical purposes. In this paper, three h‐based methods for solving WDN including h‐based Newton–Raphson method, finite element method, and gradient algorithm are implemented using MATLAB and Excel spreadsheet. The input data should be first inserted into Excel spreadsheet while MATLAB codes utilize this data to solve the pipe network. The output results are also presented in Excel for convenience. As educational facets of this application was the main focus of this paper, the details of this computer application were step‐by‐step explained with codes. Furthermore, a simple network selected from literature was analyzed using the three h‐based methods. Finally, the presented codes and this computer application are believed to encourage many educators and applicants to assess them for both educational and practical purposes in this engineering field. © 2017 Wiley Periodicals, Inc. Comput Appl Eng Educ 25:129–141, 2017; View this article online at wileyonlinelibrary.com/journal/cae; DOI 10.1002/cae.21786