# Short-Term Power Forecasting Model for Photovoltaic Plants Based on Historical Similarity

^{1}

^{2}

^{3}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. PV Power Forecasting Model

_{t+k}) is created, which contains power transition probabilities between the future instants t+k−1 and t+k, where t is the instant when the forecast is generated -present instant-; and k is the number of time steps of the forecast (forecasting horizon). Thus, the HISIMI model provides valuable forecast information, using probability values: prediction of uncertainties, associated with electric power forecasted values, and electric power forecasts (point or spot forecasts). The following subsections contain more detailed explanations regarding the HISIMI model.

#### 2.1. Database of the Forecasting Model

_{c}

_{−1}and P

_{c}) of the PV plant. The pairs of past instants c−1 and c are necessary to model power transitions. The index c ranges from 2 to present instant t and it is expressed in hours. At this point, notice that the size of the records depend on the number of forecasted weather variables and the number of the remaining variables related to the short-term forecast of power generation in the PV plant.

#### 2.2. Mechanism Based on Data Mining (MDM)

_{c}, is defined in Equation (2):

_{i,c}represents the weight value associated with the local Gaussian function corresponding to the input variable i.

#### 2.3. Power Intervals

_{m}and b

_{m}correspond to the minimum and maximum values of that interval:

_{1}< I

_{2}<…< I

_{n}:

#### 2.4. Probability Matrix (PM)

_{t+k}, is shown in Table 1. Each element in this matrix represents the pseudo-probability of a power transition from one power interval in instant t+k−1 (interval x, that is, row x in the matrix) to another power interval in instant t+k (interval y, that is, column y in the matrix). The element PPM

_{t}

_{+k}(x, y), corresponding to row x and column y, is calculated using the sum of values FH

_{c}from Equation (2) considering all cases in the database.

_{t+k}, which contains the bivariate distribution of power transitions, from one power interval x (associated with instant t+k−1) to another power interval y (associated with instant t+k). Note that results are obtained after applying the mechanism MDM, which defines the space of global events of power transitions.

_{t+k}matrix can be associated with a joint probability distribution f

_{XY}(x, y) (Table 2), that satisfies Equation (5):

_{XY}(x, y) represents the probability that the interval of the electric power variable is x in a given instant, and y in the following one, i.e., P(X = x, Y = y).

Pseudo-probabilities | Power interval in t+k | ||||

1 | 2 | … | n | ||

Power interval in t+k−1 | 1 | … | … | … | … |

2 | … | … | … | … | |

… | … | … | … | … | |

n | … | … | … | … |

f_{XY} (x, y) | y | ||||
---|---|---|---|---|---|

1 | 2 | … | n | ||

x | 1 | f_{XY} (1, 1) | f_{XY} (1, 2) | … | f_{XY} (1, n) |

2 | f_{XY} (2, 1) | f_{XY} (2, 2) | … | f_{XY} (2, n) | |

… | … | … | … | … | |

n | f_{XY} (n, 1) | f_{XY} (n, 2) | … | f_{XY} (n, n) |

_{m}

_{1}and f

_{m}

_{2}can be defined, for each transition in t+k, by Equations (6) and (7) respectively:

_{x}denotes the set of all f

_{XY}(x,y) for which X = x:

_{y}denotes the set of all f

_{XY}(x,y) for which Y = y.

#### 2.5. Model Outputs

#### 2.5.1. Uncertainty Prediction

_{m}

_{1}and f

_{m}

_{2}, obtained for two consecutive forecasting instant, t+k−1 and t+k, denoted as f

_{m}

_{1;t+k−1}and f

_{m}

_{2;t+k}.

_{t+k}, for the uncertainty prediction, as the product of the values of the marginal probability functions defined in Equations (6) and (7), as is given in Equation (8).

_{t+k}, defined in Equation (8), are normalized (to values between 0 and 1), leading to a new vector, [u

_{n}]

_{t+k}, in which each element of this new vector, corresponding to a power interval, is associated with the probability that the forecasted electric power value belongs to that interval; thus, this vector gives a measure of uncertainty associated with electric power forecasts.

#### 2.5.2. Point Forecast

_{t+k}(in kW) can be obtained by computing the expected power value for a future instant t+k as seen in Equation (9):

_{n,t+k}(y) is the element of the vector [u

_{n}]

_{t+k}corresponding to the power interval y.

