# Predicting Water Availability in Water Bodies under the Influence of Precipitation and Water Management Actions Using VAR/VECM/LSTM

^{1}

^{2}

^{3}

^{4}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Related Works

## 3. Methodology Used

#### 3.1. Vector Autoregressive (VAR)

_{t}: is the vector of observation, A: parameter matrix, ε

_{t}: a vector of error,

_{t}: is at any instant of time.

#### 3.2. Vector Error Correction Model (VECM)

_{t}= γ

_{t}− γ

_{t−1}, y

_{t}

_{−1}= vector variable endogenous with lag1, ${\phi}_{t}$ = k × 1 vector residuals, D

_{t}= k × 1 vector constant, Π = matrix coefficient of cointegration (Π = αβ

^{t}; α = vector adjustment, k × r matrix and β = matrix cointegration (long-run parameter) (k × r)) Γ

_{i}= k × k matrix coefficient the i th variable endogenous. p represents the lag; r is the cointegration rank; k is the size of vectors considered.

#### 3.3. Long Short Term Memory (LSTM)

_{t}represents the cell input state, the cell output state is given as ${C}_{t}$, and ${C}_{t-1}$ is its former state, ${i}_{t}$, ${f}_{t}$, and ${o}_{t}$ are the three gate’s states. Both ${C}_{t}$ and ${h}_{t}$ are transmitted to the following NN in RNN, determined by the structure of the LSTM cell. We use Equation (3) in order to evaluate ${C}_{t}$ and ${h}_{t}$.

_{t}to the three gates and the cell input, weight metrics ${W}_{h}^{i}$, ${W}_{h}^{f}$, ${W}_{h}^{o}$, ${W}_{h}^{C}$ connects h

_{t−}

_{1}to the three gates and cell input, bias terms for all three gates and cell inputs (b

_{i}, b

_{f}, b

_{o}, b

_{C}), the sigmoid function ($\frac{1}{1+\mathrm{exp}\left(-x\right)}$) given by σ and the hyperbolic tangent function, ($\frac{\mathrm{exp}\left(x\right)-\mathrm{exp}\left(-x\right)}{\mathrm{exp}\left(x\right)+\mathrm{exp}\left(-x\right)}$), represented by tanh.

_{t}, f

_{t}, $\u0108$

_{t}, C

_{t}

_{−1}, and C

_{t}have the same dimensions.

## 4. Evaluation Metrics

#### 4.1. Mean Absolute Error (MAE)

_{j}: observed value.

#### 4.2. Root Mean Squared Error (RMSE)

_{j}: observed value.

#### 4.3. Model Framework

## 5. Case Study Area

## 6. Results and Discussion

## 7. Applications of Models to Water Bodies

#### 7.1. Aquifer

#### 7.2. Lake

#### 7.3. River

`→`Temperature

`→`Hydrometry. The former can shock later but not the other way around.

#### 7.4. Water Springs

## 8. Conclusions

## Author Contributions

## Funding

## Data Availability Statement

## Acknowledgments

## Conflicts of Interest

## References

