Machine learning algorithms in wastewater technology : Predicting treatment quality and efficiency

Authors

DOI:

https://doi.org/10.24425/jwld.2025.155310

Abstract

Wastewater treatment is essential for protecting both the environment and public health. With a growing global population and concerns about water shortages, wastewater must be treated effectively to meet the increasing demand for drinking water. Wastewater treatment plants (WWTP) that use innovative technologies, such as machine learning (ML), are playing a leading role in addressing this challenge. This study aims to use advanced ML algorithms to predict parameters in WWTP Kenitra, such as total suspended solids (TSS), chemical oxygen demand (COD), and biological oxygen demand (BOD). Four ML models were evaluated, including random forest (RF), decision tree regressor (DTR), Gaussian process regressor (GPR), and adaptive boosting regression (AdaBoost-R). The coefficient of determination (R2) and accuracy were used to evaluate the algorithm’s efficiency, R2 values of 0.99, 0.93, and 0.96 were obtained by the DTR, reflecting exceptional performance with RMSE values of 1.33 mg∙dm-3 for TSS, 3.85 mg∙dm-3 for COD, and 2.32 mg∙dm-3 for BOD. The GPR demonstrated strong predictive capability, achieving R2 values of 0.92 for TSS and 0.97 for BOD, with corresponding RMSE values of 3.12 mg∙dm-3 and 2.67 mg∙dm-3, respectively. These results indicate that the DTR and GPR learning models provide better algorithms for evaluating wastewater parameters. In particular, the study demonstrates the main benefits of using ML algorithms to predict the parameters of WWTP. This study illustrates that the DTR optimises treatment solutions and monitors the treatment process. The proposed method outperforms other algorithms in terms of efficiency and provides an accurate way to improve the performance of WWTP.

References

Afan, H.A. et al. (2024) “Data-driven water quality prediction for wastewater treatment plants,” Heliyon, 10(18), e36940. Available at: https://doi.org/10.1016/j.heliyon.2024.e36940.

Aghdam, E. et al. (2023) “Predicting quality parameters of wastewater treatment plants using artificial intelligence techniques,” Journal of Cleaner Production, 405, 137019. Available at: https://doi.org/10.1016/j.jclepro.2023.137019.

Aghilesh, K. et al. (2023) “Use of artificial intelligence for optimizing biosorption of textile wastewater using agricultural waste,” Environmental Technology, 44(1), pp. 22–34. Available at: https://doi.org/10.1080/09593330.2021.1961874.

Anjum, M. et al. (2022) “Application of ensemble machine learning methods to estimate the compressive strength of fiber-reinforced nano-silica modified concrete,” Polymers, 14(18), 3906. Available at: https://doi.org/10.3390/polym14183906.

Asteris, P.G. et al. (2022) “Machine learning approach for rapid estimation of five-day biochemical oxygen demand in wastewater,” Water, 15(1), 103. Available at: https://doi.org/10.3390/w15010103.

Atanasova, N. and Kompare, B. (2002) “Modelling of wastewater treatment plant with decision and regression trees,” in Proceedings of the Workshop on Binding Environmental Sciences and Artificial Intelligence, Lyon, July 23, 2002. ECAI, pp. 6-1–6-9.

Ayyoub, H. et al. (2022) “Membrane bioreactor (MBR) performance in fish canning industrial wastewater treatment,” Water Practice & Technology, 17(6), pp. 1358–1368. Available at: https://doi.org/10.2166/wpt.2022.059.

Ayyoub, H. et al. (2023) “Aerobic treatment of fish canning wastewater using a pilot-scale external membrane bioreactor,” Results in Engineering, 17, 101019. Available at: https://doi.org/10.1016/j.rineng.2023.101019.

Baskar, G. et al. (2024) “Status and future trends in wastewater management strategies using artificial intelligence and machine learning techniques,” Chemosphere, 362, 142477. Available at: https://doi.org/10.1016/j.chemosphere.2024.142477.

Caswell, T.A. et al. (2023) Matplotlib: Visualization with Python. Available at: https://matplotlib.org (Accessed: December 26, 2024).

Cechinel, M.A.P. et al. (2024) “Enhancing wastewater treatment efficiency through machine learning-driven effluent quality prediction: A plant-level analysis,” Journal of Water Process Engineering, 58, 104758. Available at: https://doi.org/10.1016/J.JWPE.2023.104758.