## 3. Optimization of the PV Power Forecasting Model

_{j}means that the input j is used by the model as prospection variable, while a “0” value means that the input j is not used by the model. At least one of these first p bits must be activated (value “1”) because the model represented by the individual needs one or more inputs (prospection variables). The second gene, with a 6 bits size, corresponds to the number of intervals minus two, expressed in binary, used by the model: a value “000000” means 2 intervals, while a value “111111” means 65 intervals. The third gene corresponds to the standard deviation of the Gaussian function for the first input (prospection) variable, σ

_{1}(the first variable selected as input); it is composed of 16 bits, and its value is equal to the binary number contained in the 16 bits plus one and divided by 32,768. So, the standard deviation can take values from 2

^{−15}to 2 (remember that input variables are normalized). The fourth gene, if available, corresponds to the standard deviation of the Gaussian function of the second (prospection) variable selected as input, and so on for the following genes. In Figure 2, the standard deviation of the Gaussian function for the last input variable selected is σ

_{l}, assuming that l inputs have been selected in the first gene. The maximum number of genes is equal to the number of available input variables plus the two first genes.

_{i}the real power generation value and ${\widehat{P}}_{i}$ the value obtained (forecasted) with the model, and the index i covers all instants corresponding to the data set which error is evaluated:

## 4. Model Testing

**Figure 3.**Percentage of hours with power output variations with respect to power rating of the PV plant.

_{1}) and temperature (v

_{2}) obtained with an NWP tool. This tool was the Weather Research and Forecasting (WRF) model [20], a mesoscale NWP model that can simulate atmospheric dynamics and provide numerical predictions for a wide set of weather variables in a selected geographic zone. The hourly average surface shortwave radiation and temperature values correspond to those forecasted (with the NWP tool) with the data assimilation (moment when real weather measures were supplied to the model to predict the future values) of the hour 00:00. The forecasted hourly average values include all the values for the next 24 h, making that forecasting horizons for the HISIMI model range from 1 to 24 h. Obviously, the maximum forecasting horizon with the HISIMI model coincides with that of the weather variables forecasted with the NWP tool (24 h in our case).

_{3}and v

_{4}). These two variables are expressed in Equation (11), where h corresponds to the solar hour for the location of the PV plant for the corresponding instant:

_{3}, two values for variable v

_{4}, and two values for the hourly power production in the PV plant. The two values of each variable correspond to two consecutive instants, c−1 and c.

**Figure 4.**Percentage of hours with power output variations with respect to power rating of the PV plant, for the data sets of training and testing.

_{1}(forecasted hourly average surface shortwave radiation), v

_{2}(forecasted hourly average surface temperature), and v

_{4}. The number of power intervals was 9 and the range of any interval was 314 kW. The two extremes of the last interval (ninth) were centered on the maximum value of the power output of the PV plant for the training data set (2512 kW in our case) and the ones of first interval were centered on the minimum power output, i.e., they were centered in 0 kW. Thus the first interval spanned from −157 to 157 kW, the second from 157 to 471 kW, and so on until the ninth interval from 2355 to 2669 kW. The standard deviations for the three used inputs of the HISIMI model were 0.314453125 (for v

_{1}), 0.193359375 (for v

_{2}) and 0.076171875 (for v

_{4}). Figure 5 plots the RMS error with the data of the training set, using the 5-fold cross-validation, throughout the optimization process for the best individual in each generation and the average value of RMS error for all the individuals in each generation.

**Figure 5.**RMS error of the best individual and average RMS error of all the individuals in each generation.

Model | HISIMI | MLP |
---|---|---|

Population size | 50 | 50 |

Number of generations | 50 | 50 |

Crossover rate | 90% | 90% |

Mutation rate | 2% | 1% |

Inputs selected | v_{1}, v_{2}, v_{4} | v_{1}, v_{3}, v_{4} |

Power Intervals | 9 | - |

Neurons in hidden layer | - | 15 |

_{reference}corresponds to the RMS error obtained with the model used as reference, and RMS

_{model}corresponds to the RMS error of the compared model. The RMS forecasting error for the HISIMI model was 0.8% better than that obtained with the MLP model, and 36.3% better than that obtained with the persistence model. Table 4 summarizes the forecasting results obtained with the three models:

Forecasting Results | HISIMI | MLP | Persistence |
---|---|---|---|

RMS error (kW) | 283.89 | 286.11 | 445.48 |