- Baer, A. Not enough water to go round? Int. Soc. Sci. J.
**1996**, 48, 277–292. [Google Scholar] [CrossRef] - Yuan, X.; Wu, X.; Tian, H.; Yuan, Y.; Adnan, R.M. Parameter Identification of Nonlinear Muskingum Model with Backtracking Search Algorithm. Water Resour. Manag.
**2016**, 30, 2767–2783. [Google Scholar] [CrossRef] - Salem, G.S.A.; Kazama, S.; Shahid, S.; Dey, N.C. Impact of temperature changes on groundwater levels and irrigation costs in a groundwater-dependent agricultural region in northwest Bangladesh. Hydrol. Res. Lett.
**2017**, 11, 85–91. [Google Scholar] [CrossRef] [Green Version] - Bayatvarkeshi, M.; Zhang, B.; Fasihi, R.; Adnan, R.M.; Kisi, O.; Yuan, X. Investigation into the Effects of Climate Change on Reference Evapotranspiration Using the HadCM3 and LARS-WG. Water
**2020**, 12, 666. [Google Scholar] [CrossRef] [Green Version] - U.S. Geological Survey. Available online: https://www.usgs.gov/special-topic/water-science-school/science/a-comprehensive-study-natural-water-cycle?qt-science_center_objects=0#qt-science_center_objects (accessed on 18 January 2021).
- Alizamir, M.; Kisi, O.; Adnan, R.M.; Kuriqi, A. Modelling reference evapotranspiration by combining neuro-fuzzy and evolutionary strategies. Acta Geophys.
**2020**, 68, 1113–1126. [Google Scholar] [CrossRef] - Yuan, X.; Chen, C.; Lei, X.; Yuan, Y.; Adnan, R.M. Monthly runoff forecasting based on LSTM–ALO model. Stoch. Environ. Res. Risk Assess.
**2018**, 32, 2199–2212. [Google Scholar] [CrossRef] - Donkor, E.A.; Mazzuchi, T.A.; Soyer, R.; Roberson, J.A. Urban Water Demand Forecasting: Review of Methods and Models. J. Water Resour. Plan. Manag.
**2014**, 140, 146–159. [Google Scholar] [CrossRef] - Chen, J.; Boccelli, D.L. Forecasting Hourly Water Demands with Seasonal Autoregressive Models for Real-Time Application. Water Resour. Res.
**2018**, 54, 879–894. [Google Scholar] [CrossRef] - Muhammad Adnan, R.; Yuan, X.; Kisi, O.; Yuan, Y.; Tayyab, M.; Lei, X. Application of soft computing models in streamflow forecasting. In Proceedings of the Institution of Civil Engineers-Water Management; Thomas Telford Ltd.: London, UK, 2019; Volume 172, No. 3. pp. 123–134. [Google Scholar]
- Gujarati, D.N. Basic Econometrics; Tata McGraw-Hill Education: New York, NY, USA, 2009. [Google Scholar]
- Adnan, R.M.; Liang, Z.; Yuan, X.; Kisi, O.; Akhlaq, M.; Li, B. Comparison of LSSVR, M5RT, NF-GP, and NF-SC Models for Predictions of Hourly Wind Speed and Wind Power Based on Cross-Validation. Energies
**2019**, 12, 329. [Google Scholar] [CrossRef] [Green Version] - Kisi, O.; Shiri, J.; Karimi, S.; Adnan, R.M. Three different adaptive neuro fuzzy computing techniques for forecasting long-period daily streamflows. In Big Data in Engineering Applications; Springer: Singapore, 2018; pp. 303–321. [Google Scholar]
- Lütkepohl, H. Vector autoregressive models. In Handbook of Research Methods and Applications in Empirical Macroeconomics; Edward Elgar Publishing: Camberley, UK, 2013. [Google Scholar] [CrossRef] [Green Version]
- Mehmood, A.; Jia, S.; Lv, A.; Zhu, W.; Mahmood, R.; Saifullah, M.; Adnan, R.M. Detection of Spatial Shift in Flood Regime of the Kabul River Basin in Pakistan, Causes, Challenges, and Opportunities. Water
**2021**, 13, 1276. [Google Scholar] [CrossRef] - Mitchell, T.M. The Discipline of Machine Learning; Carnegie Mellon University, School of Computer Science, Machine Learning Department: Pittsburgh, PA, USA, 2006; Volume 9. [Google Scholar]
- Provost, F. Machine learning from imbalanced data sets 101. In Proceedings of the AAAI’2000 Workshop on Imbalanced Data Sets; AAAI Press: Palo Alto, CA, USA, 2000; pp. 1–3. [Google Scholar]
- Vellido, A.; Martin-Guerrero, J.D.; Lisboa, P.J.G. Making machine learning models interpretable. In Proceedings of the ESANN, European Symposium on Artificial Neural Networks, Computational Intelligence and Machine Learning, Bruges, Belgium, 25–27 April 2012; Volume 12, pp. 163–172. [Google Scholar]
- Groenen, I. Master Thesis: Representing Seasonal Patterns in Gated Recurrent Neural Networks for Multivariate Time Series Forecasting. 2018. Not Yet Online; Confidential. Available online: http://www.scriptiesonline.uba.uva.nl/657906 (accessed on 20 October 2018).
- Bontsema. Master Thesis: Forecasting Ammonium Concentration in Wastewater Treatment Plant. 2018. Available online: https://beta.vu.nl/nl/onderwijs/project-en-stage/stagebureau-wiskunde-informatica/master-project-ba/stageverslagen-online/index.aspx (accessed on 25 January 2021).
- Adnan, R.M.; Liang, Z.; El-Shafie, A.; Zounemat-Kermani, M.; Kisi, O. Prediction of Suspended Sediment Load Using Data-Driven Models. Water
**2019**, 11, 2060. [Google Scholar] [CrossRef] [Green Version] - LeCun, Y.; Bengio, Y.; Hinton, G. Deep learning. Nature
**2015**, 521, 436–444. [Google Scholar] [CrossRef] [PubMed] - Xiang, Z.; Yan, J.; Demir, I. A Rainfall-Runoff Model with LSTM-Based Sequence-to-Sequence Learning. Water Resour. Res.
**2020**, 56, 1. [Google Scholar] [CrossRef] - Elsheikh, A.H.; Katekar, V.P.; Muskens, O.L.; Deshmukh, S.S.; Elaziz, M.A.; Dabour, S.M. Utilization of LSTM neural network for water production forecasting of a stepped solar still with a corrugated absorber plate. Process. Saf. Environ. Prot.
**2021**, 148, 273–282. [Google Scholar] [CrossRef] - Barzegar, R.; Aalami, M.T.; Adamowski, J. Short-term water quality variable prediction using a hybrid CNN–LSTM deep learning model A Short-Term Data Based Water Consumption Prediction Approach. Stoch. Environ. Res. Risk Assess.
**2020**, 34, 1–19. [Google Scholar] [CrossRef] - Xu, Z.; Ying, Z.; Li, Y.; He, B.; Chen, Y. Pressure prediction and abnormal working conditions detection of water supply network based on LSTM. Water Supply
**2020**, 20, 963–974. [Google Scholar] [CrossRef] - McCracken, M.W.; McGillicuddy, J.T. An empirical investigation of direct and iterated multistep conditional forecasts. J. Appl. Econ.
**2019**, 34, 181–204. [Google Scholar] [CrossRef] - Zhao, J.; Mu, X.; Gao, P. Dynamic response of runoff to soil and water conservation measures and precipitation based on VAR model. Hydrol. Res.
**2019**, 50, 837–848. [Google Scholar] [CrossRef] - Keng, C.Y.; Shan, F.P.; Shimizu, K.; Imoto, T.; Lateh, H.; Peng, K.S. AIP Conference Proceedings Application of vector autoregressive model for rainfall and groundwater level analysis. In Proceedings of the 24th National Symposium on Mathematical Sciences: Mathematical Sciences Exploration for the Universal Preservation, Kuala Terengganu, Malaysia, 27–29 September 2016. [Google Scholar] [CrossRef]
- Hartini, S.; Hadi, M.P.; Sudibyakto, S.; Poniman, A. Application of Vector Auto Regression Model for Rainfall-River Discharge Analysis. Forum Geogr.
**2015**, 29, 1–10. [Google Scholar] [CrossRef] [Green Version] - Pradhan, R.P.; Bagchi, T.P. Effect of transportation infrastructure on economic growth in India: The VECM approach. Res. Transp. Econ.
**2013**, 38, 139–148. [Google Scholar] [CrossRef] - Honkatukia, J.; Malkonen, V.; Perrels, A. Impacts of the European Emissions Trade System on Finnish Wholesale Electricity Prices; Government Institute for Economic Researchs: Helsinki, Finland, 2006. [Google Scholar]
- Fell, H. EU-ETS and Nordic Electricity: A CVAR Analysis. Energy J.
**2010**, 31, 1–25. [Google Scholar] [CrossRef] [Green Version] - Chemarin, S.; Heinen, A.; Strobl, E. Electricity, Carbon and Weather in France: Where do We Stand? Ecole Polytechnique, Centre National de la Recherche Scientifique: Paris, France, 2008. [Google Scholar]
- Thoenes, S. Understanding the Determinants of Electricity Prices and the Impact of the German Nuclear Moratorium; Institute of Energy Economics at the University of Cologne (EWI): Cologne, Germeny, 2011. [Google Scholar]
- Loves, L.; Usman, M.; Russel, E. Modeling Multivariate Time Series by Vector Error Correction Models (VECM) (Study: PT Kalbe Farma Tbk. and PT Kimia Farma (Persero) Tbk). In Journal of Physics: Conference Series; IOP Publishing: Bristol, UK, 2021. [Google Scholar] [CrossRef]
- Enders, W. Applied Econometric Time Series; John Wiley and Sons Interscience Publication: Hoboken, NJ, USA, 2015. [Google Scholar]
- Asteriou, D.; Hall, S.G. Applied Econometrics: A Modern Approach; Palgrave Macmillan: New York, NY, USA, 2007. [Google Scholar]
- Lutkepohl, H. New Introduction to Multiple Time Series Analysis; Springer: Heidelberg, Germany, 2005. [Google Scholar]
- Duan, Y.; Lv, Y.; Wang, F. Travel time prediction with LSTM neural network. In Proceedings of the IEEE 19th International Conference on Intelligent Transportation Systems (ITSC), Rio de Janeiro, Brazil, 1–4 November 2016; pp. 1053–1058. [Google Scholar] [CrossRef]
- MAE and RMSE—Which Metric Is Better?-Human in Machine World, Medium. 2016. Available online: https://medium.com/human-in-a-machine-world/mae-and-rmse-which-metric-is-better-e60ac3bde13d (accessed on 25 February 2021).
- Tayyab, M.; Zhou, J.; Zeng, X.; Zhao, N.; Adnan, R. Integrated Combination of the Multi Hydrological Models by Applying the Least Square Method. Res. J. Appl. Sci. Eng. Technol.
**2015**, 10, 107–111. [Google Scholar] [CrossRef] - Tayyab, M.; Zhou, J.; Adnan, R.; Meng, C.; Zahra, A. Streamflow Prediction by Applying Generalized Regression Network with Time Series Decomposition Method. Indones. J. Electr. Eng. Comput. Sci.
**2016**, 4, 611–616. [Google Scholar] [CrossRef] - Yuan, X.; Tian, H.; Yuan, Y.; Huang, Y.; Ikram, R.M.A. An extended NSGA-III for solution multi-objective hydro-thermal-wind scheduling considering wind power cost. Energy Convers. Manag.
**2015**, 96, 568–578. [Google Scholar] [CrossRef] - Adnan, M.; Nabi, G.; Kang, S.; Zhang, G.; Adnan, R.M.; Anjum, M.N.; Iqbal, M.; Ali, A.F. Snowmelt Runoff Modelling under Projected Climate Change Patterns in the Gilgit River Basin of Northern Pakistan. Pol. J. Environ. Stud.
**2017**, 26, 525–542. [Google Scholar] [CrossRef] - Adnan, R.M.; Parmar, K.S.; Heddam, S.; Shahid, S.; Kisi, O. Suspended Sediment Modeling Using a Heuristic Regression Method Hybridized with Kmeans Clustering. Sustainability
**2021**, 13, 4648. [Google Scholar] [CrossRef]

