A photovoltaic power short-term prediction and uncertainty analysis method and system
High-resolution solar irradiance data are obtained through the multi-objective slime mold algorithm, and high-resolution solar irradiance data are obtained through the multi-objective slimming algorithm, and combined with the nuclear density estimation method to analyze the photovoltaic power prediction error, solving the shortcomings of existing short-term prediction methods of photovoltaic power and improving the prediction Accuracy and uncertainty analysis provide confidence intervals for photovoltaic power, supporting more scientific grid scheduling and consumption planning.
Patent Information
- Application Number
- CN202411272947.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-12
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-09-12
AI Technical Summary
The existing short-term prediction methods for photovoltaic power are insufficient in terms of solar irradiance data resolution and acquisition methods, model parameter optimization, meteorological data processing methods, depth and breadth of uncertainty analysis, and cannot effectively describe the distribution of prediction errors, resulting in During the scheduling operation, the system cannot make decisions based solely on photovoltaic deterministic predictions.
Multi-objective mucosmic sterilization algorithm is used to optimize the support vector machine (MOSMA-SVM) model, combine WRF mode to obtain high-resolution solar irradiance forecast data, process meteorological data through mean clustering, and use nuclear density estimation to perform photovoltaic power determination An analysis of uncertainty in predicted results.
It improves the accuracy and accuracy of photovoltaic power prediction, provides a fluctuation space for photovoltaic power, gives confidence intervals for photovoltaic prediction, helps grid scheduling and photovoltaic absorption plans, and enhances the scientificity and reliability of decision-making.
Smart Images