Normalized RMS (%) | 10.14 | 10.22 | 15.91 |

Improvement with respect to Persistence (%) | 36.3 | 35.8 | - |

Improvement with respect to MLP (%) | 0.8 | - | - |

**Figure 6.**Forecasts of the hourly power production for three cloudy and rainy days in the testing set.

**Figure 7.**Scatter plots of forecasted values versus actual values of power output for HISIMI and MLP models.

## 5. Analysis of Information Provided by the PV Power Forecasting Model

**Figure 9.**Forecasted hourly power production (

**a**) and uncertainty prediction for six central hours; (

**b**) (from 9:00 to 14:00) on a sunny day.

**Figure 10.**Forecasted production of hourly power (

**a**) and uncertainty prediction for six hours; (

**b**) on a partly cloudy day.

**Figure 11.**Forecasted hourly power production (

**a**) and uncertainty prediction for six central hours; (

**b**) (from 9:00 to 14:00) on a rainy day.

**Figure 12.**Forecasted hourly power production (

**a**) and uncertainty prediction for six central hours; (

**b**) (from 9:00 to 14:00) on a cloudy and rainy day.

## 6. Conclusions

- The HISIMI model allows a stochastic modeling based on similarity between input values in a database of historical cases. This similarity focuses mainly on variables forecasted by NWP tools.
- A database with a significant number of historical cases is used to model stochastic forecast, by creating discrete probability distribution functions.
- A genetic algorithm optimizes the structure of the HISIMI model, allowing the selection of the best inputs (variables) to be used by the model as well as the optimal values of basic parameters that define the model.
- The stochastic modeling of electric power transitions allows for the estimation of uncertainties in point (spot) forecasts of electric power. Uncertainty results obtained from HISIMI provide the probability distributions associated with the spot values.
- Spot forecasts are calculated using such discrete probability distributions.

## Acknowledgements

## References