Aquifer | VAR | LSTM | ||||
---|---|---|---|---|---|---|

Steps | RMSE (m) | MAE (m) | RMSE (m) | MAE (m) | ||

Auser | 1-day | 0.0516 | 0.0374 | Before scaling | 0.1516 | 0.1129 |

7-day | 0.0457 | 0.0389 | After scaling | 0.2089 | 0.1640 | |

14-day | 0.0583 | 0.0490 | ||||

Doganella | 1-day | 0.6030 | 0.1732 | Before scaling | 0.3875 | 0.2525 |

7-day | 0.1540 | 0.1255 | After scaling | 1.7477 | 1.3480 | |

14-day | 0.2257 | 0.1912 | ||||

Luco | 1-day | 0.466 | 0.0311 | Before scaling | 0.0843 | 0.0647 |

7-day | 0.0577 | 0.0430 | After scaling | 0.0464 | 0.0356 | |

14-day | 0.0394 | 0.0264 | ||||

Petrignano | 1-day | 0.1004 | 0.0729 | Before scaling | 0.0319 | 0.0256 |

7-day | 0.2999 | 0.2919 | After scaling | 0.2346 | 0.1884 | |

14-day | 0.2709 | 0.2276 |

Lake | Steps | VAR | LSTM | |||
---|---|---|---|---|---|---|

