## 2 Methodology
### Training and Estimation  
Features are normalized to have zero mean and unit variance and then each hour of data is set as an input \(\mathrm{x}\) such that \(\mathrm{x}=(x_{1},x_{2}\cdots,\,x_{7})\) and solar irradiance is set as the  
Figure 2: Recurrent neural network structure.  
output \(y\). For an RNN designed for time-series data, the times-series data are constructed as follows:  
\[\text{xs}=\Big{(}\text{x}_{1}{}^{T},\text{x}_{2}{}^{T},\cdots,\text{x}_{s}{}^{T} \Big{)}. \tag{10}\]  
where \(s\) is the number of consecutive hours for an input and T is time step index.  
We used the weather data for eight years (from 2008 to 2015) as a training set and predicted the solar irradiance value in 2016 as a test set.  
To evaluate the accuracy of the simulation results, this study used calibration standards: the mean square error (MSE), widely accepted by ASHRAE Guideline 14-2002 [64]. The corresponding equation is as follows:  
\[[\frac{1}{n}\sum_{i=1}^{n}(y_{i}-\overline{y}_{i})^{2}]^{1/2} \tag{11}\]  
where \(n\) is the number of data points, \(y_{i}\) is the actual value, and \(\overline{y}_{i}\) is the predicted value.  
Figure 3: Historical data for 9 years (2008–2016): temperature, humidity ratio, and air pressure.  
Figure 4: Historical data for 9 years (2008–2016): wind velocity, wind direction, amount of middle, low-layer cloud cover (MLcc) and amount of total cloud cover (Tcc).  
Figure 5: Historical data for 9 years (2008–2016): Global Horizontal Irradiance (GHI).  
The network training process is shown in Figure 6.  
Generally, in machine learning, SVM, MLNN, and LSTM models require a hyper-parameter whose value is set before the training process can begin. For SVM, we chose a gamma value of 0.1 before learning process. For MLNN, the network used in this study was composed of an input layer, 64 nodes for hidden layer 1, 32 nodes for hidden layer 2, and an output layer. The learning rate was 0.005 and training was conducted for 200 epochs. For the LSTM, we used the same number of layers as the MLNN, and the same learning rate of 0.0005.  
To determine the correlations among the weather parameters that impact solar irradiance, we used impact factors, where the magnitude of each value represents the impact and positive or negative values illustrate the direction of the impact. The impact factor evaluation method calculates the impact of each input node element based on an adjusted value after training with input elements and real solar irradiance values. The process used to calculate the impact factor is as follows. After training and testing with all-weather parameters, the test node values are varied between \(-10\%\) and \(+10\%\) with an interval of \(1\%\) of their original values, to form new testing samples. In order to determine the number of hidden layer nodes, the formula suggested following Equation (12) [40; 65]:  
\[p<\sqrt{n+m}+a \tag{12}\]  
where \(p\) is in the range of numbers, \(n\) is the input number, m is the output node number, and a is a positive integer that is less than 10 [40; 65].  
Subsequently, the new adjusted testing nodes are simulated and compared with the values obtained without adjusting the nodes. Then, each algorithm is used to fit 21 points to a linear functional, and then the gradient of the linear functional is obtained. The gradient is used as the impact of the feature because the gradient describes a linear relation between  
Figure 6: Training process for artificial neural network.  
two variables. The impact values of the features for each machine learning algorithm are illustrated by Equation (13).  
\[\underset{\Gamma}{\text{min}}\sum_{i=1}^{k}(q_{i}-f(p_{i},\Gamma))^{2} \tag{13}\]  
where min denotes minimizing, \(q_{i}\) and \(p_{i}\) are input values which include 21 data points, and \(\Gamma\) is a set of coefficients.