Figure CN118801375B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of photovoltaic power prediction, and in particular to a method and system for short-term photovoltaic power prediction and uncertainty analysis thereof. Background Art
[0002] Vigorously developing renewable energy, improving energy efficiency, promoting energy conservation and emission reduction in key areas, and accelerating the construction of a clean, low-carbon, safe and efficient energy system have a driving effect. Under the influence of multiple factors such as the minimum responsibility weight for the consumption of non-hydro renewable energy, photovoltaic installed capacity is growing rapidly. However, the weather conditions are complex and changeable, and the photovoltaic output power has shown characteristics such as volatility and randomness. The volatility of photovoltaic power generation in the power grid will have a great impact on its safe and stable operation. The formulation of photovoltaic consumption plans also requires photovoltaic power prediction results.
[0003] The Chinese patent with announcement number CN113159102B discloses a multi-time scale photovoltaic power prediction method and system, which is committed to improving the prediction accuracy and provides steps for data preprocessing, building a composite prediction model, considering the influence of meteorological factors, performing uncertainty analysis and short-term prediction. However, the patent with announcement number CN113159102B has certain deficiencies in the resolution and acquisition method of solar irradiance data, the optimization method of model parameters, the processing method of meteorological data, the depth and breadth of uncertainty analysis, and the systematicity and comprehensiveness. In addition, a single prediction value cannot effectively describe the distribution of prediction errors, and the system needs spare capacity based solely on photovoltaic deterministic predictions during scheduling operations.
[0004] Therefore, it is of great significance to construct a photovoltaic power short-term prediction and uncertainty analysis method and system to solve the above problems. Summary of the invention
[0005] In order to solve the problems existing in the background technology, the present invention aims to provide a photovoltaic power short-term prediction method and its uncertainty method based on multi-objective slime mold algorithm to optimize support vector machine, introduce WRF mode to obtain solar irradiance forecast data, cluster and classify meteorological data by mean clustering, optimize support vector machine (SVM) by multi-objective slime mold algorithm (MOSMA), construct MOSMA-SVM prediction model, and then use kernel density estimation method to perform uncertainty analysis on the deterministic prediction results of photovoltaic power. This method improves the power prediction accuracy and provides the fluctuation space of photovoltaic predicted power.
[0006] The present invention provides a photovoltaic power short-term prediction and uncertainty analysis method, which comprises the following steps:
[0007] S1. Data preparation and preprocessing: Obtain weather forecast data on solar irradiance, temperature and wind speed in the target area; clean the historical power data of the photovoltaic power station and remove bad data; classify the photovoltaic power station data into three weather types: clear, cloudy and rainy according to the historical measured irradiance and time period;
[0008] S2. Solar irradiance prediction and correction: Use the WRF-Solar model to obtain the solar irradiance forecast data of the target area; divide the daily solar irradiance data into three periods: morning, noon, and afternoon; perform K-means cluster analysis on the measured historical data of solar irradiance in each period;
[0009] S3. Model output statistical correction: The model output statistical method is used to select meteorological factors and construct correction equations to correct the solar irradiance forecast output by WRF-Solar.
[0010] S4. Construction and verification of photovoltaic power prediction model: Take weather forecast data as input and photovoltaic power station historical power data as output to build a photovoltaic power prediction model; use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor of the support vector machine SVM, and build the MOSMA-SVM photovoltaic power prediction model; train the model on the training set, and verify the prediction performance of the model on the test set, and use the root mean square error RMSE and mean absolute percentage error MAPE indicators to evaluate the model;
[0011] S5. Uncertainty analysis of photovoltaic power: The prediction error of the MOSMA-SVM model is analyzed using the kernel density estimation method KDE to obtain the distribution of the prediction error. Then, under a given confidence level, the boundary value of the prediction error is calculated, and the confidence interval of the photovoltaic power prediction is given in combination with the deterministic prediction results.
[0012] In a preferred solution, the specific process of step S2 includes:
[0013] S21. Divide the daily solar irradiance data into three periods: 9:00-11:45, 12:00-14:45, and 15:00-17:45;
[0014] S22. K-means algorithm is used to cluster the measured historical data of solar irradiance in each period and divide them into three weather types: clear, cloudy, and rainy.
[0015] In a preferred solution, the specific process of step S3 includes:
[0016] S31. Use the model output statistical MOS method to correct the solar irradiance forecast output by WRF-Solar;
[0017] S32, select shortwave radiation flux, 2m air temperature, surface temperature, surface pressure, 10m radial component meteorological factors, and construct the correction equation as follows:
[0018]
[0019] In the formula, y is the correlation coefficient of each factor, x is the relevant variable, are independent random variables; after correlation analysis, the model output statistical correction equation is constructed to correct the solar irradiance forecast data output by the WRF model.
[0020] In a preferred embodiment, step S4 comprises the following steps:
[0021] S41, select prediction model: use support vector machine SVM as prediction model;
[0022] S42, optimize model parameters: use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor parameters of SVM to improve prediction accuracy;
[0023] S43, model training and verification: divide the data set into training set and test set; use the training set data to train the MOSMA-SVM prediction model; verify the prediction performance of the model on the test set, and use RMSE and MAPE indicators to evaluate the model.
[0024] In a preferred solution, the specific process of step S4 includes:
[0025] The weather forecast data is used as input and the historical power data of photovoltaic power plants is used as output to build a short-term photovoltaic power prediction model. The support vector machine is used to build the prediction model. The optimal hyperplane It can be obtained by making a nonlinear mapping. When the sample set is linearly separable, the optimization problem is as follows:
[0026]
[0027] In the formula, Defined as a vector x The modulus value of the optimal classification hyperplane is ; When the samples are linearly inseparable, add slack variables , penalty factor C Represents the tolerance to outliers; by introducing the kernel function and Lagrange multipliers , we can get the following formula:
[0028]
[0029] In order to improve the speed and efficiency of support vector machine parameter selection, the multi-objective slime mold algorithm is used to select and optimize the support vector machine kernel function parameters and error penalty factor parameters; it includes three stages: approaching food stage, surrounding food stage and grabbing food stage, which are described mathematically as follows;
[0030] During the foraging process, the position update formula of slime mold can be simulated by the following formula:
[0031]
[0032] In the formula, Represents the upper bound of the search range, represents the lower bound of the search range, limiting the activity range of the slime mold individual; x represents the current position of the slime mold individual and is a key variable for algorithm optimization and updating; r and rand is a random number between 0 and 1, which introduces randomness into the search process of slime mold. rand Can help the algorithm find the global optimal solution; z It is a constant parameter and plays a key regulatory role; t Indicates the number of iterations of the current algorithm; and are two positions randomly selected from the entire slime mold population; It indicates the location with the highest food concentration found by the slime mold individuals; represents the quality of slime mold; It is a value that decreases linearly from 1 to 0, as shown below:
[0033]
[0034] in, The parameters are as follows:
[0035]
[0036] Based on the best location found so far To update the position of the slime mold individual x ,parameter The position can be fine-tuned, and the parameters and The combined effect of determines the search speed and search range of slime mold individuals;
[0037]
[0038] In the formula , represents the fitness of slime mold individual x, Represents the value of the best fitness obtained during the iteration process; fitness evaluation refers to evaluating the quality of the slime mold position according to the defined goal; the best fitness during the iteration process is used to guide the search process of the slime mold; is the maximum number of iterations; The formula is as follows:
[0039]
[0040]
[0041] The formula simulates the positive and negative feedback mechanism between food concentration and the width of slime mold veins; Represents the current individual fitness of slime mold Ranked in the first half of the overall fitness, it simulates the behavior of slime mold changing its search method according to the concentration of food; is a random number in the range [0,1], indicating the uncertainty of venous contraction; is a sequence sorted by fitness, and Represent the best fitness and the worst fitness respectively; log The change trend of contraction frequency can be made more stable; the change of slime mold vein width is , and These three parameters together represent the oscillation frequency of slime mold around “1” at different food concentrations, Parameter representation; parameter and The synergistic effect can mimic the selection behavior of slime mold.
[0042] In a preferred embodiment, step S5 comprises the following steps:
[0043] S51. Error distribution analysis: Use the kernel density estimation method KDE to analyze the prediction error distribution of the MOSMA-SVM model; draw the probability density curve of the prediction error to obtain the distribution of the error;
[0044] S52, confidence interval calculation: According to the probability density distribution function obtained by the KDE method, the upper and lower bounds of the error under a given confidence level such as 95% are calculated; combined with the deterministic prediction results of the MOSMA-SVM model, the confidence interval of the photovoltaic power prediction is given;
[0045] In the preferred solution, MOSMA and SMA in step S5 use the same mechanism for convergence; first, the population is initialized in the solution space, the fitness of the randomly generated population is calculated, then the population is non-dominated sorted and the crowding distance is calculated, the population position is updated to obtain a new population, and finally the elite strategy is used to select the merged population until the iteration ends and the optimal solution is output.
[0046] The penalty parameters and kernel parameters in the SVM prediction model have the greatest impact on the prediction accuracy. MOSMA is used to optimize the parameters of SVM. The modeling steps of the MOSMA-SVM prediction model are as follows:
[0047] Step 1: Divide the data set into training data and prediction data, and normalize the data;
[0048] Step 2: Initialize the parameters of the MOSMA and SVM models; the number of slime mold populations, the maximum number of iterations, the spatial dimension of slime mold individuals, and the upper and lower bounds of the slime mold population positions;
[0049] Step 3: Calculate the fitness of the population, calculate the non-dominated solution, save it to Pareto, sort it according to the crowding mechanism, and rank it;
[0050] Step 4: Update the position of the slime mold and calculate the fitness of the population after the position is updated;
[0051] Step 5: Merge the new and old populations, sort the fitness of the merged population as much as possible by non-dominant order, select the individuals to be retained as the new parents according to the crowding degree, and enter the iteration;
[0052] Step 6: Continue to iterate until the maximum number of iterations is reached, terminate the optimization search, output the Pareto final solution of the multi-objective optimization problem, and build a MOSMA-SVM prediction model.
[0053] The prediction error of the MOSMA-SVM model is analyzed by the kernel density estimation method to obtain the distribution of the photovoltaic power prediction error. Then, combined with the deterministic prediction results of the MOSMA-SVM model, a confidence interval with a confidence level of 95% is given.
[0054] The core idea of the nonparametric kernel density estimation method is to construct the overall density distribution by considering the local information around each sample point. The mathematical description is as follows: is the density function of the random variable x, , the distribution estimation expression of x by KDE method is:
[0055]
[0056] In the above formula, his a non-negative number, indicating bandwidth; this parameter determines the contribution range of each sample point to the density estimation. If h is selected too large, the estimated result may be too smooth and unable to fit the local characteristics of the data. If h is selected too small, the influence range of each sample point will be very narrow, resulting in serious noise and unable to reflect the overall trend of the data. n represents the total number of samples to be estimated, F(x) is the empirical distribution function of the sample, as shown below:
[0057]
[0058] In the above formula, x i For the i samples, each sample point is assigned a weight, and this weight is calculated using the kernel function K To calculate, the present disclosure selects a Gaussian kernel, and its expression is as follows:
[0059]
[0060] By substituting the Gaussian kernel function into the empirical distribution function, we can get the probability density estimation based on the Gaussian kernel. The probability density distribution function based on the Gaussian kernel density estimation is shown as follows:
[0061]
[0062] The process of analyzing the uncertainty of photovoltaic power generation using the kernel density estimation method is as follows: first, the distribution of photovoltaic power prediction errors is analyzed using the kernel density estimation method, then the boundary value of the error interval under a given confidence level is calculated, and finally the deterministic prediction results and confidence intervals of photovoltaic power are output;
[0063] Photovoltaic power error e is the actual value of the photovoltaic power With the predicted value Deviation:
[0064]
[0065] It is i The prediction error at time e , given a confidence level (1- ) is calculated as:
[0066]
[0067] in is expressed as the significant level, , They are the confidence levels (1- ) under the error upper and lower boundaries; obtain the probability density distribution function through the KDE method, and then calculate the cumulative probability density function, and determine the upper and lower bounds of the error under a given confidence level through the cumulative density function curve:
[0068]
[0069]
[0070] In the formula F Indication error e The probability of falling into a certain interval can then be calculated to find the boundary value of the photovoltaic power error at a given confidence level. Combined with the deterministic prediction results, the upper and lower bounds of the power prediction interval can be given:
[0071]
[0072]
[0073] The confidence interval of the photovoltaic power prediction at a given confidence level is [ , ].
[0074] The preferred solution further includes a step S6 of performance calculation and evaluation, and the specific process of S6 includes:
[0075] The prediction interval coverage rate PICP, the average prediction interval width MPIW and the Winkler score Score index are calculated to evaluate the interval prediction performance of PV power prediction and ensure that the prediction results cover more actual values while maintaining a reasonable prediction interval width.
[0076] The present invention also provides a photovoltaic power short-term prediction and uncertainty analysis system, comprising:
[0077] Data preparation and preprocessing module: used to obtain weather forecast data of solar irradiance, temperature and wind speed in the target area; clean the historical power data of photovoltaic power stations and remove bad data; classify photovoltaic power station data into three types of weather: clear, cloudy and rainy according to the historical measured irradiance and time period;
[0078] Solar irradiance prediction and correction module: used to obtain solar irradiance forecast data of the target area using the WRF-Solar model; divide the daily solar irradiance data into three periods: morning, noon, and afternoon; perform K-means clustering analysis on the measured historical data of solar irradiance in each period;
[0079] Model output statistical correction module: It is used to adopt the model output statistical method, select meteorological factors, construct the correction equation, and correct the solar irradiance forecast value output by WRF-Solar;
[0080] Photovoltaic power prediction model construction and verification module: used to take weather forecast data as input and historical power data of photovoltaic power stations as output to build a photovoltaic power prediction model; use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor of the support vector machine SVM to build a MOSMA-SVM photovoltaic power prediction model; train the model on the training set, and verify the prediction performance of the model on the test set, and use the root mean square error RMSE and mean absolute percentage error MAPE indicators to evaluate the model;
[0081] Photovoltaic power uncertainty analysis module: It is used to analyze the prediction error of the MOSMA-SVM model using the kernel density estimation method KDE, obtain the distribution of the prediction error, and then calculate the boundary value of the prediction error under a given confidence level, and give the confidence interval of the photovoltaic power prediction in combination with the deterministic prediction results.
[0082] The beneficial effects achieved by the present invention are:
[0083] First, the present invention introduces the WRF-Solar model for high-resolution solar irradiance forecasting, and uses the multi-objective slime mold algorithm (MOSMA) to optimize the support vector machine (SVM) parameters to provide high-resolution solar irradiance forecasting, and uses the MOSMA algorithm to optimize the SVM parameters to significantly improve the accuracy of the prediction model. The present invention can adapt to complex and changeable weather conditions and accurately capture the changing characteristics of solar irradiance.
[0084] Second, the present invention divides the daily solar irradiance data into three time periods: morning, noon, and afternoon, and performs K-means cluster analysis on the measured historical data of solar irradiance in each time period, which is divided into three weather types: clear, cloudy, and rainy. Time division and cluster analysis make data processing more refined and can better reflect the changing law of photovoltaic power under different weather conditions. Through cluster analysis, data with similar characteristics are classified into one category, which reduces the complexity and calculation amount of model training and improves prediction efficiency.
[0085] Third, the present invention adopts the model output statistical method to correct the solar irradiance forecast value output by WRF-Solar. By selecting relevant meteorological factors to construct the correction equation, the systematic error of WRF-Solar forecast is effectively reduced and the accuracy of the forecast is improved. The correction method makes the prediction model more stable and reliable, and can adapt to different weather conditions and forecast errors.
[0086] Fourth, the present invention uses the kernel density estimation method (KDE) to analyze the photovoltaic power prediction error and gives the confidence interval of the photovoltaic power prediction. It not only gives the deterministic prediction value of photovoltaic power, but also provides the fluctuation space of the prediction value, providing more comprehensive information for the formulation of power grid dispatch and photovoltaic consumption plan. The provision of confidence interval enables decision makers to take into account the uncertainty of prediction when formulating strategies, so as to make more scientific and reasonable decisions.
[0087] Fifth, the present invention uses multi-dimensional indicators such as prediction interval coverage (PICP), mean prediction interval width (MPIW) and Winkler score (Score) to evaluate the prediction performance. Multi-dimensional evaluation indicators can comprehensively reflect the performance of the prediction model, including the accuracy, stability and reliability of the prediction. Through the evaluation results, the direction and focus of model improvement can be clarified, providing strong support for model optimization. BRIEF DESCRIPTION OF THE DRAWINGS
[0088] Figure 1 is a system block diagram of the present invention;
[0089] Figure 2 is a flowchart of the WRF-Solar mode operation in Example 1 of the present invention;
[0090] Figure 3 is a solar irradiance forecast result diagram in Example 1 of the present invention;
[0091] Figure 4 It is a diagram of nine data types in Embodiment 1 of the present invention;
[0092] Figure 5 is a flowchart of statistical correction of model output in Embodiment 1 of the present invention;
[0093] Figure 6 is the MOSMA flow chart in Embodiment 1 of the present invention;
[0094] Figure 7 is a flow chart of the prediction model based on MOSMA-SVM in Example 1 of the present invention;
[0095] Figure 8 This is a comparison chart of the prediction results of the six algorithms in Example 1 (9:00-11:45) - sunny;
[0096] Fig. 9 This is a comparison chart of the prediction results of the six algorithms in Example 1 (9:00-11:45) - cloudy;
[0097] Fig.10 This is a comparison chart of the prediction results of the six algorithms in Example 1 (9:00-11:45) - cloudy and rainy;
[0098] Fig.11 This is a comparison chart of the prediction results of the six algorithms in Example 1 (12:00-14:45) - sunny;
[0099] Fig.12 This is a comparison chart of the prediction results of the six algorithms in Example 1 (12:00-14:45) - cloudy;
[0100] Fig.13 This is a comparison chart of the prediction results of the six algorithms in Example 1 (12:00-14:45) - cloudy and rainy;
[0101] Fig.14 This is a comparison chart of the prediction results of the six algorithms in Example 1 (15:00-17:45) - sunny;
[0102] Fig.15 This is a comparison chart of the prediction results of the six algorithms in Example 1 (15:00-17:45) - cloudy;
[0103] Fig.16 This is a comparison chart of the prediction results of the six algorithms in Example 1 (15:00-17:45) - cloudy and rainy. DETAILED DESCRIPTION
[0104] The technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the present invention. In addition, the forms of the various structures recorded in the following embodiments are merely illustrative, and the present invention is not limited to the various structures recorded in the following embodiments. All other embodiments obtained by ordinary technicians in this field without making creative work belong to the scope of protection of the present invention.
[0105] Reference Figure 1-Figure 16 , the present invention introduces the WRF model to obtain solar irradiance forecast data, and adopts the model output statistical method to correct the solar irradiance forecast result. The method requires configuring the area to be simulated, inserting various terrain data into the grid points of the pattern, and establishing "static" ground data, that is, defining the projection, regional range, nested relationship and surface parameter interpolation of the model. Then, the required meteorological parameters are extracted and interpolated to the simulation area, and finally the weather output file of the simulated grid of the WRF system is run to obtain the required weather variables.
[0106] Example 1. This example uses the historical data of the Desert Garden Power Station (105.9kW) at Eggland Airport to analyze the proposed algorithm example, and compares it with particle swarm optimization support vector machine (ISO-SVM), whale optimization vector machine (WOA-SVM), radial basis function neural network (RBFNN), long short-term memory network (LSTM), and convolutional neural network (CNN). First, the historical data of the photovoltaic power station is cleaned to remove bad data, and then the photovoltaic power station data is divided into types according to the historical measured irradiance size and time period. WRF-Solar is introduced to obtain the irradiance forecast value and correct the forecast result. The local wind speed and temperature forecast data are crawled, and together with the solar irradiance data, they constitute the weather forecast data for the support vector machine input. The MOSMA-SVM algorithm is used to construct a prediction model for weather forecast data and historical photovoltaic power data. The kernel density estimation method is used to calculate the probability density distribution of the prediction error, and the confidence interval is obtained using the probability density distribution characteristics. The overall framework is as follows: Figure 1 shown.
[0107] Based on WRF-Solar, triple nesting is set, with Uluru in Australia as the forecast center (25.190°S, 130.976°E). The horizontal resolution of the first nesting area is 27km*27km, and the number of grids in the outermost layer is 99*102. The horizontal resolution of the second nesting area is 9km*9km, and the number of grids in the simulation area is 127*127. The horizontal resolution of the third nesting area is 3km*3km, and the number of grids in the simulation area is 88*97. The vertical direction of the model is set to 27 layers. The operation process is as follows: Figure 2 shown.
[0108] like Figure 3 Shown is the prediction result of solar irradiance after the WRF-Solar model runs the data visualization.
[0109] After obtaining the solar irradiance forecast data, the daily data is first processed by time periods. The daily data is divided into three periods: morning (9:00-11:45), noon (12:00-14:45), and afternoon (15:00-17:45). The K-means algorithm is used to cluster and classify the historical data of solar irradiance measurements in each period into three weather types: clear, cloudy, and rainy. In summary, the time series of solar irradiance measurements are divided into nine types in each quarter, such as Figure 4 shown.
[0110] The solar irradiance forecast data of these nine data types are corrected using the model output statistics. The correction process based on the MOS method is as follows: Figure 5 shown.
[0111] like Figure 6The figure shows the construction process of the multi-objective slime mold algorithm. The multi-objective slime mold algorithm is used to optimize the support vector machine and build a MOSMA-SVM photovoltaic power short-term prediction model. The specific process is as follows Figure 7 In order to better demonstrate the prediction capabilities of the algorithm proposed in this paper, particle swarm optimization support vector machine, whale algorithm optimization support vector machine and three deep learning algorithms (radial basis function neural network, long short-term memory network, convolutional neural network) are used for comparison to build prediction models for these nine data types. Figure 8 , Fig. 9 , Fig.10 The following are the forecast results for three types of weather during the time period (9:00-11:45). Figure 8 The prediction results for clear weather data are shown below. The left side is the training set and the right side is the test set. Fig. 9 This is the forecast result for cloudy days. Fig.10 Predict results for rainy day data. Fig.11 , Fig.12 , Fig.13 The forecast results of three weather types in the time period (12:00-14:45) are: Fig.14 , Fig.15 , Fig.16 The results are for the time period (15:00-17:45). The two model evaluation indicators, RMSE and MAPE, were calculated to evaluate the performance of the prediction models constructed by the six algorithms used. The results are shown in Table 1. From the table, it can be seen that compared with other models, the MOSMA-SVM prediction algorithm proposed in this paper has a lower MAPE, and the prediction performance is still improved, and the prediction accuracy is also high.
[0112] The prediction error of the MOSMA-SVM model was analyzed by non-parametric kernel density estimation method, and the distribution of photovoltaic power prediction error was obtained. Combined with the deterministic prediction results of photovoltaic power, the fluctuation range of photovoltaic power with 95% confidence was analyzed. The uncertainty analysis of photovoltaic power output prediction power was still carried out according to nine data types, and the uncertainty analysis of the deterministic prediction results of the MOSMA-SVM power model was carried out by non-parametric kernel density estimation method.
[0113] In order to calculate the confidence interval of photovoltaic power prediction, the probability density distribution of photovoltaic power prediction error must be determined first. In order to verify whether the method used in this paper is superior, the parametric Gaussian distribution method is selected as a comparison, and the power prediction error distribution is fitted respectively.
[0114] The interval evaluation indicators of the KDE method at the 95% confidence level are calculated: prediction interval coverage (PICP), prediction interval mean width (MPIW) and Winkler score (Score). The results are shown in Table 2. It can be seen from the table that the coverage of the interval obtained by the KDE method is higher than that of the interval obtained by the Gaussian distribution in most cases. The interval coverage of the Gaussian distribution is high in the case of cloudy and rainy weather from 9 to 11 o'clock, which may be caused by the excessive width of the interval obtained by the Gaussian distribution under this data type. In general, the interval score obtained by the KDE method is much better than that of the Gaussian distribution. Therefore, the results show that the KDE method can better describe the distribution range of the prediction interval of photovoltaic power generation.
[0115] Table 1 Prediction performance evaluation in Example 1 (test set);
[0116]
[0117] Table 2 Interval evaluation indicators of nine data types in Example 1 (test set)
[0118]
[0119] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A photovoltaic power short-term prediction and uncertainty analysis method, characterized in that: It includes the following steps: S1. Data preparation and preprocessing: Obtain weather forecast data on solar irradiance, temperature and wind speed in the target area; clean the historical power data of the photovoltaic power station and remove bad data; classify the photovoltaic power station data into three weather types: clear, cloudy and rainy according to the historical measured irradiance and time period; S2. Solar irradiance prediction and correction: Use the WRF-Solar model to obtain the solar irradiance forecast data of the target area; divide the daily solar irradiance data into three periods: morning, noon, and afternoon; perform K-means cluster analysis on the measured historical data of solar irradiance in each period; S3. Model output statistical correction: The model output statistical method is used to select meteorological factors and construct correction equations to correct the solar irradiance forecast output by WRF-Solar. S4. Construction and verification of photovoltaic power prediction model: Take weather forecast data as input and photovoltaic power station historical power data as output to build a photovoltaic power prediction model; use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor of the support vector machine SVM, and build the MOSMA-SVM photovoltaic power prediction model; train the model on the training set, and verify the prediction performance of the model on the test set, and use the root mean square error RMSE and mean absolute percentage error MAPE indicators to evaluate the model; S5. Uncertainty analysis of photovoltaic power: The prediction error of the MOSMA-SVM model is analyzed using the kernel density estimation method KDE to obtain the distribution of the prediction error. Then, under a given confidence level, the boundary value of the prediction error is calculated, and the confidence interval of the photovoltaic power prediction is given in combination with the deterministic prediction results. In step S5, MOSMA and SVM use the same mechanism for convergence; elite non-dominated sorting is introduced in MOSMA, and the excellent individuals in the parent generation are retained and directly enter the child generation, and non-dominated sorting is performed together to prevent the loss of the Pareto optimal solution; the crowding distance operator is introduced to maintain the diversity of the population, so that SMA can handle multi-objective optimization problems; first, the population is initialized in the solution space, the fitness of the randomly generated population is calculated, and then the population is non-dominated sorted and the crowding distance is calculated, the population position is updated to obtain a new population, and finally the elite strategy is used to select the merged population until the iteration ends and the optimal solution is output; The penalty parameters and kernel parameters in the SVM prediction model have the greatest impact on the prediction accuracy; MOSMA is used to optimize the selection of SVM parameters; The modeling steps of the MOSMA-SVM prediction model are as follows: Step 1: Divide the data set into training data and prediction data, and normalize the data; Step 2: Initialize the parameters of the MOSMA and SVM models; the number of slime mold populations, the maximum number of iterations, the spatial dimension of slime mold individuals, and the upper and lower bounds of the slime mold population positions; Step 3: Calculate the fitness of the population, calculate the non-dominated solution, save it to Pareto, sort it according to the crowding mechanism, and rank it; Step 4: Update the position of the slime mold and calculate the fitness of the population after the position is updated; Step 5: Merge the new and old populations, sort the fitness of the merged population as much as possible by non-dominant order, select the individuals to be retained as the new parents according to the crowding degree, and enter the iteration; Step 6: Continue to iterate until the maximum number of iterations is reached, terminate the optimization search, output the Pareto final solution of the multi-objective optimization problem, and build a MOSMA-SVM prediction model.
2. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: The specific process of step S2 includes: S21. Divide the daily solar irradiance data into three periods: 9:00-11:45, 12:00-14:45, and 15:00-17:45; S22. K-means algorithm is used to cluster the measured historical data of solar irradiance in each period and divide them into three weather types: clear, cloudy, and rainy.
3. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: The specific process of step S3 includes: S31. Use the model output statistical MOS method to correct the solar irradiance forecast output by WRF-Solar; S32, select shortwave radiation flux, 2m air temperature, surface temperature, surface pressure, 10m radial component meteorological factors, and construct the correction equation as follows: In the formula, N is the number of highly correlated factors in the WRF model output, y is the correlation coefficient of each factor, x 1, x 2… x N is the relevant variable, β 0 ,β 1… β N is the regression coefficient, are independent random variables; after correlation analysis, the model output statistical correction equation is constructed to correct the solar irradiance forecast data output by the WRF model.
4. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: Step S4 includes the following steps: S41, select prediction model: use support vector machine SVM as prediction model; S42, optimize model parameters: use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor parameters of SVM to improve prediction accuracy; S43, model training and verification: divide the data set into training set and test set; use the training set data to train the MOSMA-SVM prediction model; verify the prediction performance of the model on the test set, and use RMSE and MAPE indicators to evaluate the model.
5. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 4 is characterized by: The specific process of step S4 includes: The weather forecast data is used as input and the historical power data of photovoltaic power plants is used as output to build a short-term photovoltaic power prediction model. The support vector machine is used to build the prediction model. The optimal hyperplane It can be obtained by making a nonlinear mapping. When the sample set is linearly separable, the optimization problem is as follows: In the formula, Defined as the modulus of vector x, the classification interval value of the optimal classification hyperplane is ; When the samples are linearly inseparable, add slack variables , the penalty factor C represents the tolerance to outliers; by introducing the kernel function and Lagrange multipliers , we can get the following formula: The mapping form and feature space defined by different kernel functions determine the degree to which the nonlinearity of the system is captured. The support vector machine uses the inner product kernel function to replace the nonlinear mapping to the high-dimensional space. Its penalty coefficient and kernel parameters directly affect the learning accuracy and generalization ability of the model and determine the performance of the support vector machine. In order to improve the speed and efficiency of the support vector machine parameter selection, the multi-objective slime mold algorithm is used to realize the selection and optimization of the support vector machine kernel function parameters and error penalty factor parameters. It includes three stages: approaching food stage, surrounding food stage and grabbing food stage, which are described as follows by mathematical methods. During the foraging process, the position update formula of slime mold can be simulated by the following formula: In the formula, Represents the upper bound of the search range, Represents the lower bound of the search range, limiting the activity range of slime mold individuals; x Represents the current position of the slime mold individual; r and rand is a random number between 0 and 1, which introduces randomness into the search process of slime mold. rand Can help the algorithm find the global optimal solution; z It is a constant parameter and plays a key regulatory role; t Indicates the number of iterations of the current algorithm; and are two positions randomly selected from the entire slime mold population; It indicates the location with the highest food concentration found by the slime mold individuals; represents the quality of slime mold; It is a value that decreases linearly from 1 to 0, as shown below: in, The parameters are as follows: Based on the best location found so far To update the position of the slime mold individual x ,parameter Fine-tune the position, and the parameters and The combined effect of the factors determines the search speed and search range of the slime mold individuals; In the above formula , Representative slime mold individuals x The fitness of Represents the value of the best fitness obtained during the iteration process; fitness evaluation refers to evaluating the quality of the slime mold position according to the defined goal; the best fitness during the iteration process is used to guide the search process of the slime mold; is the maximum number of iterations; The formula is as follows: The formula simulates the positive and negative feedback mechanism between food concentration and the width of slime mold veins; Represents the current individual fitness of slime mold Ranked in the first half of the overall fitness, it simulates the behavior of slime mold changing its search method according to the concentration of food; is a random number in the range [0,1], indicating the uncertainty of venous contraction; is a sequence sorted by fitness, and Represent the best fitness and the worst fitness respectively; log The change trend of contraction frequency is relatively stable; the change of slime mold vein width is , and These three parameters together represent the oscillation frequency of slime mold around "1" at different food concentrations, Parameter representation; parameter and The synergistic effect simulates the selection behavior of slime mold.
6. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: Step S5 includes the following steps: S51. Error distribution analysis: Use the kernel density estimation method KDE to analyze the prediction error distribution of the MOSMA-SVM model; draw the probability density curve of the prediction error to obtain the distribution of the error; S52. Confidence interval calculation: Based on the probability density distribution function obtained by the KDE method, the upper and lower bounds of the error under a given confidence level such as 95% are calculated; combined with the deterministic prediction results of the MOSMA-SVM model, the confidence interval of the photovoltaic power prediction is given.
7. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: In step S5, the deterministic prediction of photovoltaic power is realized by MOSMA-SVM, but the fluctuation space of the predicted value is not analyzed. Therefore, the prediction error of the MOSMA-SVM model is analyzed by the kernel density estimation method to obtain the distribution of the photovoltaic power prediction error. Then, combined with the deterministic prediction results of the MOSMA-SVM model, a confidence interval with a confidence level of 95% is given. The core idea of the nonparametric kernel density estimation method is to construct the overall density distribution by considering the local information around each sample point. The mathematical description is as follows: is a random variable x The density function of , by KDE method x The distribution estimation expression of is: In the above formula, h is a non-negative number, indicating the bandwidth; this parameter determines the contribution range of each sample point to the density estimation; n represents the total number of samples to be estimated, F(x) is the empirical distribution function of the sample, as shown below: In the above formula, x i For the i samples, each sample point is assigned a weight, and this weight is calculated using the kernel function K To calculate, the present disclosure selects the Gaussian kernel, and its expression is as follows: By substituting the Gaussian kernel function into the empirical distribution function, we get the probability density estimation based on the Gaussian kernel. The probability density distribution function based on the Gaussian kernel density estimation is shown as follows: The process of analyzing the uncertainty of photovoltaic power generation using the kernel density estimation method is as follows: first, the distribution of photovoltaic power prediction errors is analyzed using the kernel density estimation method, then the boundary value of the error interval under a given confidence level is calculated, and finally the deterministic prediction results and confidence intervals of photovoltaic power are output; Photovoltaic power error e is the actual value of photovoltaic power With the predicted value Deviation: is the prediction error at the i-th moment, for the error e , given a confidence level The probability calculation formula is: in is expressed as the significant level, , The confidence levels are The upper and lower bounds of the error are obtained by the KDE method, and then the cumulative probability density function is obtained. The upper and lower bounds of the error under a given confidence level are determined by the cumulative density function curve: In the formula F Indication error e The probability of falling into a certain interval is calculated, and then the boundary value of the photovoltaic power error under a given confidence level is calculated. Combined with the deterministic prediction results, the upper and lower bounds of the power prediction interval are given: The confidence interval of the photovoltaic power prediction at a given confidence level is [ , ].
8. The photovoltaic power short-term prediction and uncertainty analysis method according to claim 1 is characterized by: The step S6 of performance calculation and evaluation is also included. The specific process of S6 includes: The prediction interval coverage rate PICP, the average prediction interval width MPIW and the Winkler score Score index are calculated to evaluate the interval prediction performance of PV power prediction and ensure that the prediction results cover more actual values while maintaining a reasonable prediction interval width.
9. A photovoltaic power short-term prediction and uncertainty analysis system, using the photovoltaic power short-term prediction and uncertainty analysis method according to any one of claims 1 to 8, characterized in that: include: Data preparation and preprocessing module: used to obtain weather forecast data of solar irradiance, temperature and wind speed in the target area; clean the historical power data of photovoltaic power stations and remove bad data; classify photovoltaic power station data into three types of weather: clear, cloudy and rainy according to the historical measured irradiance and time period; Solar irradiance prediction and correction module: used to obtain solar irradiance forecast data of the target area using the WRF-Solar model; divide the daily solar irradiance data into three periods: morning, noon, and afternoon; perform K-means clustering analysis on the measured historical data of solar irradiance in each period; Model output statistical correction module: It is used to adopt the model output statistical method, select meteorological factors, construct the correction equation, and correct the solar irradiance forecast value output by WRF-Solar; Photovoltaic power prediction model construction and verification module: used to take weather forecast data as input and historical power data of photovoltaic power stations as output to build a photovoltaic power prediction model; use the multi-objective slime mold algorithm MOSMA to optimize the kernel function parameters and error penalty factor of the support vector machine SVM to build a MOSMA-SVM photovoltaic power prediction model; train the model on the training set, and verify the prediction performance of the model on the test set, and use the root mean square error RMSE and mean absolute percentage error MAPE indicators to evaluate the model; Photovoltaic power uncertainty analysis module: It is used to analyze the prediction error of the MOSMA-SVM model using the kernel density estimation method KDE, obtain the distribution of the prediction error, and then calculate the boundary value of the prediction error under a given confidence level, and give the confidence interval of the photovoltaic power prediction in combination with the deterministic prediction results.
Citation Information
Patent Citations
A method and system for predicting photovoltaic power across multiple time scales
CN113159102B
A photovoltaic power generation power prediction method based on support vector machine regression
CN109685257A
Prediction method for output power of short-term photovoltaic power generation
CN113159437A