# Forecasting Methods in Various Applications Using Algorithm of Estimation Regression Models and Converting Data Sets into Markov Model

Authors: Mohammed M. El Genidy; Mokhtar S. Beheary
Journal: Complexity
 (2022)

---

## Abstract

Water quality control helps in the estimation of water bodies and detects the span of pollutants and their effect on the neighboring environment. This is why the water quality of the northern part of Lake Manzala has been studied here from January to March, 2016. This study aims to model and create a program for linear and nonlinear regression of the water elements in Lake Manzala to assess and predict the water quality. Water samples have been extracted from various depths, and physio-chemical properties and heavy metal concentrations have been evaluated. This study has proposed a new algorithm for predicting water quality called “Algorithm of Estimation Regression Model” (AERM). On the contrary, in renewable energy applications, statistical modeling and forecasting the solar radiation remains a significant issue with detect to reinforce power management. A new proposed method for forecasting the average Monthly Global Solar Energy (MGSE) in Queensland, Australia, is called, Converting Data Set into Markov Model (CDMM). It was used to obtain Markov transition probability matrices for three and six states of the solar energy. The proposed forecasting method yielded accurate results with minimal error.


---

## Body

## 1. Introduction

Adequate amounts of suitable-quality water resources provide a precondition for economic development and ecological integrity. Numerous stresses influence water quality, such as natural processes (e.g., weathering, precipitation, and soil erosion), anthropogenic activities (e.g., agricultural, urban, and industrial activities), and the increased utilization of water resources. Because of multifaceted effects noted above, water quality deterioration has become a serious issue worldwide as Wu et al. and Qin et al. emphasized [1, 2].In recent years, Elkady et al. showed that Lake Manzala could have been recorded as the largest and the most productive Lake of the northern Egyptian coastal lakes [3]. It is a shallow, brackish-water lake located on the northeastern edge of the Nile Delta between Port Said and the Suez Canal eastwards and the Damietta brink of the Nile westwards. It is an important natural resource for fish catch, wildlife, hydrologic and biologic regimes, and table salt production. Lake Manzala is characterized by special sensitive environments.The lake has declined in area over the last two decades, reaching 700 km2 in 2003, as mentioned by Ali [4]. The lake has five major drains which carry agricultural drainage water as well as waste water from urban areas. It crosses the Delta and discharges into the southern, eastern, and western parts of the Lake Manzala, as discussed by Abukila, Khadr, and Elshemy [5, 6].It is also essential to enhance water quality because it plays a pivotal role in ecological and human health and in economic development. Based on information from assessments, the public is more likely to implement a protective measure that improves the conditions of water bodies, studied by Jiang et al. and Sousa et al. [7, 8].In this study, estimation of water quality using regression models has been applied to assess the water quality and its spatial variations in Lake Manzala. The primary objectives of this study are to determine the water quality status, whereby its spatial variation across the study area and to explore the critical parameters in the development of a statistical model for simple and cost-effective water quality evaluation. The performance of the statistical model will improve with full consideration of parameter estimation.Several researchers have developed monthly mean global solar radiation models that include classical empirical regression, artificial neural networks (ANNs), and time-series regression techniques, auto regression moving average (ARMA), and empirical correlation to estimate the monthly mean daily global solar radiation (GSR). Researchers have faced serious difficulties in modeling, estimating, and obtaining the prediction equation of meteorological data like the solar energy amount and the corresponding maximum temperature. A variety of methods for estimating global solar exposure have been published using empirical correlations. A model was proposed depending on the statistic properties of hourly global radiation with a variety of parameters. It represents an accurate understanding of hourly solar radiation, performed by Aguiar and Collares-Pereira [9].Almost all approaches used applied forecasting parameters such as period of sunlight, temperature degree, and moisture. Methods must therefore include more than two parameters to obtain reliable tests, which can carry more complex and higher computational error risks. Relying on their ability to make statistical decisions, they have noticed that the sampling method turns into statistical inference methods. Thus, they need to select the appropriate statistical inference method for the terminal objective of the significant study. Here lies the importance of the estimation method.The development of pattern similarity in solar radiation estimation is presented in the clustering algorithm and its application. For the extraction of shape-based clusters from the input meteorological parameters, the continuous-density hidden Markov model (HMM) with Pearson’sR model is used and then processed by the generalized fuzzy model (GFM) to accurately estimate solar radiation. The patterns of the data vectors are used as the similarity index for clustering instead of using distance function as an index of similarity. Here, which overcomes few of the drawbacks associated with distance-based approaches to clustering.The method of estimation used here exploits the HMM’s pattern recognition prowess for the collection and generalization of clusters and the GFM’s nonlinear modeling capabilities in forecast the solar radiation. The proposed model is applied to 15 different classifications of various combinations of meteorological parameters, applied by Bhardwaj et al. [10]. As standard practice is to use acceptable empirical correlations to estimate the average daily global solar radiation based on the applicable data measured at those locations. For few regions, there are no real calculated values, and these correlations estimate the values of meteorological data for a region of investigation from more widely accessible meteorological, climatology, and geographical parameters.Some researchers show an interest to collect and study the comprehensive global models of solar radiation available in the literature chronologically. In addition, to identify them into four groups, such as sunshine-based, cloud-based, temperature-based, as well as other meteorological parameter-based models, depending on the meteorological parameters used as model data, showed by Besharat et al. [11]. The artificial neural network (ANN) is used to identify effective methods available for solar radiation prediction in the literature and to identify research gaps. In contrast to traditional approaches, artificial neural network techniques forecast solar radiation more accurately. The prediction accuracy of an ANN model is found to be based on the combination of input parameters, training algorithms, and configuration of architecture, carried out by Yadav and Chandel [12].In particular, artificial neural network was performed to predict the direction movement of financial time series. The resilient back-propagation learning procedure was suggested for training a single-layer feed-forward neural netwo. The data set of the network was 15 indicators, and the single output of the daily stock closing price takes the value of either 0 or 1. Whereby, 0 indicates that the daily closing stock price index for the next day is lower than today’s price and 1 means that it is higher. If the output value ≥0.5, the prediction of direction movement is considered upward, and if it is less than 0.5, it is considered downward [13].It is clear from this previous study that it was based only on two states in the output, namely, zero and one, in which the stock exchange is closed, and the prediction will be on the next day of closing the stock exchange. In addition, this method needs to improve the parameter values of neural networks, which leads to the creation of complex algorithms. On the contrary, this study was to obtain a prediction using Markov models for three states of solar radiation in addition other six states for each month during the successive years and do not only predict the next state for once, nor only two states “0” and “1” like in the previous study.In addition, it is possible to create a program that is not as complicated as the one in the previous study, and the accuracy can be increased by increasing the number of states, and it does not need to improve any parameters or indicators, as is the case in the previous study.On the contrary, the prediction for various drought classes using spatiotemporal categorical sequences relied on the forecasting method on drought data for the interval from 1971 to 2017, which were divided into six cases while they used only one optimal probability distribution named three-parameter Weibull distribution for all drought data during (1971–2017) in a specific region where there is a monitoring station named Astore station with time scale equal one. In addition, the logistic regression model was considered to compute the probability of drought persistence from one season to the next one to survey the seasonal drought frequency and drought persistence in the northern area of Pakistan [14, 15].Therefore, the aforementioned studies relied on the prediction method during the months of the same year, with a single probability distribution for all data. While the droughts during the different months are considered independent, which leads to prediction error and inaccuracy, they did not calculate the estimation error in the forecast. As they did not show that the sum of the state probabilities in each column in the transition matrix equal one using three-parameter Weibull, it is known that each column in the transition matrix will be represented by a single distribution due to the different transition states for each column. For this reason, the paper should study the drought classes for each month separately during consecutive years. Each month should be represented by a transition matrix which represents the transition states during successive years to predict the state of each month more accurately.It is remarkable that the effects of component parameters from the mixing stage on the manufactured results of Li-ion battery electrode via classification modeling has been studied. As suggested, an effective RUBoost-based ensemble learning framework to recover for category imbalance case and good classification of three key quality indicators for both LiFePO4- and Li4Ti5O12-based electrodeIn another previous study, a random forest (RF)-based classification framework, using the out-of-bag (OOB) predictions for effective quantification the importance of battery manufacturing advantages [16, 17].While the prediction in this study was related to the field of natural resources in water quality by estimating its components in the different depths of the lakes, which have not been measured before, the sample is limited and has a high dispersion. There is always a need for a large sample size of water element measurements to be represented graphically by functions of probability distributions containing three parameters: shape, scale, and location. Thus, the probabilities of the outliers of the elements can be predicted, as well as the skewness and kurtosis and the measurement range of each element in the water at different depths. The application of the AERM algorithm is very possible in the manufacture of batteries and that is on the measurement points of each of the lifetime and corresponding battery voltage. Therefore, the battery voltage values can be represented by a cumulative probability distribution function that contains three parameters, and it is of great importance in increasing the lifetime and reliability and reducing the failure rate of the battery.It was also recorded that an algorithm is called the advanced proximal policy optimization (PPO) reinforcement learning was used to improve speed control of the model-free quadrotor. It was used for acquired neural networks to determine the states of the command control system in an end-to-end style. In addition, it has been suggested as an adaptive neural network (NN) distributed control algorithm for a group of high-order nonlinear agents with nonidentical unknown control directions (UCDs) under signed time-varying topologies [18, 19].In this study, AERM’s algorithm determined the unknown readings at various other depths of the lake, which were not measured by water element analyzers. In addition, the sample is limited and has high dispersion. AERM’s algorithm accurately estimates the unknown readings by controlling the values ofR-square (R2), the total sum of squares (SST), the regression sum of squares (SSR), and the error sum of squares (SSE). Nonetheless, AERM algorithm can be applied on four acquired neural networks to obtain a larger number of estimations of other unknown states of the command control system. For this reason, AERM algorithm may reduce time, cost, and effort in obtaining other unknown states or measurements of the command control system. In contrast with the method of CDMM dealing with a lot of size measurements, the aim was to convert these measurements to a limited number of states. Thus, the idea of CDMM method can also be used on the control systems, which have a large number of different measurements.