Cheng, Q., Chunhong, Z. and Qianglin, L. (2023) “Development and application of random forest regression soft sensor model for treating domestic wastewater in a sequencing batch reactor,” Scientific Reports, 13(1), 9149. Available at: https://doi.org/10.1038/s41598-023-36333-8.

Daud, S. (2023) “Importance of water resources in the Middle Eastern politics,” Pakistan Journal of International Affairs, 6(3), pp. 406–427. Available at: https://doi.org/10.52337/pjia.v6i3.910.

Dey, I. et al. (2024) “Effluent quality improvement in sequencing batch reactor-based wastewater treatment processes using advanced control strategies,” Water Science and Technology, 89(10), pp. 2661–2675. Available at: https://doi.org/10.2166/wst.2024.150.

Duarte, M.S. et al. (2024) “A review of computational modeling in wastewater treatment processes,” ACS ES&T Water, 4(3), pp. 784–804. Available at: https://doi.org/10.1021/acsestwater.3c00117.

Fouchal, A. et al. (2025) “Biological oxygen demand prediction using artificial neural network and random forest models enhanced by the neural architecture search algorithm,” Modeling Earth Systems and Environment, 11(1), 9. Available at: https://doi.org/10.1007/s40808-024-02178-x.

Gholizadeh, M. et al. (2024) “Machine learning-based prediction of effluent total suspended solids in a wastewater treatment plant using different feature selection approaches: A comparative study,” Environmental Research, 246, 118146. Available at: https://doi.org/10.1016/J.ENVRES.2024.118146.

Harris, C.R. et al. (2020) “Array programming with NumPy,” Nature, 585(7825), pp. 357–362. Available at: https://doi.org/10.1038/s41586-020-2649-2.

Islam, M.M.U., Mondal, J.J. and Shihab, I.F. (2022) “Detecting faulty machinery of waste water treatment plant using statistical analysis & machine learning,” in 2022 25th International Conference on Computer and Information Technology (ICCIT), Cox's Bazar, Bangladesh, December 17–19, 2022. Piscataway Township, NJ: IEEE, pp. 188–193. Available at: https://doi.org/10.1109/ICCIT57492.2022.10055321.

Ivan, H.L. and Ivan, J.-P.A. (2023) “Banks of Gaussian process sensor models for fault detection in wastewater treatment processes,” in K.G. Kyprianidis et al. (eds.) SIMS 2023. Proceedings of the 64th International Conference of Scandinavian Simulation Society, Västerås, Sweden, September 25–28, 2023. Linköping: LiU E-Press, pp. 294–301. Available at: https://doi.org/10.3384/ecp200038.

Lukyanova, E., Golodov, M. and Kirilenko, V. (2024) “Wastewater quality and microbiology,” E3S Web of Conferences, 583, 02005. Available at: https://doi.org/10.1051/e3sconf/202458302005.

Ministère de l'Environnement du Maroc (2002) Normes marocaines [Moroccan standards]. Bulletin officiel du Maroc, No. 5062, 30 Ramadan 1423, Rabat. Available at: https://gazettes.africa/akn/ma/officialGazette/bulletin-officiel/2002-12-05/5062/fra@2002-12-05 (Accessed: December 26, 2024).

McKinney, W. and the Pandas Development Team (2022) “pandas: powerful Python data analysis toolkit – Release 1.4.4.,” Available at: https://pandas.pydata.org/pandas-docs/version/1.4/pandas.pdf (Accessed: December 26, 2024).

Nasir Bin, F. and Li, J. (2024) “Understanding machine learning predictions of wastewater treatment plant sludge with explainable artificial intelligence,” Water Environment Research, 96(10), e11136. Available at: https://doi.org/10.1002/wer.11136.

Nguyen, L.V. and Seidu, R. (2022) “Application of regression-based machine learning algorithms in sewer condition assessment for Ålesund City, Norway,” Water, 14(24), 3993. Available at: https://doi.org/10.3390/w14243993.

Pedregosa, F. et al. (2011) “Scikit-learn: Machine learning in Python,” Journal of Machine Learning Research, 12, pp. 2825–2830. Available at: https://www.jmlr.org/papers/volume12/pedregosa11a/pedregosa11a.pdf (Accessed: December 26, 2024).