RMSE (m/s) | MAE (m/s) | RMSE (m/s) | MAE (m/s) | |||

Blancino | 1-day | 0.8862 | 0.3404 | Before scaling | 0.0585 | 0.0388 |

7-day | 0.1205 | 0.1096 | After scaling | 1.1897 | 0.7056 | |

14-day | 0.1081 | 0.0894 |

River | Steps | VAR | LSTM | |||
---|---|---|---|---|---|---|

RMSE (m) | MAE (m) | RMSE (m) | MAE (m) | |||

Arno | 1-day | 0.1172 | 0.0731 | Before scaling | 0.0582 | 0.0436 |

7-day | 0.0486 | 0.0441 | After scaling | 0.1358 | 0.1017 | |

14-day | 0.0686 | 0.0657 |

Water Spring | Steps | VAR | VECM | |||
---|---|---|---|---|---|---|

RMSE (m/s) | MAE (m/s) | RMSE (m/s) | MAE (m/s) | |||

Amiata | Flow_Rate_Bugnano | 1-day | 0.0383 | 0.0304 | 0.0112 | 0.007 |

7-day | 0.0306 | 0.0274 | 0.0138 | 0.010 | ||

14-day | 0.0253 | 0.0238 | 0.0153 | 0.012 | ||

Flow_Rate_Arbure | 1-day | 0.0222 | 0.0157 | 0.0825 | 0.0546 | |