## 2. Complex Forecasting Science

### 2.1. Why Complex Forecasting Science?

Complex forecasting science considered on sampling and analysis of data sets for different applications such as water quality and solar energy. In this study, a new estimation method called algorithm of estimation regression model (AERM) was implemented to evaluate the water elements in the lake. This algorithm was characterized by its high accuracy more than the estimation methods found in the previous studies.The eastern part of Lake Manzala is separated from the Mediterranean Sea by a sandy beach ridge and is isolated from the main lake by a coastal road. The study area receives its feed from the Mediterranean Sea through El-Gamil and El Mussallas inlets and accepts drainage water from Ezbet El Borg drain. Extracted water samples from various depths in Lake Manzala in Egypt, physio-chemical properties, and heavy metal concentrations have been evaluated, and all sampling sites are displayed in Figure1, which presents 12 different sampling sites of Lake Manzala in Egypt for water quality, studied by Beheary and El-Matary [20].Figure 1
Sampling sites from Lake Manzala, Egypt.This study has been based on a data set of 18 parameters, measured three times from January to March 2016, at 12 sampling sites that cover the northern part of Lake Manzala at the fish farming area called El Mussallas (see Figure1). Sampling locations have been identified using global positioning system (GPS), while water samples have been analyzed in the field using multiparameter water quality probe (Aqua Prob. AP-2000) for Depth (m), Temp (C), PH, ORP (REDOX), DO (mg/L), EC (uS/cm @25°C), RES (Ohms.cm), TDS (mg/L), SAL (PSU), and SSG (st). According to APHA, water samples were brought to the laboratory and analyzed for TN (mg/L), COD (mg/L), and total phosphorous (mg/L).UNEP/IAEA showed that the total heavy metal in water was measured as follows. An exact 100 mL of the sample is to be placed into a beaker, then 5 mL concentrated HNO3 is to be added. That is to be carefully boiled on a hot plate or a steam bath until it evaporates down to about 20 mL. Then, a further 5 mL concentrated HNO3 is to be added and covered with a watch glass to be heated this way. The process of adding and heating concentrated HNO3 is to continue until the solution appears colored light and clear. This sign indicates that digestion is complete, yet drying is not allowed during the digestion. About 1to 2 mL concentrated HNO3 is to be added and slightly heated to dissolve any remaining residue. The beaker walls are to be carefully washed down. Then, the entire content is to be poured into a 50 mL volumetric flask to cool. This is how all digested solutions have been analyzed for heavy metal (Cu, Cd, Pb, Zn, and Fe) using an atomic absorption spectrophotometer (Shimadzu AA-6800), and the results are canonically expressed as mg/L.Water samples have been extracted from various depths of the northern part of Lake Manzala. Then, their physio-chemical properties and heavy metal concentrations of Cu, Cd, Pb, Zn, and Fe have been estimated. Their respective mean estimations are sorted out in a tabular form to show how they differ at various depths ranging from 0.13 to 2.5 m. The values of these estimates are presented in Table1, where (1) refers to the actual values of the elements in Lake Manzala, pH: potential of hydrogen, ORP: oxidation reduction potential, DO: dissolved oxygen, EC: electrical conductivity, RES: RESISTIVITY, TDS: total dissolved solids, SAL: SALINITY, SSG: seawater specific gravity, TN: total nitrogen, COD: chemical oxygen demand, PO4: total phosphorous, cd: cadmium, cu: copper, zn: zinc, pb: lead, fe: iron, Temp: temperature, C: degree Celsius, mg/L: milligrams per litre.Table 1
Actual values of water elements at different depths of lake.
Depth (m)0.130.290.30.310.330.381.341.522.5Temp1 (°C)22.122.222.83322.621.822.319.920.720.220.7pH18.548.517.1538.699.098.378.427.928.118.72ORP1 (REDOX)−50.549.7171.740.58−7.4−152.8−208.5−141.2−9.6DO1 (mg/L)14.610.868.9410.3411.297.738.013.054.438.95EC1uS/cm@25°C63,01752,89331,849.6765,33335,21863,79264,53753,45043,87958,426RES1 (Ohms·cm)16192216301617202518TDS1 (mg/L)40,33033,85142,860.6741,81322,53940,82641,30334,20828,08237,392SAL1 (PSU)42.5234.8422.15344.2922.1643.143.735.2628.2739SSG1 (st)30.924.914.732.115.131.332.325.520.228.4TN1 (mg/L)50.464.468.6497044.8135.860.2162.465.8COD1 (mg/L)47526001474.3331252550575123207011501425Total pH.1 (mg/L)0.0790.0090.190.0530.0830.2330.0330.0330.0090.056cd10.0390.0370.0230.0370.0410.0390.0320.030.0370.037cu10.0790.0740.0620.0740.0830.0850.0710.0680.0730.076zn10.0620.0330.0330.0320.0360.0410.0310.0370.040.038pb10.0120.0070.0070.0060.0070.010.0060.0070.0080.008fe10.7290.4870.5290.5591.0380.9860.4750.3420.9010.472In this section, the statistical regression equation of the water quality has been performed to evaluate the water quality and its spatial variations in Lake Manzala. The prediction programs are a promising solution that could aptly be used to control the water quality of lakes insofar as real estimations of some specific locations.In Queensland (Terrey Hills)-Australia, the annual solar energy map shows a higher energy of the south coastal regions to central and northern Australia with a lower solar energy. Inland Australia areas have a lower humidity in the air and thus less cloud cover. The data set used in this study included yearly global solar energy average (YGSEA). Climate data over 30 years in Queensland, Australia. It was actual and reliable data, as they are recorded by the Bureau of Meteorology in Australian government. Figure2 indicates yearly global solar energy average (GSEA) in 30 years successively.Figure 2
Yearly global solar energy average in Queensland, Australia.On the contrary, the largest amount of solar energy in Queensland, Australia, is distributed over January, February, September, October, November, and December. The month with the largest amount of solar energy. January and June are the months with the lowest amount of solar energy as indicated in Figure3. The percentages of each month over 30 years are shown in Figure 4.Figure 3
Monthly global solar energy average in Queensland, Australia.Figure 4
Yearly global solar energy percentage in Queensland, Australia.Typical values for daily global solar exposure range from 1 to 35 MJ/m2 (mega joules per square meter) and are usually highest in clear sky conditions during the summer and lowest during the winter or very cloudy days.


### 2.2. What Is Complexity?

This study attempts to estimate the values of water elements at various depths during significant time span. This is performed with the least unavoidable error rate at different values of depth.The depth points were divided into two or more points, and the regression model was derived for each interval of water depth depending on the error sum of squares (SSE) and adjustedR-square. In effect, these procedures produced high accurate estimates of water elements at various depths, and a computer program was created to calculate them.


### 2.3. Complexity Solution

For this reason, the algorithm of estimation regression models (AERMs) was created to estimate the regression model. It was implemented on the computer to evaluate the parameters of regression models. Consequently, the values of water elements in the different depths of the lake were obtained with high accuracy.


### 2.4. Why Data Set of Solar Energy May Be Complex?

Many data sets have high dispersion or big size such as data set of solar energy through years. For this reason, we supposed thatX(t) is a stochastic process, where X is a continuous random variable which represents the amount of solar energy with a discrete time, t representing the day. Markov transition probability pij represents transferring the state i to the state j, whereby X(t) satisfies Markov property.(1)PXt+1=j|Xtit,Xt−1=it−1,…,X0=i0=PXt+1=j|X0=i0=Pi,j,PXt+1=j|Xt=it,Xt−1=it−1,…,X0=i0=pXt+1∩X0∩X1∩⋯∩Xt−2∩Xt−1∩XtpX0,X1,…,Xt,=PXt+1|Xt.pXt−1.pXt−2,…,pX1.pX0pX0.pX1,…,pXt−1,=PXt+1|Xt=PXt+1=j|Xt=it=i=Pij.Thus,Xt+1 depends only on the current state Xt, without knowing all history of states X0,X1,…,Xt−1. Transition matrix P shows the transitions between different states. It was used for forecasting the monthly global solar energy (MGSE).(2)P=X1,1X1,2…………X1,12X2,1X2,2…………X2,12⋮⋮⋮⋮⋮⋮⋮⋮X12,1X12,2…………X12,12.The probability of the predicted values for the 12 months of next year is by multiplying the vector of current states by the transition matrixP, whereby Y presents the vector of the probabilities of states in the next year.(3)Y=X1X2…X12X1,1X1,2…………X1,12X2,1X2,2…………X2,12⋮⋮⋮⋮⋮⋮⋮⋮X12,1X12,2…………X12,12.In this study, a new statistical method called converting data set to Markov model (CDMM) is produced to give an accurate prediction of the monthly average of global solar exposure giving the probabilities transition matrix. Software programs Mathematica, SPSS, and Excel were used to fulfill the research requirements, evaluate the calculations, and extract the numerical results. In addition, nonparametric tests were applied for validity results with the actual data.


### 2.5. Processing Missing Data Set of Solar Energy

There was a missing value in the month of December, 2005. Through the method of regression for December values for 30 years with the principle of Markov, the future value depends only on the current value; two points before the missing point and two points after it was used to estimate the approximating curve to predict the missing point as shown in Figure5. The best-fitting curve of the data set in December is shown in Figure 5.Figure 5
Best-fitting regression curve of MSEA in December, Queensland, Australia.Consequently, the nonlinear regression equation (y = 0.4583x3–22.536x2 + 367.43x − 1963.4) was obtained, whereby R-square = 1, x is the rank of the year in 26 years from 1990 to 2019, and y is the global solar exposure in December. Therefore, the missing estimated value of y at x = 16 is equal to 23.8 for 2005.