- International Energy Agency. Technology Roadmap: Wind Energy; IEA Publications: Paris, France, 2010; Available online: http://www.iea.org/publications/freepublications/publication/Wind_Roadmap-1.pdf (accessed on 12 December 2012).
- International Energy Agency. Technology Roadmap: Solar Photovoltaic Energy; IEA Publications: Paris, France, 2010; Available online: http://www.iea.org/publications/freepublications/publication/pv_roadmap-1.pdf (accessed on 12 December 2012).
- Parsons, B.; Milligan, M.; Zavadil, B.; Brooks, D.; Kirby, B.; Dragoon, K.; Caldwell, J. Grid impacts of wind power: A summary of recent studies in the United States. Wind Energy
**2005**, 7, 87–108. [Google Scholar] [CrossRef] - Ortega-Vazquez, M.A.; Kirschen, D.S. Assessing the impact of wind power generation on operating costs. IEEE T. Smart Grids
**2010**, 1, 295–301. [Google Scholar] [CrossRef] - Angarita-Márquez, J.L.; Hernandez-Aramburo, C.A.; Usaola-Garcia, J. Analysis of a wind farm’s revenue in the British and Spanish markets. Energy Policy
**2007**, 35, 5051–5059. [Google Scholar] [CrossRef] - Hocaoglu, F.O.; Gerek, O.N.; Kurban, M. Hourly solar radiation forecasting using optimal coefficient 2-D linear filters and feed-forward neural networks. Solar Energy
**2008**, 82, 714–726. [Google Scholar] [CrossRef] - Mellit, A.; Massi Pavan, A. A 24-h forecast of solar irradiance using artificial neural network: Application for performance prediction of a grid-connected PV plant at Trieste, Italy. Sol. Energy
**2010**, 84, 807–821. [Google Scholar] [CrossRef] - Kaplanis, S.; Kaplani, E. Stochastic prediction of hourly global solar radiation for Patra, Greece. Appl. Energy
**2010**, 87, 3748–3758. [Google Scholar] [CrossRef] - Wang, F.; Mi, Z.; Su, S.; Zhao, H. Short-term solar irradiance forecasting model based on artificial neural network using statistical feature parameters. Energies
**2012**, 5, 1355–1370. [Google Scholar] [CrossRef] - Mandal, P.; Madhira, S.T.S.; Haque, A.U.I.; Meng, J.; Pineda, R.L. Forecasting power output of solar photovoltaic system using wavelet transform and artificial intelligence techniques. Procedia Comput. Sci.
**2012**, 12, 332–337. [Google Scholar] [CrossRef] - Pedro, H.T.C.; Coimbra, C.F.M. Assessment of forecasting techniques for solar power production with no exogenous inputs. Solar Energy
**2012**, 86, 2017–2028. [Google Scholar] [CrossRef] - Yona, A.; Senjyu, T.; Saber, A.Y.; Funabashi, T.; Sekine, H.; Kim, C.-H. Application of Neural Network to One-day-ahead 24 hours Generating Power Forecasting for Photovoltaic System. In Proceedings of the International Conference on Intelligent Systems Applications to Power Systems, Kaohsiung, Taiwan, 5–8 November 2007; pp. 442–447.
- Da Silva Fonseca, J.G.; Oozeki, T.; Takashima, T.; Koshimizu, G.; Uchida, Y.; Ogimoto, K. Use of support vector regression and numerically predicted cloudiness to forecast power output of a photovoltaic power plant in Kitakyushu, Japan. Prog. Photovolt. Res. Appl.
**2012**, 20, 874–882. [Google Scholar] [CrossRef] - Shi, J.; Lee, W.J.; Liu, Y.; Yang, Y.; Wang, P. Forecasting power output of photovoltaic systems based on weather classification and support vector machines. IEEE Trans. Ind. Appl.
**2012**, 48, 1064–1069. [Google Scholar] [CrossRef] - Fernandez-Jimenez, L.A.; Muñoz-Jimenez, A.; Falces, A.; Mendoza-Villena, M.; Garcia-Garrido, E.; Lara-Santillan, P.M.; Zorzano-Alba, E.; Zorzano-Santamaria, P.J. Short-term power forecasting system for photovoltaic plants. Renew. Energy
**2012**, 44, 311–317. [Google Scholar] [CrossRef] - Lorenz, E.; Heinemann, D.; Kurz, C. Local and regional photovoltaic power prediction for large scale grid integration: Assessment of a new algorithm for snow detection. Prog. Photovolt. Res. Appl.
**2012**, 20, 760–769. [Google Scholar] [CrossRef] - Krömer, P.; Prokop, L.; Snášel, V.; Mišák, S.; Platoš, J.; Abraham, A. Evolutionary Prediction of Photovoltaic Power Plant Energy Production. In Proceedings of International Conference on Genetic and Evolutionary Computation, Philadelphia, PA, USA, 7–11 July 2012; pp. 35–42.
- Sivanandam, S.N.; Deepa, S.N. Introduction to Genetic Algorithms; Springer-Verlag: Berlin, Germany, 2008. [Google Scholar]
- Arlot, S. A survey of cross-validation procedures for model selection. Statist. Surv.
**2010**, 4, 40–79. [Google Scholar] [CrossRef] - Janjic, Z.; Black, T.; Pyle, M.; Rogers, E.; Chuang, H.-Y.; DiMego, G. High Resolution Applications of the WRF NMM. In Extended Abstract of 21st Conference on Weather Analysis and Forecasting/17th Conference on Numerical Weather Prediction, Washington, DC, USA, 31 July–5 August 2005.

© 2013 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 license (http://creativecommons.org/licenses/by/3.0/).

## Share and Cite

**MDPI and ACS Style**

Monteiro, C.; Santos, T.; Fernandez-Jimenez, L.A.; Ramirez-Rosado, I.J.; Terreros-Olarte, M.S.
Short-Term Power Forecasting Model for Photovoltaic Plants Based on Historical Similarity. *Energies* **2013**, *6*, 2624-2643.
https://doi.org/10.3390/en6052624

**AMA Style**

Monteiro C, Santos T, Fernandez-Jimenez LA, Ramirez-Rosado IJ, Terreros-Olarte MS.
Short-Term Power Forecasting Model for Photovoltaic Plants Based on Historical Similarity. *Energies*. 2013; 6(5):2624-2643.
https://doi.org/10.3390/en6052624

**Chicago/Turabian Style**

Monteiro, Claudio, Tiago Santos, L. Alfredo Fernandez-Jimenez, Ignacio J. Ramirez-Rosado, and M. Sonia Terreros-Olarte.
2013. "Short-Term Power Forecasting Model for Photovoltaic Plants Based on Historical Similarity" *Energies* 6, no. 5: 2624-2643.
https://doi.org/10.3390/en6052624