# Adaptive Solar Power Forecasting based on Machine Learning Methods
## 2 Principle and Framework of the ASPF  
In this paper, the realization of ASPF mainly depends on the stored historical solar power data and the learning network which is updated according to the actual needs. In the database, we store the original predictive solar power \(P_{ori}\), the revised solar power \(P_{rev}\), and the actual solar power data \(P_{act}\). As more data collected, ASPF becomes more adaptive. Under certain condition, the historical solar power data \(P_{sdm}\) are taken as the revised data \(P_{rev}\) directly, which is named as _Similar Day Mode (SDM)_. On the other hand, when the condition of SDM does not hold, which is named as _Non-similar Day Mode (NDM)_, ASPF modifies the original predictions \(P_{ori}\) by the output from a learning and updating network obtained from Back-propagation neural networks (BPNN) [25]. It learns the characteristics of differences between \(P_{ori}\) and \(P_{act}\). In this way, ASPF predicts more precisely for both SDM and NDM.  
Furthermore, whatever the system is working in SDM or NDM, the network can be updated according to that whether the error between \(P_{rev}\) and \(P_{act}\) is within an acceptable range or not. If the error is out of the allowed range, the network in ASPF is updated. We now present the mode judging standard, ASPF framework, and updating rules in this section. The notations used in this paper are summarized in Table 1.  
\begin{table}
\begin{tabular}{l l l l} \hline \hline
**Symbol** & **Description** & **Symbol** & **Description** \\ \hline \(P_{ori}\) & the original predictive solar power & \(C_{k}^{giv}\) & initial given clustering center \\  & & & in group \(k\) \\ \(P_{rev}\) & the revised solar power & \(C_{k}^{s}\) & optimal clustering center in group \(k\) \\ \(P_{act}\) & the actual solar power & \(D_{n}^{(k)}\) & density function value of the \(n\)th data \\  & & & in order to calculate the initial center \\  & & & of \(k+1\)th cluster \\ \(P_{sdm}\) & the historical solar power & \(D_{k}^{s}\) & the \(k\)th group initial cluster center \\ \(\Delta_{1}\) & the threshold to judge the similar day & \(D_{w}\) & inner distance in the same group \\ \(\Delta_{1,ap}\) & the updated value of \(\Delta_{1}\) & \(D_{b}\) & the minimum distance between \\  & & & different groups \\ \(\Delta_{2}\) & acceptable error between \(P_{rev}\) and \(P_{act}\) & \(I_{k}\) & intra-group and inter-group index \\ \(\Delta_{2,up}\) & the updated value of \(\Delta_{2}\) & \(N_{k}\) & the number of data in \(k\)th cluster \\ \(R_{s}\) & signal to trigger the network updating & \(x_{k,g}\) & the gth data in group \(k\) \\ \(x\) & the vector contains \(P_{ori}\) and & \(c_{or}\) & correlation coefficient of residual \\  & weather data & & \\ \(N\) & the total number of \(x\) & \(\delta_{n}\) & the predictive value of the \(n\)th data \\ \(k\) & clustering number & \(w\) & the weight of neural network \\ \(K\) & the maximum number of clusterings & \(b\) & the bias value of neural network \\ \(C_{k}\) & the \(k\)th clustering center & \(h\) & the number of hidden neurons \\ \(NT\) & total number of similar days & \(NL\) & the number of days with the MxAE \\  & or non-similar day & less than \(\Delta_{2}\) & \\ \(NB\) & the number of days with the MxAE & \(SI\) & the indicator to record whether \\  & larger than \(\Delta_{2}\) & & there is a similar day \\ \(TS\) & the number of similar days & \(WD\) & the indicator to record whether MxAE \\  & when \(SI\geq 1\) & & in \(P_{sdm}/P_{rev}\) and \(P_{act}\leq\Delta_{2}\) \\ \(BD\) & the indicator to record whether MxAE & \(WD^{\prime}\) & the indicator to record \(WD\) state \\  & in \(P_{sdm}/P_{rev}\) and \(P_{act}\geq\Delta_{2}\) & after NN updated \\ \(BD^{\prime}\) & the indicator to record \(BD\) state & \(NS\) & the indicator without similar day \\  & after NN updated & & \\ \hline \hline \end{tabular}
\end{table}
Table 1: Notation.