### 2.6. Conversion Data Set of Solar Energy into Markov Model (CDMM)

Suppose thatT¯i,j represents the average temperature for a month (i), i = 1,2,…, 12, in the year (j), j = 1990, 1991,…, 2019. The states of the temperature T¯i,j for each month (i) are low (a ≤ Ti¯ < b), medium (b ≤ Ti¯ < c), and high (Ti¯ ≥ c), where a, b, and c are constant temperatures for all months. Then, the number of the transition states of the average temperature T¯i,j for each month (i) can be calculated separately from 1990 to 2019. Thus, the probabilities of transition states and the probability of each state for each month (i) during 1990 to 2019 were obtained, respectively. As a result, the electrical energy corresponding to the cases of solar radiation is known, and thus the number of units benefiting from this electrical energy is estimated.For this purpose, data sets can be transformed to fit the Markov model by classifying the solar energy to low (L), medium (M), and high (H). Consequently, there are nine transition probabilities: {p (Xi), p (Yi), p (Zi); i = 1, 2, 3} among three states L, M, and H.(4)X1:L⇒L⟶n⋅LLX2:L⇒M⟶n⋅LMX3:L⇒H⟶n⋅LH↦pX1=n⋅LLn⋅LL+n⋅LH+n⋅LMpX2=n⋅LMn⋅LL+n⋅LH+n⋅LMpX3=n⋅LHn⋅LL+n⋅LH+n⋅LM,Y1:M⇒M⟶n⋅MMY2:M⇒L⟶n⋅MLY3:M⇒H⟶n⋅MH↦pY1=n⋅MMn⋅LL+n⋅LH+n⋅LMpY2=n⋅MLn⋅LL+n⋅LH+n⋅LMpY3=n⋅MHn⋅LL+n⋅LH+n⋅LM,Z1:H⇒H⟶n⋅HHZ2:H⇒L⟶n⋅HLZ3:H⇒M⟶n⋅HM↦pZ1=n⋅HHn⋅HH+n⋅HL+n⋅HMpZ2=n⋅HLn⋅HH+n⋅HL+n⋅HMpZ3=n.HMn⋅HH+n⋅HL+n⋅HM.Then,(5)LMHP=LMHpX1pY2pZ2pX2pY1pZ3pX3pY3pZ1.Figure6 shows that Markov model for the transition states of L, M, and H, whereby the summation of the probabilities of each column in the matrix P is equal to 1. Figure 7 demonstrates the Markov model for six states L, L+, M, M+, H+, and 36 transition states, where L+, M+, and H+ represent the states of solar energy above low, above medium, above high, respectively.Figure 6
Markov model of the solar energy with three states.Figure 7
Markov model of the solar energy for the states (L) L+, (M) M+, and H+.


### 2.7. Joint Probability Function Combined with the Property and Process of Markov Model

Suppose that there are four different transition states for a month in two consecutive years:VI, VJ, VK, and VL and this is for two phenomena: solar radiation (S) and corresponding temperature (T) simultaneously. Both X and Y are continuous random variables represent S and T, respectively, which satisfy the conditions of Markov process and Markov property. The increasing, decreasing, and unchanged amount of the solar radiation for a month in two consecutive years can be represented by X+, X−, and Xo, respectively. Similarly, Y+, Y−, and Yo represent the increasing, decreasing, and unchangeable temperatures for a month in two consecutive years, respectively.LetD¯S refer to the average of different values of X, and D¯T stand for the average of the different values of Y. The four different transition states for a month in two consecutive years can be defined as follows:StateI:(6)pVI=pX<x±D¯S|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sx∓⋅pD¯Ty∓.StateJ:(7)pVJ=pX<x|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sxo⋅pD¯Ty∓.StateK:(8)pVK=pX<x±D¯S|Y<y⋅pY<y⋅pD¯Sx∓⋅pD¯Tyo.StateL:(9)pVL=pX<x|Y<y⋅pY<y⋅pD¯Sxo⋅pD¯Tyo.Then, the joint probability functionF (x, y) will have the following equation:(10)FX<x,Y<y=pVI+pVJ+pVK+pVL=pX<x±D¯S|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sx∓⋅pD¯Ty∓,pX<x|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sxo⋅pD¯Ty∓,pX<x±D¯S|Y<y⋅pY<y⋅pD¯Sx∓⋅pD¯Tyo,pX<x|Y<y⋅pY<y⋅pD¯Sxo⋅pD¯Tyo,whereas I, J, K, and L signify all the different transition states of X and Y for a month in two consecutive years, as follows:(11)I:X±,Y±⟶X∓,Y∓,X±,Y∓⟶X∓,Y±,J:X0,Y±⟶X0,Y∓,K:X±,Y0⟶X∓,Y0,L:X0,Y0⟶X0,Y0.Moreover, the probabilitiespD¯Sx−,pD¯Ty−,pD¯Sx+,pD¯Ty+,pD¯Sxo, and pD¯Tyo are defined as shown below. pD¯Sx− is the probability when x is decreased by D¯S, pD¯Sy− is the probability when y is decreased by D¯S, pD¯Sx+ is the probability when x is increased by D¯S, pD¯Ty+ is the probability when y is increased by D¯T, pD¯Sxo is the probability when x is unchangeable, and pD¯Tyo is the probability when y is unchanged.Remarkably, ifX and Y had the exponentiated Gumbel maximum distribution, then the probability density functions and cumulative distribution functions would be as follows:(12)fZ=z=μγβγe−z/βγe−μγe−z/βγ,z∈−∞;+∞,FZ=z=e−μγe−z/βγ,z∈−∞;+∞,where Z = {X, Y} and corresponding γ = {S, T}, respectively. It is worth mentioning that βS>0andβT>0 are scale parameters and μS>0andμT>0 are shape parameters.


## 2.1. Why Complex Forecasting Science?

Complex forecasting science considered on sampling and analysis of data sets for different applications such as water quality and solar energy. In this study, a new estimation method called algorithm of estimation regression model (AERM) was implemented to evaluate the water elements in the lake. This algorithm was characterized by its high accuracy more than the estimation methods found in the previous studies.The eastern part of Lake Manzala is separated from the Mediterranean Sea by a sandy beach ridge and is isolated from the main lake by a coastal road. The study area receives its feed from the Mediterranean Sea through El-Gamil and El Mussallas inlets and accepts drainage water from Ezbet El Borg drain. Extracted water samples from various depths in Lake Manzala in Egypt, physio-chemical properties, and heavy metal concentrations have been evaluated, and all sampling sites are displayed in Figure1, which presents 12 different sampling sites of Lake Manzala in Egypt for water quality, studied by Beheary and El-Matary [20].Figure 1
Sampling sites from Lake Manzala, Egypt.This study has been based on a data set of 18 parameters, measured three times from January to March 2016, at 12 sampling sites that cover the northern part of Lake Manzala at the fish farming area called El Mussallas (see Figure1). Sampling locations have been identified using global positioning system (GPS), while water samples have been analyzed in the field using multiparameter water quality probe (Aqua Prob. AP-2000) for Depth (m), Temp (C), PH, ORP (REDOX), DO (mg/L), EC (uS/cm @25°C), RES (Ohms.cm), TDS (mg/L), SAL (PSU), and SSG (st). According to APHA, water samples were brought to the laboratory and analyzed for TN (mg/L), COD (mg/L), and total phosphorous (mg/L).UNEP/IAEA showed that the total heavy metal in water was measured as follows. An exact 100 mL of the sample is to be placed into a beaker, then 5 mL concentrated HNO3 is to be added. That is to be carefully boiled on a hot plate or a steam bath until it evaporates down to about 20 mL. Then, a further 5 mL concentrated HNO3 is to be added and covered with a watch glass to be heated this way. The process of adding and heating concentrated HNO3 is to continue until the solution appears colored light and clear. This sign indicates that digestion is complete, yet drying is not allowed during the digestion. About 1to 2 mL concentrated HNO3 is to be added and slightly heated to dissolve any remaining residue. The beaker walls are to be carefully washed down. Then, the entire content is to be poured into a 50 mL volumetric flask to cool. This is how all digested solutions have been analyzed for heavy metal (Cu, Cd, Pb, Zn, and Fe) using an atomic absorption spectrophotometer (Shimadzu AA-6800), and the results are canonically expressed as mg/L.Water samples have been extracted from various depths of the northern part of Lake Manzala. Then, their physio-chemical properties and heavy metal concentrations of Cu, Cd, Pb, Zn, and Fe have been estimated. Their respective mean estimations are sorted out in a tabular form to show how they differ at various depths ranging from 0.13 to 2.5 m. The values of these estimates are presented in Table1, where (1) refers to the actual values of the elements in Lake Manzala, pH: potential of hydrogen, ORP: oxidation reduction potential, DO: dissolved oxygen, EC: electrical conductivity, RES: RESISTIVITY, TDS: total dissolved solids, SAL: SALINITY, SSG: seawater specific gravity, TN: total nitrogen, COD: chemical oxygen demand, PO4: total phosphorous, cd: cadmium, cu: copper, zn: zinc, pb: lead, fe: iron, Temp: temperature, C: degree Celsius, mg/L: milligrams per litre.Table 1
Actual values of water elements at different depths of lake.
Depth (m)0.130.290.30.310.330.381.341.522.5Temp1 (°C)22.122.222.83322.621.822.319.920.720.220.7pH18.548.517.1538.699.098.378.427.928.118.72ORP1 (REDOX)−50.549.7171.740.58−7.4−152.8−208.5−141.2−9.6DO1 (mg/L)14.610.868.9410.3411.297.738.013.054.438.95EC1uS/cm@25°C63,01752,89331,849.6765,33335,21863,79264,53753,45043,87958,426RES1 (Ohms·cm)16192216301617202518TDS1 (mg/L)40,33033,85142,860.6741,81322,53940,82641,30334,20828,08237,392SAL1 (PSU)42.5234.8422.15344.2922.1643.143.735.2628.2739SSG1 (st)30.924.914.732.115.131.332.325.520.228.4TN1 (mg/L)50.464.468.6497044.8135.860.2162.465.8COD1 (mg/L)47526001474.3331252550575123207011501425Total pH.1 (mg/L)0.0790.0090.190.0530.0830.2330.0330.0330.0090.056cd10.0390.0370.0230.0370.0410.0390.0320.030.0370.037cu10.0790.0740.0620.0740.0830.0850.0710.0680.0730.076zn10.0620.0330.0330.0320.0360.0410.0310.0370.040.038pb10.0120.0070.0070.0060.0070.010.0060.0070.0080.008fe10.7290.4870.5290.5591.0380.9860.4750.3420.9010.472In this section, the statistical regression equation of the water quality has been performed to evaluate the water quality and its spatial variations in Lake Manzala. The prediction programs are a promising solution that could aptly be used to control the water quality of lakes insofar as real estimations of some specific locations.In Queensland (Terrey Hills)-Australia, the annual solar energy map shows a higher energy of the south coastal regions to central and northern Australia with a lower solar energy. Inland Australia areas have a lower humidity in the air and thus less cloud cover. The data set used in this study included yearly global solar energy average (YGSEA). Climate data over 30 years in Queensland, Australia. It was actual and reliable data, as they are recorded by the Bureau of Meteorology in Australian government. Figure2 indicates yearly global solar energy average (GSEA) in 30 years successively.Figure 2
Yearly global solar energy average in Queensland, Australia.On the contrary, the largest amount of solar energy in Queensland, Australia, is distributed over January, February, September, October, November, and December. The month with the largest amount of solar energy. January and June are the months with the lowest amount of solar energy as indicated in Figure3. The percentages of each month over 30 years are shown in Figure 4.Figure 3
Monthly global solar energy average in Queensland, Australia.Figure 4
Yearly global solar energy percentage in Queensland, Australia.Typical values for daily global solar exposure range from 1 to 35 MJ/m2 (mega joules per square meter) and are usually highest in clear sky conditions during the summer and lowest during the winter or very cloudy days.


