Wind power prediction method and system for areas lacking wind measurement data by adopting BP neural network
The BP neural network method integrates ERA5 reanalysis data with historical wind farm data to overcome data scarcity issues, enabling accurate wind power forecasting and enhancing power system stability.
Patent Information
- Application Number
- CN202411200531.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-29
- Publication Date
- 2024-12-20
AI Technical Summary
Existing wind power prediction methods face challenges in areas lacking wind measurement data, making it difficult to accurately forecast wind power in the early stages of projects or regions with insufficient or low-quality data.
A method using a BP neural network that combines historical wind farm data with ERA5 reanalysis data, employing inverse distance weighting for interpolation, data normalization, and a BP neural network model to predict wind power.
Provides timely and accurate wind power predictions, reducing the impact on power system operation and grid dispatching by improving data availability in data-scarce regions.
Smart Images

Figure CN119168134A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of wind farm wind power prediction, and in particular to a method and system for predicting wind power in areas lacking wind measurement data by using a BP neural network. Background Art
[0002] With the proposal of my country's "dual carbon" goals, the low-carbon green energy strategy has become the mainstream energy development strategy worldwide. The proportion of wind power installed capacity in my country's power energy supply has gradually increased, and it has gradually assumed the task of peak and frequency regulation of the power grid. However, wind is random and volatile. With the access of a large number of wind power to the power grid, it has brought certain negative impacts on the operation control of the power system and the grid dispatching plan.
[0003] Wind power forecasting can determine the regulation space of wind power in the future. It is an effective means to improve the regulation capacity of wind turbines. It is of great significance to wind power consumption and the stability of the power grid system. Therefore, efficient and accurate prediction of wind power is crucial to improving wind power consumption and improving the overall stability of the power system.
[0004] Most wind power forecasts use the meteorological data and historical data of the wind farm to predict the output power of the entire wind farm. Commonly used methods include machine learning and neural networks. Among them, BP neural network has strong nonlinear mapping capabilities and can also analyze and predict data with nonlinear relationships. When using BP neural network to predict wind power, the commonly used characteristic elements are meteorological data such as wind speed and wind direction. These meteorological data are often difficult to obtain. Therefore, it is difficult to predict wind power in the early stage of wind power projects and in areas where data is lacking or difficult to obtain.
[0005] ERA5 is the fifth generation of reanalysis global climate data products released by the European Centre for Medium-Range Weather Forecasts (ECMWF) after ERA-Interim. This data product series combines observational data and numerical models, and has the advantages of high temporal and spatial resolution, fast update, and multiple parameters. Up to now, ECMWF has released all data after 1950, with a temporal resolution of 1h and a horizontal resolution of 0.25°×0.25°. The data set is continuously updated daily. ERA5 combines meteorological observations with model data, and its wind speed accuracy is at the world's leading level under medium and low wind speed conditions. It can be a feasible reference solution for predicting wind power in areas where there is a lack of observational data or the quality of observational data is not high. Summary of the invention
[0006] In response to the current problems, the present invention provides a method and system for predicting wind power in areas lacking wind measurement data using a BP neural network, to solve the problem that it is difficult to predict wind power in the early stages of wind power projects and in areas lacking data or where it is difficult to obtain data, and to provide a reference for predicting wind power in areas lacking observation data or with low quality observation data.
[0007] In order to achieve the above object, a method for predicting wind power in areas lacking wind measurement data using a BP neural network comprises the following steps:
[0008] Step 1: Collect historical characteristic data of wind speed, wind direction, temperature and humidity and actual wind power of the wind farm;
[0009] Step 2: Download the ERA5 reanalysis data for the wind farm provided by the European Centre for Medium-Range Weather Forecasts (ECMWF);
[0010] Step 3: Use the inverse distance weighted (IDW) method to interpolate the ERA5 reanalysis data to the location of each unit in the wind farm to obtain the ERA5 meteorological data at the corresponding location of the wind turbine;
[0011] Step 4: Combine historical data of wind farms and ERA5 reanalysis data to construct sample data, remove singular points for each characteristic element in the sample data, and interpolate and supplement data in the time series of removed data points;
[0012] Step 5: Build a BP neural network model, use the downloaded ERA5 reanalysis data as the input element of the model, and use wind power as the output element;
[0013] Step 6: Group the processed sample data into training set and test set;
[0014] Step 7: Normalize each feature element in the sample data;
[0015] Step 8: Process and calculate the input data through the hidden layer inside the BP neural network and output the predicted wind power;
[0016] Step 9: The mean absolute error (MAE), root mean square error (RMSE) and Pearson correlation coefficient (R) were used to evaluate the predicted wind power and the measured wind power.
[0017] In step 2, the ERA5 reanalysis data includes data on 2m relative humidity, surface pressure, surface global radiation, total precipitation, 2m temperature, 100m wind speed, and 100m wind direction.
[0018] In step 3, the calculation process of the inverse distance weighted method interpolation is as follows:
[0019] 3.1 Calculate the distance d from the unknown point to all points i
[0020]
[0021] In the formula, x and y are the horizontal and vertical coordinates corresponding to the unknown point, x i ,y i The horizontal and vertical coordinates correspond to all ERA5 reanalysis data;
[0022] 3.2 Calculate the weight w i
[0023]
[0024] 3.3 Calculate the value of the interpolation point Z0
[0025]
[0026] In the formula, Z(X i ,Y i ) is the corresponding ERA5 reanalysis data in the field area.
[0027] In step 4, the method for interpolating and supplementing data in the time series after removing data points is as follows:
[0028] Y=((X-X1)(Y2-Y1) / (X2-X1))+Y1
[0029] Among them, (X1, Y1) and (X1, Y1) are the known coordinate points, X is the target value, and Y is the result.
[0030] In step 7, the formula for normalizing each characteristic element in the sample data is as follows:
[0031]
[0032] inputs=(inputs-inputs_mean) / inputs_std
[0033]
[0034]
[0035] outputs=(outputs-outputs_mean) / outputs_std
[0036] Among them, inputs_mean is the mean of a certain input element, N is the number of input element data, inputs iis the i-th data of the input, inputs_std is the standard deviation of an input element, inputs is the normalized result of an input element, outputs_mean is the mean of an output element, and outputs i is the i-th data output, outputs_std is the standard deviation of an output element, and outputs is the normalized result of an output element.
[0037] In step 8, the input data is processed and calculated by the hidden layer inside the BP neural network, and the predicted wind power is output, which includes the following process:
[0038] 8.1 Initialize model weights ω, learning rate η, target error E0 and thresholds a0 and b0;
[0039] 8.2 Determine the number of neurons in the hidden layer using an empirical formula, namely:
[0040]
[0041] Among them, h is the number of neurons in the hidden layer; m is the number of neurons in the input layer; n is the number of neurons in the output layer; s is a constant between 1 and 10;
[0042] 8.3 When predicting wind power, the BP neural network first performs forward propagation to calculate the wind power value of the output layer. The formula used is:
[0043]
[0044] in, is the wind power output by the kth neuron in the pth hidden layer, is the weight of the connection between the jth neuron in the p-1th hidden layer and the kth neuron in the pth hidden layer, is the wind power output by the kth neuron in the p-1th hidden layer, is the threshold of the kth neuron in the pth hidden layer, σ is the activation function, and
[0045] 8.4 Calculate the error E between the wind power output by the BP neural network and the actual wind power n for:
[0046]
[0047] in, is the predicted wind power; is the measured value of wind power;
[0048] If the error E nIf the error is greater than the target error E0, the BP neural network will perform back propagation and update the weights. The formula used is as follows:
[0049] W i (n+1)=ΔW ij (n+1)+W kj (n)
[0050] Among them, W ij is the data weight from the input layer to the hidden layer, W kj is the data weight from the hidden layer to the output layer, W i is the updated data weight;
[0051] 8.5 When the error E n When it is less than E0 or the maximum number of iterations is reached, the model ends.
[0052] In step 9, the calculation formulas for the mean absolute error (MAE), root mean square error (RMSE) and Pearson correlation coefficient (R) are as follows:
[0053]
[0054] Among them, W i cal is the wind power forecast value at the i-th moment, W i obs is the measured value of wind power at the i-th moment.
[0055]
[0056] in, Represents the mean values of X and Y samples, σ X , σ Y Represent the standard deviation of X and Y samples respectively.
[0057] An information data processing terminal for realizing the above-mentioned method of using BP neural network to predict wind power in areas lacking wind measurement data.
[0058] A computer-readable storage medium includes instructions, which, when executed on a computer, enable the computer to execute the above-mentioned method for predicting wind power in areas lacking wind measurement data by using a BP neural network.
[0059] Beneficial effects of the invention: The wind power prediction method of the invention solves the problem that wind power prediction is difficult for carrying out preliminary work of wind power projects and in areas where data is lacking or where it is difficult to obtain information data. It predicts wind power in a timely and accurate manner, reduces the number of wind power connected to the power grid, and brings certain negative impacts on power system operation control and power grid dispatching plans. BRIEF DESCRIPTION OF THE DRAWINGS
[0060] Figure 1 A flow chart of the steps of performing wind power prediction in an embodiment of the present invention;
[0061] Figure 2 A comparison chart of ERA5 data and measured data in an embodiment of the present invention;
[0062] Figure 3 It is a trend diagram of wind power changes predicted by the training set and measured in the embodiment of the present invention;
[0063] Figure 4 This is a trend chart of wind power changes predicted and measured by the test set in an embodiment of the present invention. DETAILED DESCRIPTION
[0064] In order to make the purpose, technical solution and advantages of the present invention clearer, the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. The specific embodiments described here are only used to explain the present invention and are not used to limit the present invention.
[0065] like Figure 1 As shown, the wind power prediction method for areas lacking wind measurement data using a BP neural network of the present invention specifically includes the following steps:
[0066] Step 1: Collect historical characteristic data such as wind speed, wind direction, temperature, humidity and actual wind power of the wind farm.
[0067] Step 2: Download ERA5 data such as 2m relative humidity, surface pressure, surface total radiation, total precipitation, 2m temperature, 100m wind speed, and 100m wind direction within the wind farm provided by the European Centre for Medium-Range Weather Forecasts (ECMWF).
[0068] Step 3: Use the inverse distance weighted method (IDW) to interpolate the ERA5 data to the location of each unit in the wind farm to obtain the ERA5 meteorological data at the corresponding location of the wind turbine; the IDW calculation process is as follows:
[0069] Step 3.1: Calculate the distance from the unknown point to all points
[0070]
[0071] Step 3.2: Calculate weights
[0072]
[0073] Step 3.3: Calculate the value of the interpolation point
[0074]
[0075] Step 4: Combine historical data of wind farms and ERA5 data to construct sample data, remove singular points for each characteristic element in the sample data, and interpolate and supplement data in the time series of the removed data points; the formula of the interpolation method is as follows:
[0076] Y=((X-X1)(Y2-Y1) / (X2-X1))+Y1
[0077] Among them, (X1, Y1) and (X1, Y1) are the known coordinate points, X is the target value, and Y is the result.
[0078] In this example, the hourly wind speed and wind power data at a height of 100m in a wind farm in northern my country in 2022 are collected, and the corresponding ERA5 reanalysis data are downloaded from ECMWF. IDW is used to interpolate the ERA5 reanalysis data to the wind farm, remove singular points, and interpolate and supplement the singular points to construct a data set, as shown in Table 1.
[0079] Table 1 Actual data of wind farms and ERA5 reanalysis data
[0080]
[0081]
[0082] In this embodiment, the final processed measured data is compared and analyzed with the ERA5 data. The results are as follows: Figure 2 As shown by Figure 2 It can be seen that the measured wind speed and ERA5 wind speed are mainly concentrated in the range of 0 to 15 m / s, and fluctuate on both sides of the trend line. The formula of the trend line is y=0.791x+0.498, and the correlation coefficient R is 0.89. The relationship between the two is very close.
[0083] Step 5: Build a BP neural network model, take 7 characteristic factors such as 2m relative humidity, surface pressure, total surface radiation, total precipitation, 2m temperature, 100m wind speed, and 100m wind direction as the input factors of the model, and take wind power as the output factor.
[0084] Step 6: Group the processed sample data into a training set and a test set. In this embodiment, the first 90% of the sample data is used as the training set, and the last 10% is used as the test set.
[0085] Step 7: Normalize each feature element in the sample data. The formula is as follows:
[0086]
[0087] inputs=(inputs-inputs_mean) / inputs_std
[0088]
[0089] outputs=(outputs-outputs_mean) / outputs_std
[0090] Among them, inputs_mean is the mean of a certain input element, N is the number of input element data, inputs i is the i-th data of the input, inputs_std is the standard deviation of an input element, inputs is the normalized result of an input element, outputs_mean is the mean of an output element, and outputs i is the i-th data output, outputs_std is the standard deviation of an output element, and outputs is the normalized result of an output element.
[0091] Step 8: Process and calculate the input data through the hidden layer inside the BP neural network; output the predicted wind power. The basic process is as follows:
[0092] Initialize model weights ω, learning rate η, target error E0, and thresholds a0, b0, etc.;
[0093] The number of neurons in the hidden layer is usually determined by an empirical formula, namely:
[0094]
[0095] Among them, h is the number of neurons in the hidden layer; m is the number of neurons in the input layer; n is the number of neurons in the output layer; and s is a constant between 1 and 10.
[0096] In this embodiment, the root mean square error corresponding to different values of the number of neurons in the hidden layer is shown in Table 2.
[0097] Table 2 Root mean square error corresponding to different values of the number of neurons
[0098] Number of neurons 3 4 5 6 7 8 9 10 11 12 Root mean square error 1027 1016 1009 1001 998 1011 1000 990 984 990
[0099] In this embodiment, it can be seen from Table 2 that when the number of neurons is 11, the root mean square error of the model is the smallest, which is 984; when the number of neurons is 3, the root mean square error of the model is the largest, which is 1027. Therefore, the optimal number of neurons in this study is 11.
[0100] When predicting wind power, the BP neural network first performs forward propagation to calculate the wind power value of the output layer. The formula used is:
[0101]
[0102] in, is the wind power output by the kth neuron in the pth hidden layer, is the weight of the connection between the jth neuron in the p-1th hidden layer and the kth neuron in the pth hidden layer, is the wind power output by the kth neuron in the p-1th hidden layer, is the threshold of the kth neuron in the pth hidden layer, σ is the activation function, and
[0103] 8.4 Calculate the error E between the wind power output by the BP neural network and the actual wind power n for:
[0104]
[0105] in, is the predicted wind power; is the measured value of wind power;
[0106] If the error E n If the error is greater than the target error E0, the BP neural network will perform back propagation and update the weights. The formula used is as follows:
[0107] W i (n+1)=ΔW ij (n+1)+W kj (n)
[0108] Among them, W ij is the data weight from the input layer to the hidden layer, W kj is the data weight from the hidden layer to the output layer, W i is the updated data weight.
[0109] Step 9: The mean absolute error (MAE), root mean square error (RMSE) and Pearson correlation coefficient (R) were used to evaluate the predicted wind power and the measured wind power. The calculation formula is as follows:
[0110]
[0111] Among them, W i cal is the wind power forecast value at the i-th moment, W i obs is the measured value of wind power at the i-th moment.
[0112]
[0113] in, Respectively represent the average values of X and Y samples, σ X , σY Represent the standard deviation of X and Y samples respectively.
[0114] In this embodiment, the hourly variation trends of the measured wind power of the training set and the test set and the ERA5 predicted wind power are as follows: Figure 3 , Figure 4 The three evaluation indicators of step 9 in the training set and test set are shown in Table 3.
[0115] Table 3 Evaluation indicators of training set and test set
[0116] Sample Data Mean absolute error Root mean square error Pearson correlation coefficient Training set 702 1000 0.91 Test Set 861 1150 0.81
[0117] Depend on Figure 3 , 4 It can be seen that the wind power change trends measured in the model test set and predicted by ERA5 data are basically consistent, showing a trend of both increase and decrease; at certain moments, ERA5 data overestimates wind power to a certain extent. Overall, ERA5 data has a relatively good effect on wind power prediction. As shown in Table 2, the average absolute error in the training set is 702.12W, the root mean square error is 1000.18W, and the correlation coefficient is 0.91. The average absolute error in the test set is 861.09W, the root mean square error is 1150.86W, and the correlation coefficient is 0.81. The errors in the training set and the test set are relatively small, the correlation coefficient is high, and the model effect is relatively good.
[0118] The method of the present invention predicts wind power based on BP neural network combined with ERA5 reanalysis data, thereby providing a feasible reference solution for carrying out preliminary work of wind power projects and predicting wind power in areas lacking data or where data acquisition is difficult.
[0119] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When the use is implemented in whole or in part in the form of a computer program product, the computer program product includes one or more computer instructions. When the computer program instructions are loaded or executed on a computer, the process or function described in the embodiment of the present invention is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL) or wireless (e.g., infrared, wireless, microwave, etc.) mode) to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk SolidState Disk (SSD)), etc.
[0120] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit the present invention. Although the present invention is described in detail with reference to the embodiments, it should be understood by those skilled in the art that any modification or equivalent replacement of the technical solutions of the present invention does not depart from the spirit and scope of the technical solutions of the present invention and should be included in the scope of the claims of the present invention.
Claims
1. A method for predicting wind power in areas lacking wind measurement data using a BP neural network, characterized in that: The steps include: Step 1: Collect historical characteristic data of wind speed, wind direction, temperature and humidity and actual wind power of the wind farm; Step 2: Download the ERA5 reanalysis data for the wind farm provided by the European Centre for Medium-Range Weather Forecasts (ECMWF); Step 3: Use the inverse distance weighted (IDW) method to interpolate the ERA5 reanalysis data to the location of each unit in the wind farm to obtain the ERA5 meteorological data at the corresponding location of the wind turbine; Step 4: Combine historical data of wind farms and ERA5 reanalysis data to construct sample data, remove singular points for each characteristic element in the sample data, and interpolate and supplement data in the time series of removed data points; Step 5: Build a BP neural network model, use the downloaded ERA5 reanalysis data as the input element of the model, and use wind power as the output element; Step 6: Group the processed sample data into training set and test set; Step 7: Normalize each feature element in the sample data; Step 8: Process and calculate the input data through the hidden layer inside the BP neural network and output the predicted wind power; Step 9: The mean absolute error (MAE), root mean square error (RMSE) and Pearson correlation coefficient (R) were used to evaluate the predicted wind power and the measured wind power.
2. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 2, the ERA5 reanalysis data includes data on 2m relative humidity, surface pressure, surface global radiation, total precipitation, 2m temperature, 100m wind speed, and 100m wind direction.
3. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 3, the calculation process of the inverse distance weighted method interpolation is as follows: 3.1 Calculate the distance d from the unknown point to all points i In the formula, x and y are the horizontal and vertical coordinates corresponding to the unknown point, x i ,y i The horizontal and vertical coordinates correspond to all ERA5 reanalysis data; 3.2 Calculate the weight w i 3.3 Calculate the value of the interpolation point Z0 In the formula, Z(X i ,Y i ) is the corresponding ERA5 reanalysis data in the field area.
4. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 4, the method for interpolating and supplementing data in the time series after removing data points is as follows: Y=((X-X1)(Y2-Y1) / (X2-X1))+Y1 Among them, (X1, Y1) and (X1, Y1) are the known coordinate points, X is the target value, and Y is the result.
5. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 7, the formula for normalizing each characteristic element in the sample data is as follows: inputs=(inputs-inputs_mean) / inputs_std outputs=(outputs-outputs_mean) / outputs_std Among them, inputs_mean is the mean of a certain input element, N is the number of input element data, inputs i is the i-th data of the input, inputs_std is the standard deviation of an input element, inputs is the normalized result of an input element, outputs_mean is the mean of an output element, and outputs i is the i-th data output, outputs_std is the standard deviation of an output element, and outputs is the normalized result of an output element.
6. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 8, the input data is processed and calculated by the hidden layer inside the BP neural network, and the predicted wind power is output, which includes the following process: 8.1 Initialize model weights ω, learning rate η, target error E0 and thresholds a0 and b0; 8.2 Determine the number of neurons in the hidden layer using an empirical formula, namely: Among them, h is the number of neurons in the hidden layer; m is the number of neurons in the input layer; n is the number of neurons in the output layer; s is a constant between 1 and 10; 8.3 When predicting wind power, the BP neural network first performs forward propagation to calculate the wind power value of the output layer. The formula used is: in, is the wind power output by the kth neuron in the pth hidden layer, is the weight of the connection between the jth neuron in the p-1th hidden layer and the kth neuron in the pth hidden layer, is the wind power output by the kth neuron in the p-1th hidden layer, is the threshold of the kth neuron in the pth hidden layer, σ is the activation function, and 8.4 Calculate the error E between the wind power output by the BP neural network and the actual wind power n for: in, is the predicted value of wind power; is the measured value of wind power; If the error E n If the error is greater than the target error E0, the BP neural network will perform back propagation and update the weights. The formula used is as follows: IN i (n+1)=ΔW ij (n+1)+W kj (n) Among them, W ij is the data weight from the input layer to the hidden layer, W kj is the data weight from the hidden layer to the output layer, W i is the updated data weight; 8.5 When the error E n When it is less than E0 or the maximum number of iterations is reached, the model ends.
7. The method for predicting wind power in areas lacking wind measurement data using a BP neural network according to claim 1 is characterized in that: In step 9, the calculation formulas for the mean absolute error (MAE), root mean square error (RMSE) and Pearson correlation coefficient (R) are as follows: in, is the wind power forecast value at the i-th moment, is the measured value of wind power at the i-th moment. in, Respectively represent the average values of X and Y samples, σ X , σ Y Represent the standard deviation of X and Y samples respectively.
8. An information data processing terminal for implementing the method for predicting wind power in areas lacking wind measurement data using a BP neural network as described in any one of claims 1 to 7.
9. A computer-readable storage medium, comprising instructions, which, when executed on a computer, enable the computer to execute the method for predicting wind power in an area lacking wind measurement data using a BP neural network as described in any one of claims 1 to 7.
Citation Information
Cited By
Wind power interval prediction method and application
CN120430142A
Wind power prediction method based on input guide physical information neural network
CN121189579A
