Next Article in Journal
Assessment of the Introduction of Microorganisms Capable of Destroying Toxic Compounds during Seed Germination
Previous Article in Journal
An Analytical Solution for the Hydraulics of Looped Pipe Networks
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Proceeding Paper

AI-Assisted Pump Operation for Energy-Efficient Water Distribution Systems †

by
Niuosha Hedaiaty Marzouny
* and
Rebecca Dziedzic
Building, Civil and Environmental Engineering Department, Concordia University, Montreal, QC H3G 2W1, Canada
*
Author to whom correspondence should be addressed.
Presented at the 3rd International Joint Conference on Water Distribution Systems Analysis & Computing and Control for the Water Industry (WDSA/CCWI 2024), Ferrara, Italy, 1–4 July 2024.
Eng. Proc. 2024, 69(1), 3; https://doi.org/10.3390/engproc2024069003
Published: 28 August 2024

Abstract

:
Pumping water in water networks is generally the top energy demand for water systems. This study seeks to develop a large language model (LLM)-assisted framework for pump operation. Herein, ChatGPT was used to suggest pump control settings over 24 h that minimize energy use while maintaining pressure levels. In the proposed prompts, hourly information about the planned operation, i.e., pump control settings, minimum pressure levels, tank storage levels, and pump energy use, was provided. As the LLM suggests improved scenarios, EPANET results for these scenarios are fed back to it. This allows the LLM to learn and adjust future suggestions. The framework was validated on the example EPANET Net 3. Through iterative data exchange between the LLM and EPANET, the framework led to more energy-efficient pump scheduling. The LLM-assisted framework was compared with a genetic algorithm optimization. The results demonstrated that the proposed method outperformed the GA, achieving an energy reduction of 66.98%.

1. Introduction

Water distribution systems (WDSs) are among the major consumers of energy resources. Pump stations are responsible for the majority of energy consumption in WDS, with electricity usage representing the largest proportion, in some cases reaching 90% [1]. Thus, improving the efficiency of pump station operations can significantly impact the energy efficiency of WDSs as a whole. At the same time, these operations must ensure WDS pressure levels are maintained, and demands are met.
The challenge of improving energy efficiency while maintaining WDS levels of service has attracted the attention of various researchers. Due to the complex dynamics within the hydraulic equations governing water networks, i.e., the nonlinearity and non-convexity of the energy and flow constraints, pump scheduling optimization is a nonpolynomial (NP)-hard problem. To address this problem, many optimization methods have been developed to schedule pump operations, including local search (linear, nonlinear, and dynamic programming), discrete search, global search, and hybrid methods. In the context of real-time pump control in WDSs, Odan et al. [2] developed an integrated model based on evolutionary optimization, which comprised three sub-models, i.e., demand forecasting tool, hydraulic simulation, and multialgorithm genetically adaptive method. The proposed methodology was implemented in a real case study, and the results demonstrated its capability to achieve a 13% reduction in energy consumption while ensuring the reliability of the water supply. Salomons and Housh [3] addressed the optimization problem using a practical reduced mixed integer linear program (MILP) formulation. They proposed a real-time pump optimization framework for both fixed- and variable-speed pumps. On the other hand, Bagloee et al. [4] focused on a large system and introduced a hybrid methodology that incorporates machine learning techniques and optimization algorithms.
These methodologies involve the application of advanced algorithms aimed at determining the optimal pump control settings, taking into account hydraulic dynamics and energy efficiency considerations. Once the optimal configurations are determined, they are communicated to operators (offline control scenario) or control units (real-time control scenario) for implementation. However, despite the potential advantages of these optimized solutions, they may be perceived as a black box to operators, as the mechanism of underlying algorithms may be difficult to comprehend. As a result, operators may opt to return to their original rule-of-thumb settings, which they find more familiar and comfortable. This highlights the importance of engaging operators in the optimization process fully exploiting the benefits of these advanced methodologies.
To address this challenge, large language models (LLMs) offer a promising solution for effectively bridging the gap between advanced automated tasks and operators’ comprehension. ChatGPT [5], an advanced LLM developed by OpenAI, is a notable example, leveraging its natural language understanding and generation capabilities to assist users in various contexts. Recent applications in the water industry include platforms for managing systems [6] and communicating with customers [7]. This study seeks to develop a large language model (LLM)-assisted framework for pump operation. The proposed framework integrates a hydraulic simulator with an LLM model to provide operators with suggestions for future optimized pump control. The effectiveness of the proposed methodology was validated using the EPANET Net 3 example, and the results were compared with those obtained using a genetic algorithm.

2. Materials and Methods