## 2.2. What Is Complexity?

This study attempts to estimate the values of water elements at various depths during significant time span. This is performed with the least unavoidable error rate at different values of depth.The depth points were divided into two or more points, and the regression model was derived for each interval of water depth depending on the error sum of squares (SSE) and adjustedR-square. In effect, these procedures produced high accurate estimates of water elements at various depths, and a computer program was created to calculate them.


## 2.3. Complexity Solution

For this reason, the algorithm of estimation regression models (AERMs) was created to estimate the regression model. It was implemented on the computer to evaluate the parameters of regression models. Consequently, the values of water elements in the different depths of the lake were obtained with high accuracy.


## 2.4. Why Data Set of Solar Energy May Be Complex?

Many data sets have high dispersion or big size such as data set of solar energy through years. For this reason, we supposed thatX(t) is a stochastic process, where X is a continuous random variable which represents the amount of solar energy with a discrete time, t representing the day. Markov transition probability pij represents transferring the state i to the state j, whereby X(t) satisfies Markov property.(1)PXt+1=j|Xtit,Xt−1=it−1,…,X0=i0=PXt+1=j|X0=i0=Pi,j,PXt+1=j|Xt=it,Xt−1=it−1,…,X0=i0=pXt+1∩X0∩X1∩⋯∩Xt−2∩Xt−1∩XtpX0,X1,…,Xt,=PXt+1|Xt.pXt−1.pXt−2,…,pX1.pX0pX0.pX1,…,pXt−1,=PXt+1|Xt=PXt+1=j|Xt=it=i=Pij.Thus,Xt+1 depends only on the current state Xt, without knowing all history of states X0,X1,…,Xt−1. Transition matrix P shows the transitions between different states. It was used for forecasting the monthly global solar energy (MGSE).(2)P=X1,1X1,2…………X1,12X2,1X2,2…………X2,12⋮⋮⋮⋮⋮⋮⋮⋮X12,1X12,2…………X12,12.The probability of the predicted values for the 12 months of next year is by multiplying the vector of current states by the transition matrixP, whereby Y presents the vector of the probabilities of states in the next year.(3)Y=X1X2…X12X1,1X1,2…………X1,12X2,1X2,2…………X2,12⋮⋮⋮⋮⋮⋮⋮⋮X12,1X12,2…………X12,12.In this study, a new statistical method called converting data set to Markov model (CDMM) is produced to give an accurate prediction of the monthly average of global solar exposure giving the probabilities transition matrix. Software programs Mathematica, SPSS, and Excel were used to fulfill the research requirements, evaluate the calculations, and extract the numerical results. In addition, nonparametric tests were applied for validity results with the actual data.


## 2.5. Processing Missing Data Set of Solar Energy

There was a missing value in the month of December, 2005. Through the method of regression for December values for 30 years with the principle of Markov, the future value depends only on the current value; two points before the missing point and two points after it was used to estimate the approximating curve to predict the missing point as shown in Figure5. The best-fitting curve of the data set in December is shown in Figure 5.Figure 5
Best-fitting regression curve of MSEA in December, Queensland, Australia.Consequently, the nonlinear regression equation (y = 0.4583x3–22.536x2 + 367.43x − 1963.4) was obtained, whereby R-square = 1, x is the rank of the year in 26 years from 1990 to 2019, and y is the global solar exposure in December. Therefore, the missing estimated value of y at x = 16 is equal to 23.8 for 2005.


## 2.6. Conversion Data Set of Solar Energy into Markov Model (CDMM)

Suppose thatT¯i,j represents the average temperature for a month (i), i = 1,2,…, 12, in the year (j), j = 1990, 1991,…, 2019. The states of the temperature T¯i,j for each month (i) are low (a ≤ Ti¯ < b), medium (b ≤ Ti¯ < c), and high (Ti¯ ≥ c), where a, b, and c are constant temperatures for all months. Then, the number of the transition states of the average temperature T¯i,j for each month (i) can be calculated separately from 1990 to 2019. Thus, the probabilities of transition states and the probability of each state for each month (i) during 1990 to 2019 were obtained, respectively. As a result, the electrical energy corresponding to the cases of solar radiation is known, and thus the number of units benefiting from this electrical energy is estimated.For this purpose, data sets can be transformed to fit the Markov model by classifying the solar energy to low (L), medium (M), and high (H). Consequently, there are nine transition probabilities: {p (Xi), p (Yi), p (Zi); i = 1, 2, 3} among three states L, M, and H.(4)X1:L⇒L⟶n⋅LLX2:L⇒M⟶n⋅LMX3:L⇒H⟶n⋅LH↦pX1=n⋅LLn⋅LL+n⋅LH+n⋅LMpX2=n⋅LMn⋅LL+n⋅LH+n⋅LMpX3=n⋅LHn⋅LL+n⋅LH+n⋅LM,Y1:M⇒M⟶n⋅MMY2:M⇒L⟶n⋅MLY3:M⇒H⟶n⋅MH↦pY1=n⋅MMn⋅LL+n⋅LH+n⋅LMpY2=n⋅MLn⋅LL+n⋅LH+n⋅LMpY3=n⋅MHn⋅LL+n⋅LH+n⋅LM,Z1:H⇒H⟶n⋅HHZ2:H⇒L⟶n⋅HLZ3:H⇒M⟶n⋅HM↦pZ1=n⋅HHn⋅HH+n⋅HL+n⋅HMpZ2=n⋅HLn⋅HH+n⋅HL+n⋅HMpZ3=n.HMn⋅HH+n⋅HL+n⋅HM.Then,(5)LMHP=LMHpX1pY2pZ2pX2pY1pZ3pX3pY3pZ1.Figure6 shows that Markov model for the transition states of L, M, and H, whereby the summation of the probabilities of each column in the matrix P is equal to 1. Figure 7 demonstrates the Markov model for six states L, L+, M, M+, H+, and 36 transition states, where L+, M+, and H+ represent the states of solar energy above low, above medium, above high, respectively.Figure 6
Markov model of the solar energy with three states.Figure 7
Markov model of the solar energy for the states (L) L+, (M) M+, and H+.


## 2.7. Joint Probability Function Combined with the Property and Process of Markov Model

Suppose that there are four different transition states for a month in two consecutive years:VI, VJ, VK, and VL and this is for two phenomena: solar radiation (S) and corresponding temperature (T) simultaneously. Both X and Y are continuous random variables represent S and T, respectively, which satisfy the conditions of Markov process and Markov property. The increasing, decreasing, and unchanged amount of the solar radiation for a month in two consecutive years can be represented by X+, X−, and Xo, respectively. Similarly, Y+, Y−, and Yo represent the increasing, decreasing, and unchangeable temperatures for a month in two consecutive years, respectively.LetD¯S refer to the average of different values of X, and D¯T stand for the average of the different values of Y. The four different transition states for a month in two consecutive years can be defined as follows:StateI:(6)pVI=pX<x±D¯S|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sx∓⋅pD¯Ty∓.StateJ:(7)pVJ=pX<x|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sxo⋅pD¯Ty∓.StateK:(8)pVK=pX<x±D¯S|Y<y⋅pY<y⋅pD¯Sx∓⋅pD¯Tyo.StateL:(9)pVL=pX<x|Y<y⋅pY<y⋅pD¯Sxo⋅pD¯Tyo.Then, the joint probability functionF (x, y) will have the following equation:(10)FX<x,Y<y=pVI+pVJ+pVK+pVL=pX<x±D¯S|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sx∓⋅pD¯Ty∓,pX<x|Y<y±D¯T⋅pY<y±D¯T⋅pD¯Sxo⋅pD¯Ty∓,pX<x±D¯S|Y<y⋅pY<y⋅pD¯Sx∓⋅pD¯Tyo,pX<x|Y<y⋅pY<y⋅pD¯Sxo⋅pD¯Tyo,whereas I, J, K, and L signify all the different transition states of X and Y for a month in two consecutive years, as follows:(11)I:X±,Y±⟶X∓,Y∓,X±,Y∓⟶X∓,Y±,J:X0,Y±⟶X0,Y∓,K:X±,Y0⟶X∓,Y0,L:X0,Y0⟶X0,Y0.Moreover, the probabilitiespD¯Sx−,pD¯Ty−,pD¯Sx+,pD¯Ty+,pD¯Sxo, and pD¯Tyo are defined as shown below. pD¯Sx− is the probability when x is decreased by D¯S, pD¯Sy− is the probability when y is decreased by D¯S, pD¯Sx+ is the probability when x is increased by D¯S, pD¯Ty+ is the probability when y is increased by D¯T, pD¯Sxo is the probability when x is unchangeable, and pD¯Tyo is the probability when y is unchanged.Remarkably, ifX and Y had the exponentiated Gumbel maximum distribution, then the probability density functions and cumulative distribution functions would be as follows:(12)fZ=z=μγβγe−z/βγe−μγe−z/βγ,z∈−∞;+∞,FZ=z=e−μγe−z/βγ,z∈−∞;+∞,where Z = {X, Y} and corresponding γ = {S, T}, respectively. It is worth mentioning that βS>0andβT>0 are scale parameters and μS>0andμT>0 are shape parameters.