7-day | 0.0506 | 0.0422 | 0.0904 | 0.676 | ||

14-day | 0.0952 | 0.0889 | 0.0938 | 0.075 | ||

Flow_Rate_Ermicciolo | 1-day | 0.3136 | 0.2942 | 0.1591 | 0.1221 | |

7-day | 0.1779 | 0.1477 | 0.1907 | 0.1538 | ||

14-day | 0.0966 | 0.0845 | 0.2092 | 0.1726 | ||

Flow_Rate_Gallaria_Alta | 1-day | 0.1971 | 0.1264 | 0.6151 | 0.4048 | |

7-day | 0.4927 | 0.3748 | 0.727 | 0.5307 | ||

14-day | 0.8950 | 0.8185 | 0.7609 | 0.6057 | ||

Lupa | Flow_rate_Lupa | 1-day | 0.4206 | 0.0944 | 0.4233 | 0.0941 |

7-day | 1.4715 | 0.5708 | 1.4715 | 0.5699 | ||

14-day | 2.4280 | 1.2444 | 2.4270 | 1.2439 | ||

Madonna-Di-Canetto | Flow_rate_Madonna-di-canneto | 1-day | 9.5089 | 5.396 | 11.6846 | 6.4348 |

7-day | 14.0742 | 10.3333 | 12.8215 | 8.9599 | ||

14-day | 13.0118 | 10.9436 | 12.0066 | 9.6939 |

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |

© 2021 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 (CC BY) license (https://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Kaur, H.; Alam, M.A.; Mariyam, S.; Alankar, B.; Chauhan, R.; Adnan, R.M.; Kisi, O.
Predicting Water Availability in Water Bodies under the Influence of Precipitation and Water Management Actions Using VAR/VECM/LSTM. *Climate* **2021**, *9*, 144.
https://doi.org/10.3390/cli9090144

**AMA Style**

Kaur H, Alam MA, Mariyam S, Alankar B, Chauhan R, Adnan RM, Kisi O.
Predicting Water Availability in Water Bodies under the Influence of Precipitation and Water Management Actions Using VAR/VECM/LSTM. *Climate*. 2021; 9(9):144.
https://doi.org/10.3390/cli9090144

**Chicago/Turabian Style**

Kaur, Harleen, Mohammad Afshar Alam, Saleha Mariyam, Bhavya Alankar, Ritu Chauhan, Rana Muhammad Adnan, and Ozgur Kisi.
2021. "Predicting Water Availability in Water Bodies under the Influence of Precipitation and Water Management Actions Using VAR/VECM/LSTM" *Climate* 9, no. 9: 144.
https://doi.org/10.3390/cli9090144