Python (no date) Python 3.10 Documentation: The Python Language Reference. Available at: https://docs.python.org/3.10/reference/index.html (Accessed: December 26, 2024).

Qambar, A.S. and Khalidy, M.M.A. (2022) “Prediction of municipal wastewater biochemical oxygen demand using machine learning techniques: A sustainable approach,” Process Safety and Environmental Protection, 168, pp. 833–845. Available at: https://doi.org/10.1016/j.psep.2022.10.033.

Rashidi-Khazaee, P., Rezvantalab, S. and Kheshti Monasebi, A. (2024) “Predicting wastewater treatment plant effluent quality using ensemble learning,” Green Technologies, 02(01), pp. 35–43. Available at: https://gt.uut.ac.ir/article_210703.html (Accessed: December 26, 2024).

Rousis, N.I. et al. (2024) “Chapter 19 – Removal of emerging contaminants from wastewater by various treatment technologies in wastewater treatment plants,” in M. Hadi Dehghani, R.R. Karri and I. Tyagi (eds.) Sustainable remediation technologies for emerging pollutants in aqueous environment. Amsterdam: Elsevier, pp. 389–409. Available at: https://doi.org/10.1016/B978-0-443-18618-9.00020-6.

Saleem, M.A., Harrou, F. and Sun, Y. (2024) “Explainable machine learning methods for predicting water treatment plant features under varying weather conditions,” Results in Engineering, 21, 101930. Available at: https://doi.org/10.1016/j.rineng.2024.101930.

Santos, E., Carvalho, M. and Martins, S. (2023) “Sustainable water management: understanding the socioeconomic and cultural dimensions,” Sustainability, 15(17), 13074. Available at: https://doi.org/10.3390/su151713074.

Shingare, S.P. et al. (2024) “Applicability of machine learning in waste water quality detection,” in 2024 IEEE International Conference on Computing, Power and Communication Technologies (IC2PCT), Greater Noida, India, February 09–10, 2024. Piscataway Township, NJ: IEEE, pp. 525–530. Available at: https://doi.org/10.1109/IC2PCT60090.2024.10486814.

Tan, J.J., Arumugasamy, S.K. and Teo, F.Y. (2025) “Water quality index prediction using artificial neural network: A case study of Selangor River, Malaysia,” International Journal of Sustainable Agricultural Management and Informatics, 11(1), pp. 48–71. Available at: https://doi.org/10.1504/IJSAMI.2025.143101.

Tyralis, H., Papacharalampous, G. and Langousis, A. (2019) “A brief review of random forests for water scientists and practitioners and their recent history in water resources,” Water, 11(5), 910. Available at: https://doi.org/10.3390/w11050910.

Wang, Y., Cui, Z. and Ke, R. (2023) “Chapter 3 – Machine learning basics,” in Machine learning for transportation research and applications. Amsterdam: Elsevier, pp. 25–40. Available at: https://doi.org/10.1016/B978-0-32-396126-4.00008-4.

Yang, T. et al. (2024) “The LPST-Net: A new deep interval health monitoring and prediction framework for bearing-rotor systems under complex operating conditions,” Advanced Engineering Informatics, 62, 102558. Available at: https://doi.org/10.1016/j.aei.2024.102558.

Yazdani, H., Doostizadeh, M. and Aminifar, F. (2023) “Forecast-aided power and flexibility trading of prosumers in peer to peer markets,” IET Renewable Power Generation, 17(4), pp. 920–934. Available at: https://doi.org/10.1049/rpg2.12645.

Zhao, L. et al. (2020) “Application of artificial intelligence to wastewater treatment: A bibliometric analysis and systematic review of technology, economy, management, and wastewater reuse,” Process Safety and Environmental Protection, 133, pp. 169–182. Available at: https://doi.org/10.1016/j.psep.2019.11.014.

Downloads

Published

2025-06-30

How to Cite

Barahi, Sihame, et al. “Machine Learning Algorithms in Wastewater Technology : Predicting Treatment Quality and Efficiency”. Journal of Water and Land Development, vol. 66, no. 66, June 2025, pp. 137-51, doi:10.24425/jwld.2025.155310.

Issue

Section

Articles

Similar Articles

<< < 11 12 13 14 15 16 17 18 19 20 > >> 

You may also start an advanced similarity search for this article.