## 3. Results and Discussion

### 3.1. Methodology and Results of AERM Method

It focuses on the points of contribution that hopefully foreground the significance of this study in terms of homogeneity test and Mann–Whitney test to compare the values of the actual data set with the estimation values by AERM method. Tables2 and 3 show that the values of the estimated parameters in the regression equations at various depths of less-estimate error (Algorithm 1).Table 2
Regression model polynomial of the second degree.
ModelDepthRegression equationy = ax2 + bx + c0.13 ≤x < 0.31Temp (2) = 368.68x2 − 154.22x + 35.918pH (2) = −797.13x2 + 334.61x − 21.488ORP (2) = 68081x2 − 27968x + 2434.7DO (2) = −991.91x2 + 393.23x − 19.756RES (2) = 1654.4x2 − 676.1x + 75.934SAL (2) = −7180x2 + 2967.8x − 221.95SSG (2) = −5779.4x2 + 2389.9x − 182.11TN (2) = 1955.9x2 − 733.97x + 112.76cd (2) = −8.1618x2 + 3.4154x − 0.2671cu (2) = −6.875x2 + 2.8562x − 0.1761zn (2) = 1.0662x2 − 0.629x + 0.1258pb (2) = 0.1838x2 − 0.1085x + 0.023fe (2) = 33.603x2 − 15.626x + 2.19250.31 ≤x < 1.34Temp (2) = 714.29x2 − 497.14x + 108.07pH (2) = −491.43x2 + 334.51x − 47.783ORP (2) = 18814x2 − 13666x + 2469DO (2) = −1695x2 + 1132.8x − 177.86RES (2) = −14000x2 + 9660x − 1633.2SAL (2) = 21790x2 − 15052x + 2616.4SSG (2) = 16771x2 − 11584x + 2011.3TN (2) = −22200x2 + 15258x − 2547.6cd (2) = −3.4286x2 + 2.3943x − 0.3757Cu (2) = −5.8571x2 + 4.1986x − 0.6647zn (2) = −1.4286x2 + 1.1143x − 0.1761pb (2) = 0.1429x2 − 0.0414x + 0.0051fe (2) = −357x2 + 252.43x − 43.3870.3 ≤x < 0.38Total pb (2) = 506.67x2 − 322.77x + 51.42(2) refers to the estimated elements in Lake Manzala by regression model.Table 3
Regression models polynomial of the first, second, and third degree.
ModelDepthRegression equationy = ax3 + bx2 + cx + d1.34 ≤x ≤ 2.5Temp (2) = 9.5611x3 − 55.367x2 + 104.34x − 43.508pH (2) = −3.854x3 + 23.964x2 − 47.844x + 38.775ORP (2) = −519.66x3 + 3246.5x2 − 6421.5x + 3872.8DO (2) = −38.682x3 + 238.37x2 − 473.74x + 307.87RES (2) = −9.2607x3 + 31.564x2 − 14.813x + 2.4553SAL (2) = −20.088x3 + 155.97x2 − 374.06x + 313.21SSG (2) = −18.391x3 + 137.34x2 − 321.19x + 260.33TN (2) = −1226.9x3 + 6963.8x2 − 12820x + 7762.6cd (2) = −0.0467x3 + 0.2661x2 − 0.4855x + 0.3171cu (2) = −0.041x3 + 0.242x2 − 0.4578x + 0.3485zn (2) = 0.0325x3 − 0.2051x2 + 0.4232x − 0.2459pb (2) = 0.0038x3 − 0.025x2 + 0.054x − 0.0307fe (2) = −4.2495x3 + 23.521x2 − 41.898x + 24.6080.38 <x ≤ 2.5Total pb (2) = 0.006x3 + 0.076x2 − 0.3468x + 0.3533y = ax + b&y = ax2 + bx + c0.13 ≤x < 0.3Total pb (2) = −0.4375x + 0.13590.13 ≤x < 0.3EC (2) = −63275x + 712430.3 ≤x < 0.38EC (2) = −2E + 08x2 + 1E + 08x − 2E + 070.38 ≤x < 2EC (2) = −62562x2 + 10838x + 316412 ≤x ≤ 2.5EC (2) = 29094x − 143090.13 ≤x < 0.3COD (2) = 13281x − 1251.60.3 ≤x < 0.38COD (2) = 9E + 06x2 − 5E + 06x + 836150.38 ≤x < 2COD (2) = 12169x − 161832 ≤x ≤ 2.5COD (2) = 550x + 500.13 ≤x < 0.3TDS (2) = −40494x + 455940.3 ≤x < 0.38TDS (2) = −3E + 07x2 + 2E + 07x − 3E + 060.38 ≤x < 2TDS (2) = −40036x2 + 69359x + 202512 ≤x ≤  2.5TDS (2) = 18620x − 9158Algorithm 1: Algorithm of estimation regression models (AERMs).
(1)
Inputn “n is the number of elements in the sample.”(2)
InputM “where M > 4 is the total number of data points for the element (i).”(3)
Fori = 1 to n.(4)
letQ = M : r = 1.(5)
Forj = r to M.(6)
Fork = 4 to 2 Step 1 “k is the number of data points.”(7)
Ifk ≤ Q then read k points (Xj, Yj) from data.(8)
Estimate the model of nonlinear regressionY=∑L=0k−1aLXL form the determinant:YXk−1Xk−2X1∑j=rr+k−1Yj∑j=rr+k−1Xjk−1∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk∑j=rr+k−1XjYj∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk−3∑j=rr+k−1Xj2∑j=rr+k−1Xj⋮⋮⋮⋮⋮∑j=rr+k−1Xjk−2Yj∑j=rr+k−1Xj2k−3∑j=rr+k−1Xj2k−4∑j=rr+k−1Xjk−1∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk−1Yj∑j=rr+k−1Xj2k−2∑j=rr+k−1Xj2k−3∑j=rr+k−1Xjk∑j=rr+k−1Xjk−1Yj=0(9)
ComputeR-square (R2), the total sum of squares (SST), the regression sum of squares (SSR), and the error sum of squares (SSE) from: SSR=∑j=rr+k−1Yj^−Yj¯2,SSE=∑j=rr+k−1Yj^−Yj2,SST=∑j=rr+k−1Yj−Y¯2,whereY¯=∑j=rr+k−1Yj/k,R2=SSR/SST. Y^j is the estimated value from the equation Y=∑L=0k−1aLXL by the determinant in the Step 8, and Yj is the actual data of the element (i).(10)
IfR2 ≥ 0.95 then: {print the equation in Step 8, r = r + k, Q = Q − r + 1, Return to the loop in Step 5}, else: Return to the loop in Step 6 where k will be equal to k − 1.(11)
Whenk = 2, estimate the simple linear regression equation Y=∑L=0k−1aLXL similarly as in the determinant of Step 8. As well r = r + k, Q = Q − r + 1 then return to Step 5.(12)
Ifr = M or Q = Q − M + 1 then: {Return to the loop in the Step 3 and move to the next element (i + 1)}.(13)
The algorithm ends after the loop in Step 3 has finished; thus, all prediction equations are obtained for all elements in the given sample.The AERM algorithm aims to read the points of the scales data for any sample. The sample contains several items with different measurements, even if there is high dispersion between the measurement values for each item separately. The AERM algorithm also handles large or small sample sizes that contain several elements. For this reason, the AERM algorithm overcame the problem of the difficulty of the accuracy of predicting the measurements of each element in the different intervals of the depths of Lake Manzala in Egypt.Lake Manzala can be divided into two main regions according to their salinities. First, the southern region of the lake that is characterized by lower values of salinity and high concentration of nutrients and heavy metal as a consequence of receiving high volumes of low salinity drainage water through various drains. The second is the region at the north eastern area of the lake, near the lake-sea connection (El-Gamil), which is characterized by high salinity values and low nutrient concentration as a result of seawater intrusion through the outlet openings. Sallam and Elsayed discovered that the lake is exposed to high levels of pollutants from industrial, domestic, and agricultural sources [21].It has increasingly been subject to human pressures, including rapid municipal growth at Port Said, Damietta, and El Mataria, and reduction in lake surface by illegal land reclamation of wetlands for agriculture. Barakat et al. asserted that it produces about 50% of the fish catch of the northern lakes and freshwater fisheries [22].The results of the implementation of the AERM algorithm are charts of the linear and nonlinear regression of the water elements in Lake Manzala, which are shown in Figures8 to 12. Also, the parameter estimates for the linear and nonlinear regression lines and their equations are shown in Tables 2 and 3.Figure 8
Estimation of the regressions of Temp, pH, ORP, DO, and RES in Lake Manzala, Egypt.Figure 9
Estimation of the regressions of SAL, SSG, TN, cd, and cu in Lake Manzala, Egypt.Figure 10
Estimation of the regressions of zn, pb, fe, and total pH in Lake Manzala, Egypt.Figure 11
Estimation of the regressions of EC, COD, and TDS for the first two intervals in depth.Figure 12
Estimation of the regressions of EC, COD, and TDS for the second two intervals in depth.In effect, it is difficult to predict the maximum number of migratory bird types during a limited number of migration years, especially because of the large number of bird types in the world, a multiple nonlinear regression model of maximum number probability function of migratory bird types was obtained by El Genidy [23]. On the contrary, a multiple nonlinear regression model could accurately perform the job prediction of daily maximum ozone threshold exceedances by preprocessing and ensemble artificial intelligence techniques, as such presented by Gong and Ordieres-Mere [24].In this study, however, the homogeneity test and Mann–Whitney test were applied to obtain the real values along with the estimated values, with the use of the significant proposed program. Consequently, the two groups of values are compared to evaluate both the applicability and the accuracy of the program. In addition, the arithmetic mean and difference factor were also calculated to compare the averages of element sample values and their corresponding dispersion measures. The statistical significancep values precisely reveal that no essential differences are fore-grounded. This means that the newly proposed program efficiently works.The linear and nonlinear regressions for 17 elements in different depth intervals of Lake Manzala in Egypt shown in Figures8 to 12 clarify the accuracy of AERM’s algorithm in predicting with least error SSE ≤ 0.02 and R2 ≥ 0.98.Thus, it is possible to predict the unknown values of any elements in water using polynomial equations arising from the AERM’s algorithm in Tables2 and 3. It should be noted that AERM is a general algorithm for any other samples in different applications because their inputs of the values of variables can be changed according to application data.Table4 demonstrates the estimated values of the water elements at various depths ranging from 0.13 to 2.5 m by the estimator program in Lake Manzala, Egypt. Table 5 shows the comparison between the estimated values of the elements of water at various depths in using coefficient of variation, averages, standard deviation, homogeneity test, and Mann–Whitney test.Table 4
Estimated values of water elements at different depths of the lake.
Depth (m)0.130.290.30.310.330.381.341.522.5Temp2 (°C)22.122.222.83322.621.822.319.89620.69520.19320.69pH28.548.517.1538.6899.0898.3688.4217.9218.1118.721ORP2 (REDOX)−50.57149.592171.5940.5658.065−7.338−152.951−208.678−141.48−10.013DO2 (mg/L)14.610.8618.94110.41911.3797.8468.0033.0414.4148.926EC2uS/cm@25°C63017.2552893.2531437.3864486.4735218.463792.464537.04534504387958426RES2(Ohms.cm)16192216301617202518TDS2 (mg/L)40329.7833850.7442860.941813.2322539.240826.241303.04342082808237392SAL2 (PSU)42.52234.87422.1944.29922.17143.11643.69635.25628.26638.998SSG2 (st)30.90524.91314.71431.95314.94231.11232.29225.4920.18228.371TN2 (mg/L)50.39964.468.648.967044.76135.9560.363162.666.038COD2 (mg/L)474.932599.891474.1124.772550575123.462070.511501425Total pH.2 (mg/L)0.0790.0090.1890.0520.0820.2330.0390.0240.0120.055cd20.0390.0370.0230.0370.0410.0390.0320.030.0370.037cu20.0790.0740.0620.0740.0830.0850.0710.0680.0730.076zn20.0620.0330.0330.0320.0360.0410.0310.0370.040.038pb20.0120.0070.0070.0060.0070.010.0060.0070.0080.007fe20.7290.4870.5290.5591.0380.9860.4740.3410.90.471Table 5
Comparison between the values of estimated water elements and their actual data set.
Water propertiesCoefficient of variation (%)AverageStandard deviationHomogeneityp valueMann–Whitney testp valueTemp (1)4.9221.53331.0586050.987∗0.820∗Temp (2)4.9321.53071.061584pH (1)6.368.35230.5314920.998∗0.970∗pH (2)6.368.35230.531211ORP (1)−375.2−30.01112.59760.999∗0.880∗ORP (2)−373.98−30.1219112.6491DO (1)37.878.823.3403560.999∗0.970∗DO (2)37.918.8433.352044EC (1)23.2453239.4712373.020.995∗0.970∗EC (2)23.2853113.7212363.54RES (1)23.1419.94.6055521∗1∗RES (2)23.1419.94.605552TDS (1)18.4436320.476697.0481∗0.910∗TDS (2)18.4436320.516697.063SAL (1)24.3335.52938.6451660.998∗0.880∗SAL (2)24.3135.53888.639253SSG (1)26.5625.546.7843280.990∗0.880∗SSG (2)26.5825.48746.775422TN (1)51.0677.1439.390920.997∗0.970∗TN (2)51.177.20739.45543COD (1)74.41256.733934.96291∗0.940∗COD (2)74.391256.765934.9632PO4 (1)97.020.07780.075480.997∗0.940∗PO4 (2)97.370.07740.075365cd (1)15.320.03520.0053911∗1∗cd (2)15.320.03520.005391cu (1)9.150.07450.0068191∗1∗cu (2)9.150.07450.006819zn (1)23.480.03830.0089941∗1∗zn (2)23.480.03830.008994pb (1)24.020.00780.0018740.971∗0.811∗pb (2)24.530.00770.001889fe (1)37.560.65180.2447930.998∗0.880∗fe (2)37.610.65140.244983∗indicates the (p value) for each of homogeneity test and Mann–Whitney test.