The proposed LLM-assisted framework for pump operation optimization was developed in Python and is illustrated in Figure 1. The procedure begins by feeding an operator prompt to the LLM, GPT 3.5-turbo. The prompt consists of an explanation of the role of the ChatGPT along with the operator’s requests, i.e., minimizing energy usage while maintaining the desired pressure levels in water networks. This operator-fed prompt is then combined with the original pump control settings planned for the next 24 h and the hydraulic status of the WDS, including minimum pressure levels, tank water level, and energy usage of each pump at each time step, provided by the EPANET [8] simulator. An open Python toolkit for EPANET known as OWA-EPANET [9] was used. The constructed prompt is then fed to the LLM unit (ChatGPT). Next, the LLM suggests new pump settings. These new settings are fed to the EPANET simulator again. The hydraulic results of these settings are then once again fed into the LLM unit. This iterative data exchange continues until a minimum feasible energy consumption in the WDS is achieved. The stopping criteria for the process is the maximum number of iterations with no further reduction in energy consumption, set at 15 iterations.
This process of fine-tuning LLM models with minimal data samples, known as few-shot learning [10], can significantly benefit from the implementation of prompt engineering techniques. In this research, a range of prompts spanning from numerical to conversational dialogues were evaluated. Within the proposed framework, three strategies aimed at enhancing efficiency were investigated: (1) full history and feedback loop, (2) short-term history and no feedback loop, and (3) short-term history and feedback loop.
To compare the LLM-based approach with other traditional approaches, a genetic algorithm (GA) was implemented. The objective function, designed to reflect the optimization goal, incorporates both the primary objective of minimizing energy consumption and penalty terms to enforce constraints on decision variables. The GA was configured with a population size of 100, mutation probability of 0.8, elitism ratio of 0.01, crossover probability of 0.8, and a parent portion of 0.5. Similar to the iterative process within the ChatGPT-assisted framework, the maximum number of iterations for the optimization was set to 50. Additionally, a condition was imposed where the algorithm would terminate if no improvement was observed within 15 consecutive iterations.
The method proposed in this study was applied to the EPANET Net 3 example, which features two water sources and three tanks. For the purposes of this study, the original Net 3 was modified by adding pump efficiency curves to all pumps.

3. Results

The present study examined three different strategies for prompt engineering. The application of Strategy 3 demonstrated a greater reduction in energy consumption, as shown in Table 1. However, it is noteworthy that Strategy 1 exhibited higher robustness with a lower standard deviation, and the convergence iteration of the first two strategies was lower, indicative of reduced computational requirements.
As an interactive tool, the LLM enables operators to explore and assess the impacts of various pump control settings on system performance. Moreover, it demonstrates the potential to achieve optimal energy consumption levels while maintaining the desired pressure. To illustrate this capability, we compared the performance of the proposed framework in this study with that of a genetic optimization algorithm using an equal maximum number of iterations.
The analysis of the results reveals that the proposed methodology has enhanced performance in the optimization process, supported by its ability to achieve a higher reduction rate with a reduced number of iterations. Notably, the lower average value of solutions (lowest energy consumption across all the iterations) in the application of the AI-assisted framework highlights its robustness.

4. Discussion

The integration of LLMs like ChatGPT with hydraulic simulation tools for optimizing pump scheduling in WDSs shows promising potential. The evaluation of different prompt engineering strategies reveals the need to maintain a balance between energy reduction and solution stability. Strategy 3, integrating the use of the feedback loop and short-term historical dialogues, achieved the highest energy reduction. Comparing the AI-assisted framework with a genetic optimization algorithm highlights the former’s superiority, achieving higher energy reduction with fewer iterations. The rapid convergence and lower average solution value of the AI-assisted framework emphasize its efficiency and reliability in optimizing pump operation decisions within WDSs, along with bridging the gap between advanced automation and operator comprehension.
These findings suggest practical implications for enhancing energy efficiency and system performance in WDSs. The AI-assisted framework offers an intuitive and interpretable approach to pump scheduling optimization, empowering operators to make informed decisions. Further research is essential to fully realize the potential of AI-driven solutions in enhancing the sustainability and resilience of water supply systems. Although the findings demonstrate the efficacy of the proposed methodology within the Net 3 example, extrapolating the results to a larger, more complex system within variable demand patterns presents notable challenges requiring further investigation in future research endeavors. Additionally, the proposed methodology can be further improved by incorporating variable speed pumps.

Author Contributions