### 3.2. Validity of AERM Method

As a result, the high accurate parameters estimation method by AERM was performed to estimate the elements of water quality at various depths in Lake Manzala, Egypt. In addition, AERM technique achieved all required results.Referring to related estimation methods, multiple linear regression, and artificial neural networks, based on principal components, could predict ozone concentrations. Later on, an adaptive neuro fuzzy inference system to anticipate the ground inflow into Amir Kabir tunnel in Iran, whereby a sample of 110 data sets containing the most influential parameters on ground inflow rate was set to develop the ground inflow rate forecasting model, introduced by Mecibah et al. [25]. Typical of the results of some previous studies is that the exponentiated Gumbel maximum distribution was estimated by quartiles moments method to analyze the maximum temperature and solar radiation data, thence, multiple nonlinear regressions of the daily global solar radiation, and the corresponding daily maximum temperatures are produced and compared with the real data set accordingly, carried out by El Genidy [26].It is necessary to obtain a large amount of sensor data correctly and effectively. A new method has been proposed to filter noise from the input sensor called Kalman filtering, which is one of the most representative filtering techniques. Kalman filtering corrects inaccurate values of input sensor data [27].


### 3.3. Applying CMMD Method to Solar Energy

In the case of three statesL, M, and H, the data sets of solar energy in January 2019 were divided into three half-open intervals [1–12), [12–23), and [23–34). These intervals are corresponding to the states L, M, and H, respectively. After converting the data set into Markov model, the transition probability matrix T of the three states and the vector Vc of the probabilities of the current state in January 2019 were obtained.(13)LMHT=LMH26282152605152668815,Vc=LMH6318311731.Then, the vectorVn of the probabilities of the next states in January 2020 is derived from (T. Vc), while Va is the vector of the probabilities of the actual data set of states in January 2020.(14)Vn=LMN944652393256465≅LMN0.200.250.55,Va=LMN63111311431≅LMN0.190.350.46.It turns out that the absolute error value in predicting the probability ofL is equal to 0.01, which is small and acceptable. However, the error values of M and H are approximately equal to 0.1, that is, relatively high error. Reducing error and improving results are done by re-partitioning the data set into six half-open intervals [1,7), [7,13), [13,19), [19,25), [25,31), and [31,34), whereby three new states, above low (L+), above medium (M+), and above high (H+) were added to the previous states Low (L), Medium (M), and High (H). The transition probability matrix S of the states L, L+, M, M+, H, and H+, respectively, and the vector Qc of the probabilities of the current state in January 2019 were obtained.(15)LL+MM+HH+S=LL+MM+HH+0014011301214014113012140021300001213102434347130000000,Qc=LL+MM+HH+2314314315311531131.Then, the vectorQn of the probabilities of the next states in January 2020 is derived from (S. Qc), while Qa is the vector of the probabilities of the actual data set of states in January 2020.(16)Qn=LL+MM+HH+2840322916125640310840387516120≅LL+MM+HH+0.070.140.140.270.380,Qa=LL+MM+HH+33143153183111310≅LL+MM+HH+0.100.130.160.260.350.It is evident from this that the Markov model for the six states gives much less absolute errors than the Markov model for the three states. The absolute errors of the probabilitiesp (L), p (L+), p (M), p (M+), p (H), and p (H+) between 2019 and 2020 are 0.03, 0.01, 0.02, 0.01, 0.03, and 0, respectively. As a result, the CMMD method gave good results in forecasting by dividing the data set into an appropriate number of intervals. This can be applied to the types of data set that relates to various sciences.


## 3.1. Methodology and Results of AERM Method

It focuses on the points of contribution that hopefully foreground the significance of this study in terms of homogeneity test and Mann–Whitney test to compare the values of the actual data set with the estimation values by AERM method. Tables2 and 3 show that the values of the estimated parameters in the regression equations at various depths of less-estimate error (Algorithm 1).Table 2
Regression model polynomial of the second degree.
ModelDepthRegression equationy = ax2 + bx + c0.13 ≤x < 0.31Temp (2) = 368.68x2 − 154.22x + 35.918pH (2) = −797.13x2 + 334.61x − 21.488ORP (2) = 68081x2 − 27968x + 2434.7DO (2) = −991.91x2 + 393.23x − 19.756RES (2) = 1654.4x2 − 676.1x + 75.934SAL (2) = −7180x2 + 2967.8x − 221.95SSG (2) = −5779.4x2 + 2389.9x − 182.11TN (2) = 1955.9x2 − 733.97x + 112.76cd (2) = −8.1618x2 + 3.4154x − 0.2671cu (2) = −6.875x2 + 2.8562x − 0.1761zn (2) = 1.0662x2 − 0.629x + 0.1258pb (2) = 0.1838x2 − 0.1085x + 0.023fe (2) = 33.603x2 − 15.626x + 2.19250.31 ≤x < 1.34Temp (2) = 714.29x2 − 497.14x + 108.07pH (2) = −491.43x2 + 334.51x − 47.783ORP (2) = 18814x2 − 13666x + 2469DO (2) = −1695x2 + 1132.8x − 177.86RES (2) = −14000x2 + 9660x − 1633.2SAL (2) = 21790x2 − 15052x + 2616.4SSG (2) = 16771x2 − 11584x + 2011.3TN (2) = −22200x2 + 15258x − 2547.6cd (2) = −3.4286x2 + 2.3943x − 0.3757Cu (2) = −5.8571x2 + 4.1986x − 0.6647zn (2) = −1.4286x2 + 1.1143x − 0.1761pb (2) = 0.1429x2 − 0.0414x + 0.0051fe (2) = −357x2 + 252.43x − 43.3870.3 ≤x < 0.38Total pb (2) = 506.67x2 − 322.77x + 51.42(2) refers to the estimated elements in Lake Manzala by regression model.Table 3
Regression models polynomial of the first, second, and third degree.
ModelDepthRegression equationy = ax3 + bx2 + cx + d1.34 ≤x ≤ 2.5Temp (2) = 9.5611x3 − 55.367x2 + 104.34x − 43.508pH (2) = −3.854x3 + 23.964x2 − 47.844x + 38.775ORP (2) = −519.66x3 + 3246.5x2 − 6421.5x + 3872.8DO (2) = −38.682x3 + 238.37x2 − 473.74x + 307.87RES (2) = −9.2607x3 + 31.564x2 − 14.813x + 2.4553SAL (2) = −20.088x3 + 155.97x2 − 374.06x + 313.21SSG (2) = −18.391x3 + 137.34x2 − 321.19x + 260.33TN (2) = −1226.9x3 + 6963.8x2 − 12820x + 7762.6cd (2) = −0.0467x3 + 0.2661x2 − 0.4855x + 0.3171cu (2) = −0.041x3 + 0.242x2 − 0.4578x + 0.3485zn (2) = 0.0325x3 − 0.2051x2 + 0.4232x − 0.2459pb (2) = 0.0038x3 − 0.025x2 + 0.054x − 0.0307fe (2) = −4.2495x3 + 23.521x2 − 41.898x + 24.6080.38 <x ≤ 2.5Total pb (2) = 0.006x3 + 0.076x2 − 0.3468x + 0.3533y = ax + b&y = ax2 + bx + c0.13 ≤x < 0.3Total pb (2) = −0.4375x + 0.13590.13 ≤x < 0.3EC (2) = −63275x + 712430.3 ≤x < 0.38EC (2) = −2E + 08x2 + 1E + 08x − 2E + 070.38 ≤x < 2EC (2) = −62562x2 + 10838x + 316412 ≤x ≤ 2.5EC (2) = 29094x − 143090.13 ≤x < 0.3COD (2) = 13281x − 1251.60.3 ≤x < 0.38COD (2) = 9E + 06x2 − 5E + 06x + 836150.38 ≤x < 2COD (2) = 12169x − 161832 ≤x ≤ 2.5COD (2) = 550x + 500.13 ≤x < 0.3TDS (2) = −40494x + 455940.3 ≤x < 0.38TDS (2) = −3E + 07x2 + 2E + 07x − 3E + 060.38 ≤x < 2TDS (2) = −40036x2 + 69359x + 202512 ≤x ≤  2.5TDS (2) = 18620x − 9158Algorithm 1: Algorithm of estimation regression models (AERMs).
(1)
Inputn “n is the number of elements in the sample.”(2)
InputM “where M > 4 is the total number of data points for the element (i).”(3)
Fori = 1 to n.(4)
letQ = M : r = 1.(5)
Forj = r to M.(6)
Fork = 4 to 2 Step 1 “k is the number of data points.”(7)
Ifk ≤ Q then read k points (Xj, Yj) from data.(8)
Estimate the model of nonlinear regressionY=∑L=0k−1aLXL form the determinant:YXk−1Xk−2X1∑j=rr+k−1Yj∑j=rr+k−1Xjk−1∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk∑j=rr+k−1XjYj∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk−3∑j=rr+k−1Xj2∑j=rr+k−1Xj⋮⋮⋮⋮⋮∑j=rr+k−1Xjk−2Yj∑j=rr+k−1Xj2k−3∑j=rr+k−1Xj2k−4∑j=rr+k−1Xjk−1∑j=rr+k−1Xjk−2∑j=rr+k−1Xjk−1Yj∑j=rr+k−1Xj2k−2∑j=rr+k−1Xj2k−3∑j=rr+k−1Xjk∑j=rr+k−1Xjk−1Yj=0(9)
ComputeR-square (R2), the total sum of squares (SST), the regression sum of squares (SSR), and the error sum of squares (SSE) from: SSR=∑j=rr+k−1Yj^−Yj¯2,SSE=∑j=rr+k−1Yj^−Yj2,SST=∑j=rr+k−1Yj−Y¯2,whereY¯=∑j=rr+k−1Yj/k,R2=SSR/SST. Y^j is the estimated value from the equation Y=∑L=0k−1aLXL by the determinant in the Step 8, and Yj is the actual data of the element (i).(10)
IfR2 ≥ 0.95 then: {print the equation in Step 8, r = r + k, Q = Q − r + 1, Return to the loop in Step 5}, else: Return to the loop in Step 6 where k will be equal to k − 1.(11)
Whenk = 2, estimate the simple linear regression equation Y=∑L=0k−1aLXL similarly as in the determinant of Step 8. As well r = r + k, Q = Q − r + 1 then return to Step 5.(12)
Ifr = M or Q = Q − M + 1 then: {Return to the loop in the Step 3 and move to the next element (i + 1)}.(13)
The algorithm ends after the loop in Step 3 has finished; thus, all prediction equations are obtained for all elements in the given sample.The AERM algorithm aims to read the points of the scales data for any sample. The sample contains several items with different measurements, even if there is high dispersion between the measurement values for each item separately. The AERM algorithm also handles large or small sample sizes that contain several elements. For this reason, the AERM algorithm overcame the problem of the difficulty of the accuracy of predicting the measurements of each element in the different intervals of the depths of Lake Manzala in Egypt.Lake Manzala can be divided into two main regions according to their salinities. First, the southern region of the lake that is characterized by lower values of salinity and high concentration of nutrients and heavy metal as a consequence of receiving high volumes of low salinity drainage water through various drains. The second is the region at the north eastern area of the lake, near the lake-sea connection (El-Gamil), which is characterized by high salinity values and low nutrient concentration as a result of seawater intrusion through the outlet openings. Sallam and Elsayed discovered that the lake is exposed to high levels of pollutants from industrial, domestic, and agricultural sources [21].It has increasingly been subject to human pressures, including rapid municipal growth at Port Said, Damietta, and El Mataria, and reduction in lake surface by illegal land reclamation of wetlands for agriculture. Barakat et al. asserted that it produces about 50% of the fish catch of the northern lakes and freshwater fisheries [22].The results of the implementation of the AERM algorithm are charts of the linear and nonlinear regression of the water elements in Lake Manzala, which are shown in Figures8 to 12. Also, the parameter estimates for the linear and nonlinear regression lines and their equations are shown in Tables 2 and 3.Figure 8
Estimation of the regressions of Temp, pH, ORP, DO, and RES in Lake Manzala, Egypt.Figure 9
Estimation of the regressions of SAL, SSG, TN, cd, and cu in Lake Manzala, Egypt.Figure 10
Estimation of the regressions of zn, pb, fe, and total pH in Lake Manzala, Egypt.Figure 11
Estimation of the regressions of EC, COD, and TDS for the first two intervals in depth.Figure 12
Estimation of the regressions of EC, COD, and TDS for the second two intervals in depth.In effect, it is difficult to predict the maximum number of migratory bird types during a limited number of migration years, especially because of the large number of bird types in the world, a multiple nonlinear regression model of maximum number probability function of migratory bird types was obtained by El Genidy [23]. On the contrary, a multiple nonlinear regression model could accurately perform the job prediction of daily maximum ozone threshold exceedances by preprocessing and ensemble artificial intelligence techniques, as such presented by Gong and Ordieres-Mere [24].In this study, however, the homogeneity test and Mann–Whitney test were applied to obtain the real values along with the estimated values, with the use of the significant proposed program. Consequently, the two groups of values are compared to evaluate both the applicability and the accuracy of the program. In addition, the arithmetic mean and difference factor were also calculated to compare the averages of element sample values and their corresponding dispersion measures. The statistical significancep values precisely reveal that no essential differences are fore-grounded. This means that the newly proposed program efficiently works.The linear and nonlinear regressions for 17 elements in different depth intervals of Lake Manzala in Egypt shown in Figures8 to 12 clarify the accuracy of AERM’s algorithm in predicting with least error SSE ≤ 0.02 and R2 ≥ 0.98.Thus, it is possible to predict the unknown values of any elements in water using polynomial equations arising from the AERM’s algorithm in Tables2 and 3. It should be noted that AERM is a general algorithm for any other samples in different applications because their inputs of the values of variables can be changed according to application data.Table4 demonstrates the estimated values of the water elements at various depths ranging from 0.13 to 2.5 m by the estimator program in Lake Manzala, Egypt. Table 5 shows the comparison between the estimated values of the elements of water at various depths in using coefficient of variation, averages, standard deviation, homogeneity test, and Mann–Whitney test.Table 4
Estimated values of water elements at different depths of the lake.
Depth (m)0.130.290.30.310.330.381.341.522.5Temp2 (°C)22.122.222.83322.621.822.319.89620.69520.19320.69pH28.548.517.1538.6899.0898.3688.4217.9218.1118.721ORP2 (REDOX)−50.57149.592171.5940.5658.065−7.338−152.951−208.678−141.48−10.013DO2 (mg/L)14.610.8618.94110.41911.3797.8468.0033.0414.4148.926EC2uS/cm@25°C63017.2552893.2531437.3864486.4735218.463792.464537.04534504387958426RES2(Ohms.cm)16192216301617202518TDS2 (mg/L)40329.7833850.7442860.941813.2322539.240826.241303.04342082808237392SAL2 (PSU)42.52234.87422.1944.29922.17143.11643.69635.25628.26638.998SSG2 (st)30.90524.91314.71431.95314.94231.11232.29225.4920.18228.371TN2 (mg/L)50.39964.468.648.967044.76135.9560.363162.666.038COD2 (mg/L)474.932599.891474.1124.772550575123.462070.511501425Total pH.2 (mg/L)0.0790.0090.1890.0520.0820.2330.0390.0240.0120.055cd20.0390.0370.0230.0370.0410.0390.0320.030.0370.037cu20.0790.0740.0620.0740.0830.0850.0710.0680.0730.076zn20.0620.0330.0330.0320.0360.0410.0310.0370.040.038pb20.0120.0070.0070.0060.0070.010.0060.0070.0080.007fe20.7290.4870.5290.5591.0380.9860.4740.3410.90.471Table 5
Comparison between the values of estimated water elements and their actual data set.
Water propertiesCoefficient of variation (%)AverageStandard deviationHomogeneityp valueMann–Whitney testp valueTemp (1)4.9221.53331.0586050.987∗0.820∗Temp (2)4.9321.53071.061584pH (1)6.368.35230.5314920.998∗0.970∗pH (2)6.368.35230.531211ORP (1)−375.2−30.01112.59760.999∗0.880∗ORP (2)−373.98−30.1219112.6491DO (1)37.878.823.3403560.999∗0.970∗DO (2)37.918.8433.352044EC (1)23.2453239.4712373.020.995∗0.970∗EC (2)23.2853113.7212363.54RES (1)23.1419.94.6055521∗1∗RES (2)23.1419.94.605552TDS (1)18.4436320.476697.0481∗0.910∗TDS (2)18.4436320.516697.063SAL (1)24.3335.52938.6451660.998∗0.880∗SAL (2)24.3135.53888.639253SSG (1)26.5625.546.7843280.990∗0.880∗SSG (2)26.5825.48746.775422TN (1)51.0677.1439.390920.997∗0.970∗TN (2)51.177.20739.45543COD (1)74.41256.733934.96291∗0.940∗COD (2)74.391256.765934.9632PO4 (1)97.020.07780.075480.997∗0.940∗PO4 (2)97.370.07740.075365cd (1)15.320.03520.0053911∗1∗cd (2)15.320.03520.005391cu (1)9.150.07450.0068191∗1∗cu (2)9.150.07450.006819zn (1)23.480.03830.0089941∗1∗zn (2)23.480.03830.008994pb (1)24.020.00780.0018740.971∗0.811∗pb (2)24.530.00770.001889fe (1)37.560.65180.2447930.998∗0.880∗fe (2)37.610.65140.244983∗indicates the (p value) for each of homogeneity test and Mann–Whitney test.