Methodology, N.H.M. and R.D.; validation, N.H.M. and R.D.; writing—original draft preparation, N.H.M.; writing—review and editing, R.D. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the Natural Sciences and Engineering Research Council, grant number RGPIN-2022-04664.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data used in this study are openly available at http://wateranalytics.org/EPANET/ (accessed on 10 April 2024).

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Karassik, I.J. Pump Handbook; McGraw-Hill: New York, NY, USA, 2001. [Google Scholar]
  2. Odan, F.K.; Ribeiro Reis, L.F.; Kapelan, Z. Real-time multiobjective optimization of operation of water supply systems. J. Water Resour. Plan. Manag. 2015, 141, 04015011. [Google Scholar] [CrossRef]
  3. Salomons, E.; Housh, M.A. Practical optimization scheme for real-time operation of water distribution systems. J. Water Resour. Plan. Manag. 2020, 146, 04020016. [Google Scholar] [CrossRef]
  4. Bagloee, S.A.; Asadi, M. Minimization of water pumps’ electricity usage: A hybrid approach of regression models with optimization. Expert Syst. Appl. 2018, 107, 222–242. [Google Scholar] [CrossRef]
  5. OpenAI. ChatGPT. Available online: https://openai.com/blog/chatgpt (accessed on 10 April 2024).
  6. Klir. Introducing Klir Comply with Microsoft ChatGPT Integration. Available online: https://www.klir.com/resources/introducing-klir-comply (accessed on 10 April 2024).
  7. DEWA. DEWA Initiates Pilot Use of ChatGPT to Enhance the Capabilities of Rammas, Its Virtual Employee. Available online: https://www.dewa.gov.ae/en/about-us/media-publications/latest-news/2023/05/dewa-initiates-pilot (accessed on 10 April 2024).
  8. Rossman, L.A. EPANET 2: Users Manual 2000, 1-200. Available online: https://nepis.epa.gov/Exe/ZyNET.exe/P1007WWU.TXT?ZyActionD=ZyDocument&Client=EPA&Index=2000+Thru+2005&Docs=&Query=&Time=&EndTime=&SearchMethod=1&TocRestrict=n&Toc=&TocEntry=&QField=&QFieldYear=&QFieldMonth=&QFieldDay=&IntQFieldOp=0&ExtQFieldOp=0&XmlQuery=&File=D%3A%5Czyfiles%5CIndex%20Data%5C00thru05%5CTxt%5C00000024%5CP1007WWU.txt&User=ANONYMOUS&Password=anonymous&SortMethod=h%7C-&MaximumDocuments=1&FuzzyDegree=0&ImageQuality=r75g8/r75g8/x150y150g16/i425&Display=hpfr&DefSeekPage=x&SearchBack=ZyActionL&Back=ZyActionS&BackDesc=Results%20page&MaximumPages=1&ZyEntry=1&SeekPage=x&ZyPURL (accessed on 10 April 2024).
  9. OWA-EPANET Toolkit. Available online: http://wateranalytics.org/EPANET/ (accessed on 10 April 2024).
  10. Brown, T.; Mann, B.; Ryder, N.; Subbiah, M.; Kaplan, J.D.; Dhariwal, P.; Neelakantan, A.; Shyam, P.; Sastry, G.; Askell, A.; et al. Language models are few-shot learners. Adv. Neural Inf. Process. Syst. 2020, 33, 1877–1901. [Google Scholar]
Figure 1. Proposed LLM-assisted framework to optimize the pump scheduling.
Figure 1. Proposed LLM-assisted framework to optimize the pump scheduling.
Engproc 69 00003 g001
Table 1. The results of evaluating three prompt engineering strategies for pump optimization.
Table 1. The results of evaluating three prompt engineering strategies for pump optimization.
MethodEnergy Reduction (%)Standard DeviationConvergence Iteration
LLM Strategy 126.87%209.904
LLM Strategy 28.94%1848.714
LLM Strategy 366.98%794.3419
GA51.48%1786.0126
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Hedaiaty Marzouny, N.; Dziedzic, R. AI-Assisted Pump Operation for Energy-Efficient Water Distribution Systems. Eng. Proc. 2024, 69, 3. https://doi.org/10.3390/engproc2024069003

AMA Style

Hedaiaty Marzouny N, Dziedzic R. AI-Assisted Pump Operation for Energy-Efficient Water Distribution Systems. Engineering Proceedings. 2024; 69(1):3. https://doi.org/10.3390/engproc2024069003

Chicago/Turabian Style

Hedaiaty Marzouny, Niuosha, and Rebecca Dziedzic. 2024. "AI-Assisted Pump Operation for Energy-Efficient Water Distribution Systems" Engineering Proceedings 69, no. 1: 3. https://doi.org/10.3390/engproc2024069003

Article Metrics

Back to TopTop