## 3.2. Validity of AERM Method

As a result, the high accurate parameters estimation method by AERM was performed to estimate the elements of water quality at various depths in Lake Manzala, Egypt. In addition, AERM technique achieved all required results.Referring to related estimation methods, multiple linear regression, and artificial neural networks, based on principal components, could predict ozone concentrations. Later on, an adaptive neuro fuzzy inference system to anticipate the ground inflow into Amir Kabir tunnel in Iran, whereby a sample of 110 data sets containing the most influential parameters on ground inflow rate was set to develop the ground inflow rate forecasting model, introduced by Mecibah et al. [25]. Typical of the results of some previous studies is that the exponentiated Gumbel maximum distribution was estimated by quartiles moments method to analyze the maximum temperature and solar radiation data, thence, multiple nonlinear regressions of the daily global solar radiation, and the corresponding daily maximum temperatures are produced and compared with the real data set accordingly, carried out by El Genidy [26].It is necessary to obtain a large amount of sensor data correctly and effectively. A new method has been proposed to filter noise from the input sensor called Kalman filtering, which is one of the most representative filtering techniques. Kalman filtering corrects inaccurate values of input sensor data [27].


## 3.3. Applying CMMD Method to Solar Energy

In the case of three statesL, M, and H, the data sets of solar energy in January 2019 were divided into three half-open intervals [1–12), [12–23), and [23–34). These intervals are corresponding to the states L, M, and H, respectively. After converting the data set into Markov model, the transition probability matrix T of the three states and the vector Vc of the probabilities of the current state in January 2019 were obtained.(13)LMHT=LMH26282152605152668815,Vc=LMH6318311731.Then, the vectorVn of the probabilities of the next states in January 2020 is derived from (T. Vc), while Va is the vector of the probabilities of the actual data set of states in January 2020.(14)Vn=LMN944652393256465≅LMN0.200.250.55,Va=LMN63111311431≅LMN0.190.350.46.It turns out that the absolute error value in predicting the probability ofL is equal to 0.01, which is small and acceptable. However, the error values of M and H are approximately equal to 0.1, that is, relatively high error. Reducing error and improving results are done by re-partitioning the data set into six half-open intervals [1,7), [7,13), [13,19), [19,25), [25,31), and [31,34), whereby three new states, above low (L+), above medium (M+), and above high (H+) were added to the previous states Low (L), Medium (M), and High (H). The transition probability matrix S of the states L, L+, M, M+, H, and H+, respectively, and the vector Qc of the probabilities of the current state in January 2019 were obtained.(15)LL+MM+HH+S=LL+MM+HH+0014011301214014113012140021300001213102434347130000000,Qc=LL+MM+HH+2314314315311531131.Then, the vectorQn of the probabilities of the next states in January 2020 is derived from (S. Qc), while Qa is the vector of the probabilities of the actual data set of states in January 2020.(16)Qn=LL+MM+HH+2840322916125640310840387516120≅LL+MM+HH+0.070.140.140.270.380,Qa=LL+MM+HH+33143153183111310≅LL+MM+HH+0.100.130.160.260.350.It is evident from this that the Markov model for the six states gives much less absolute errors than the Markov model for the three states. The absolute errors of the probabilitiesp (L), p (L+), p (M), p (M+), p (H), and p (H+) between 2019 and 2020 are 0.03, 0.01, 0.02, 0.01, 0.03, and 0, respectively. As a result, the CMMD method gave good results in forecasting by dividing the data set into an appropriate number of intervals. This can be applied to the types of data set that relates to various sciences.


## 4. Conclusion

This study discovered the forecasting of water quality by programming the regression models of the water elements in lakes. It is beneficial for predicting the corresponding values of other locations that have not been estimated yet or are impossible to reach. This study will help researchers to uncover the critical areas by reducing the time and effort to frequently move to significant water bodies. Consequently, a new algorithm has been reached for predicting water quality by the regression programming of the water elements in various depths of the lake. On the contrary, Markov transition probability matrix produces accurately forecasting for the different state probabilities of solar energy, whereby the performance of environmental energetic systems depend on solar radiation. In this study, the prediction method depends on the conversion of the data set into Markov models. This procedure to minimize the absolute errors of forecasting various states of solar energy in the future.


### 4.1. Future Work

This paper suggests the use of two prediction methods: algorithm of estimation regression models (AERMs) and converting data set to Markov model (CDMM) in the field of electronic industries such as lithium battery industry to increase its lifetime, reliability, and reduce failure rate. Moreover, the prediction of the system states to control commands and optimize the stochastic control strategy to achieve the speed control of the “model-free” quadrotor. It is worth mentioning that the two prediction methods reduce the time, effort, and cost in dealing with two types of data: the first type is limited and has high dispersion; in this case, the AERM algorithm will be used. When the second type of data are unlimited or large in size and need to be converted into a limited number of states, then CDMM method will be used. There is also another new proposal when there are two different items of the same system. Thus, it is required to predict the states of the system and items at the same time. For this reason, hidden Markov model will be used instead of Markov model. For example, a system contains two items: the virtual machines and their corresponding jobs. Therefore, it needs to predict the probability of the states of virtual machines (are they all in the busy states or not?) and the corresponding jobs (are they all in the processing states or not?). Consequently, these states will be predicted using the hidden Markov model.


## 4.1. Future Work

This paper suggests the use of two prediction methods: algorithm of estimation regression models (AERMs) and converting data set to Markov model (CDMM) in the field of electronic industries such as lithium battery industry to increase its lifetime, reliability, and reduce failure rate. Moreover, the prediction of the system states to control commands and optimize the stochastic control strategy to achieve the speed control of the “model-free” quadrotor. It is worth mentioning that the two prediction methods reduce the time, effort, and cost in dealing with two types of data: the first type is limited and has high dispersion; in this case, the AERM algorithm will be used. When the second type of data are unlimited or large in size and need to be converted into a limited number of states, then CDMM method will be used. There is also another new proposal when there are two different items of the same system. Thus, it is required to predict the states of the system and items at the same time. For this reason, hidden Markov model will be used instead of Markov model. For example, a system contains two items: the virtual machines and their corresponding jobs. Therefore, it needs to predict the probability of the states of virtual machines (are they all in the busy states or not?) and the corresponding jobs (are they all in the processing states or not?). Consequently, these states will be predicted using the hidden Markov model.



---

*Source: 2631939-2022-01-29.xml*