A medium- and long-term forecasting method for hydropower generation based on decomposition reduction and machine learning
By dividing power stations into types and using tailored prediction models, the method enhances the accuracy and adaptability of hydropower generation forecasting, addressing the limitations of uniform forecasting methods.
Patent Information
- Application Number
- CN202410818113.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-24
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2044-06-24
AI Technical Summary
Existing medium- and long-term forecasting methods for hydropower generation treat all types of hydropower stations uniformly, resulting in coarse granularity and low accuracy, which cannot meet the needs of regional hydropower generation forecasting.
The method divides power stations into three types - aggregated small, large, and pumped storage power stations, establishing separate prediction models for each, using historical data and machine learning techniques to predict power generation, and combining the results to form a regional total power generation forecast.
This approach significantly improves the accuracy of regional hydropower generation prediction by considering the unique characteristics of each power station type, enhancing the precision and adaptability of forecasting.
Smart Images

Figure CN118798419B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of power generation prediction, and in particular relates to a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning. Background Art
[0002] The medium- and long-term forecast of regional hydropower generation is to give a forecast of the region's hydropower generation in the next one or three months based on the understanding of the regional precipitation climate, objective hydrological laws, electricity load characteristics and power station operation and scheduling characteristics. It plays an important supporting role in coordinating the contradictions between reservoir flood control / water storage / power generation, reducing water abandonment and power generation, balancing the power generation of coal-fired power and other power sources, supporting the dynamic adjustment of the flood limit water level of the basin cascade, and ensuring the safety and stability of energy supply.
[0003] The existing medium- and long-term forecasting method for hydropower generation treats all types of hydropower stations in the region as a whole to achieve hydropower generation forecasting. The forecast granularity is coarse, resulting in low accuracy in regional hydropower generation forecasting, which can no longer meet people's usage needs. Summary of the invention
[0004] In view of the defects of the prior art, the present invention provides a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning, which can effectively solve the above problems.
[0005] The technical solution adopted by the present invention is as follows:
[0006] The present invention provides a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning, comprising the following steps:
[0007] Step S1, dividing the power stations in the study area into three types, namely, aggregated small hydropower stations, large hydropower stations and pumped storage power stations; collecting the historical basic data related to power generation in the study area in the last t-1 months; the time scale of the historical basic data related to power generation is monthly;
[0008] Step S2, establishing a large hydropower station power generation prediction model; using the large hydropower station power generation prediction model, predicting the power generation of the large hydropower station in the tth month to be predicted, and obtaining the predicted value E0(t) of the power generation of the large hydropower station in the tth month;
[0009] Step S2.1: Use the water balance model to establish a large hydropower station inflow prediction model to predict the inflow Q of the tth month. in (t);
[0010] Step S2.2, defining a similarity index S by comprehensively considering precipitation, temperature, inflow and reservoir capacity; calculating the similarity index between each month in the most recent t-1 months and the t-th month to be predicted, and selecting the m months with the highest similarity index as the similar months of the t-th month to be predicted, thereby obtaining m similar months;
[0011] Step S2.3, based on the outflow and power generation water diversion flow of m similar months, iterate the water balance formula to predict the power generation water diversion flow Q of the tth month gen (t) and the reservoir capacity V(t) in month t;
[0012] Step S2.4, obtaining the hydraulic head H(t) in the tth month according to the predicted reservoir capacity V(t) in the tth month;
[0013] Step S2.5, using the following formula, obtain the predicted value of power generation of large hydropower station in month t, E0(t):
[0014] E0(t)=η·ρ·g·Q gen (t)·H(t)·Δt
[0015] Where: η is the turbine efficiency, ρ is the density of water, g is the acceleration of gravity, Δt is the number of days in the tth month multiplied by 3600 seconds;
[0016] Step S3, establishing a pumped-storage power station power generation prediction model; using the pumped-storage power station power generation prediction model, predicting the power generation of the pumped-storage power station in the tth month to be predicted, and obtaining a predicted value E1(t) of the power generation of the pumped-storage power station in the tth month;
[0017] Step S4, establishing a prediction model for the power generation of aggregated small hydropower stations; using the prediction model for the power generation of aggregated small hydropower stations, predicting the power generation of the aggregated small hydropower stations in the tth month to be predicted, and obtaining a predicted value E2(t) of the power generation of the aggregated small hydropower stations in the tth month;
[0018] Step S5, using formula (1), combining the predicted power generation value E0(t) of the large hydropower station in the tth month, the predicted power generation value E1(t) of the pumped storage power station in the tth month, and the predicted power generation value E2(t) of the aggregated small hydropower station in the tth month, to obtain the total power generation forecast value E(t) of the tth month:
[0019] E(t)=E0(t)+E1(t)+E2(t) (1)
[0020] This enables the prediction of hydropower generation in the region in the tth month.
[0021] Preferably, step S2.1 is specifically:
[0022] Step S2.1.1, select a monthly water balance model, use the NASH efficiency coefficient as the objective function, use historical observation monthly scale data to train the monthly water balance model, use the SCEUA algorithm to optimize parameters, and obtain a trained monthly water balance model; wherein the historical observation monthly scale data includes precipitation and evapotranspiration data;
[0023] Step S2.1.2, selecting the WRF model as the meteorological numerical forecast model; using the meteorological numerical forecast model to predict the precipitation and evapotranspiration data of the tth month, and obtaining the precipitation and evapotranspiration data of the tth month;
[0024] The precipitation and evapotranspiration data of the tth month are input into the trained monthly water balance model, and the trained monthly water balance model outputs the predicted inflow Q of the tth month. in (t).
[0025] Preferably, in step S2.2, the similarity index between each month in the most recent t-1 months and the tth month to be predicted is calculated using the following method:
[0026] The most recent t-1 months are called the 1st month, the 2nd month, ..., the t-1th month in chronological order; for the jth month, j = 1, 2, ..., t-1, using formula (2) and formula (3), the similarity index S between the jth month and the tth month to be predicted is obtained j :
[0027]
[0028] Where: X i,j is the value of the ith indicator in the jth month; X i (t) is the value of the ith indicator in the tth month predicted by the meteorological numerical forecast model; R i,j is the similarity between the i-th index in the j-th month and the t-th month; ω i is the similarity index weight of the i-th index; where i = 1, 2, 3, 4, representing precipitation index, temperature index, inflow index and reservoir capacity index respectively.
[0029] Preferably, the similarity index weight ω of the i-th index i The method for determining is:
[0030] Step S2.2.1: Set the value X of the i-th indicator in the j-th month i,j , use formula (4) to perform normalization and obtain the normalized value x i,j , represents the standardized value of the i-th indicator in the j-th month:
[0031]
[0032] Where: X i Represents the data X of the i-th indicator in the first month i,1 , the data X of the i-th indicator in the second month i,2 ,…, the data X of the i-th indicator in the t-1 month i,t-1 The data set formed; min(X i ) and max(X i ), respectively representing the minimum and maximum values in the data set;
[0033] Step S2.2.2: Use formula (5) to obtain the standardized value x of the ith indicator in the jth month. i,j The proportion p i,j :
[0034]
[0035] Step S2.2.3, using formula (6), obtain the entropy value e of the ith indicator i :
[0036]
[0037] Step S2.2.4, using formula (7), obtain the difference coefficient d of the i-th indicator i :
[0038] d i =1-e i (7)
[0039] Step S2.2.5, using formula (8), obtain the similarity index weight ω of the i-th index i :
[0040]
[0041] Thus, the similarity index weight of each index is determined.
[0042] Preferably, step S2.3 is specifically:
[0043] Step S2.3.1: Take the average of the outbound flow of m similar months as the outbound flow Q of the tth month out (t) initial value;
[0044] Step S2.3.2, establish the water balance formula shown in formula (9):
[0045] V(t)=V(t-1)+Q in (t)-Q out (t)-E(t)·A (9)
[0046] Where: V(t) is the reservoir capacity in the tth month; V(t-1) is the reservoir capacity in the t-1th month; Q out (t) is the outflow in the tth month; E(t) is the evaporation per unit area in the tth month, which is predicted by the meteorological numerical forecast model; A is the reservoir area;
[0047] The outbound flow Q out Substitute the value of (t) into the water balance formula to obtain the reservoir capacity V(t) in the tth month;
[0048] Step S2.3.3, read the reservoir capacity curve; according to the reservoir capacity curve, convert the reservoir capacity V(t) in the tth month into the water level H(t), and according to formula (10), obtain the flood discharge Q in the tth month flood (t):
[0049]
[0050] Where: H safe is the safe water level of the reservoir, k is the flood discharge coefficient;
[0051] Step S2.3.4, according to formula (11), the power generation water diversion flow Q in the tth month is obtained gen (t):
[0052] Q gen (t) = β·Q out (t) (11)
[0053] Where: β is the ratio coefficient of the power generation water diversion flow to the outflow flow; it is determined by the arithmetic average of the ratio of the power generation water diversion flow to the outflow flow in m similar months;
[0054] Step S2.3.5, take the arithmetic mean of the outflow flow of m similar months to obtain the ecological flow Q of the tth month eco (t);
[0055] Step S2.3.6, using formula (12), obtain the updated outbound flow Q out (t):
[0056] Q out (t) = Q gen (t)+Q flood (t)+Q eco (t) (12)
[0057] Step S2.3.7, set the outbound flow threshold τ; determine the outbound flow Q obtained in step S2.3.6 out (t) and the outflow Q input into the water balance formula in step S2.3.2 out(t), whether the difference is less than the outbound flow threshold τ, if not, execute step S2.3.8; if less, determine whether two consecutive iterations meet the condition of being less than the outbound flow threshold τ, if yes, end the iteration and execute step S2.3.9; if not, execute step S2.3.8;
[0058] Step S2.3.8: convert the outbound flow Q obtained in step S2.3.6 into out (t), is input into the water balance formula in step S2.3.2, and the cycle is repeated;
[0059] Step S2.3.9, output the power generation water diversion flow Q of the tth month obtained in the last round of iteration gen (t) and the reservoir capacity V(t) in the tth month.
[0060] Preferably, step S2.4 is specifically:
[0061] Step S2.4.1, using formula (13), the average of the predicted reservoir capacity V(t) in the tth month and the reservoir capacity V(t-1) in the t-1st month is taken as the average reservoir capacity V mean :
[0062] V mean =(V(t)+V(t-1)) / 2 (13)
[0063] Step S2.4.2, use the average reservoir capacity V mean Find the reservoir capacity curve and get the water level H in the tth month m (t);
[0064] Step S2.4.3, using formula (14), obtain the water head H(t) in the tth month:
[0065] H(t)=H m (t)-H turbine (14)
[0066] Where: H turbine is the height of the turbine location.
[0067] Preferably, step S3 specifically comprises:
[0068] Step S3.1, for the jth month in the most recent t-1 months, j = 1, 2, ..., t-1, read its pumped storage power generation data P j , Temperature data T j , precipitation data R j and power demand data D j , forming a four-dimensional row vector; the four-dimensional row vector combination of month t-1 is the correlation variable matrix X shown in formula (15):
[0069]
[0070] Step S3.2, the length of the correlation variable matrix X is t-1, that is, there are t-1 four-dimensional row vectors; the time step is set to 1, and the sliding window length is set to 24; the sliding window matrix W shown in formula (16) is obtained in turn k :
[0071]
[0072] Where: k is the row number of the starting four-dimensional row vector of the sliding window; k is equal to 1, 2, ..., t-24 in sequence; therefore, t-24 sliding window matrices can be obtained, which are represented as: W1, W2, ..., W t-24 ;
[0073] Step S3.3, for t-24 sliding window matrices W1, W2, ..., W t-24 , sliding window matrix W t-24 is the sliding window matrix closest to the tth month to be predicted, and calculate W1, W2, ..., W respectively. t-23 Each sliding window matrix in t-24 The similarity between t-24 The sliding window matrix with the highest similarity is called the most approximate sliding window matrix. The pumped storage power generation data in the next row of adjacent four-dimensional row vectors in the relevant variable matrix X of the most approximate sliding window matrix is the predicted power generation value E1(t) of the pumped storage power station in the tth month.
[0074] Preferably, for W1, W2, ..., W t-23 Each sliding window matrix in t-24 The calculation method of the similarity is the same;
[0075] Step S3.3.1, for the sliding window matrix W1 and the sliding window matrix W t-24 , respectively:
[0076]
[0077]
[0078] Step S3.3.2, calculate the first row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the first row vector of :
[0079] d 1,1 =α 23 ((P1-Pt-24 ) 2 +(T1-T t-24 ) 2 +(R1-R t-24 ) 2 +(D1-D t-24 ) 2 );
[0080] Calculate the second row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the second row vector of :
[0081] d 2,2 =α 22 ((P2-P t-23 ) 2 +(T2-T t-23 ) 2 +(R2-R t-23 ) 2 +(D2-D t-23 ) 2 );
[0082] And so on
[0083] Calculate the 24th row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the row vectors in row 24:
[0084] d 24,24 =α 0 ((P 24 -P t-1 ) 2 +(T 24 -T t-1 ) 2 +(R 24 -R t-1 ) 2 +(D 24 -D t-1 ) 2 );
[0085] Where: α is the time attenuation factor, 0<α<1;
[0086] Step S3.3.3, using formula (17), obtain the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference d(W1,W t-24 ):
[0087]
[0088] Where: Difference degree d(W1,W t-24 ) is smaller, which means that the sliding window matrix W1 and the sliding window matrix Wt-24 The smaller the difference between the sliding window matrix W1 and the sliding window matrix W t-24 The higher the similarity.
[0089] Preferably, step S4 is specifically:
[0090] Step S4.1, using the random forest algorithm to evaluate the importance of atmospheric circulation factors to power generation, obtain relative importance scores, and select the top M atmospheric circulation factors;
[0091] Step S4.2, using a long short-term memory network LSTM model, the input variables include the hydropower generation, precipitation, maximum temperature, minimum temperature of each month in the most recent t-1 month, and the M atmospheric circulation factors and installed capacity obtained in step S4.1, and the target variable is the predicted value of power generation in the tth month; using the root mean square error RMSE as the loss function, and selecting the Adam optimization algorithm as the model optimizer; using the Bayesian optimization algorithm to optimize the hyperparameters of the model optimizer to determine the optimal long short-term memory network LSTM model; the hyperparameters that can be optimized include the number of hidden units, training rounds, number of model layers, learning rate, batch size, and time step;
[0092] Step S4.3, using the optimized long short-term memory network LSTM model, predict the aggregated small hydropower station power generation forecast value E2(t) in the tth month.
[0093] The medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning provided by the present invention has the following advantages:
[0094] The present invention provides a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning. The power stations in the region are divided into three types, namely, aggregated small hydropower stations, large hydropower stations and pumped storage power stations. Considering the characteristics of the three types of power stations, corresponding power generation prediction models are established respectively, and then the three types of power generation prediction values obtained are superimposed and restored to form a regional total power generation prediction value, which can effectively improve the prediction accuracy of regional hydropower generation. BRIEF DESCRIPTION OF THE DRAWINGS
[0095] In order to more clearly illustrate the specific implementation of the present invention, the drawings required for use in the specific implementation are briefly introduced below.
[0096] Figure 1 A schematic flow chart of the method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning provided by the present invention. DETAILED DESCRIPTION
[0097] In order to make the technical problems, technical solutions and beneficial effects solved by the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0098] The present invention provides a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning. For example, provincial hydropower generation prediction can be realized, and the method of the present invention can improve the accuracy and applicability of hydropower generation prediction. Traditional hydropower generation prediction methods usually use a unified model to deal with different types of power stations, ignoring the differences between power stations, resulting in low prediction accuracy. The present invention decomposes regional power generation and models the characteristics of different types of power stations respectively, fully considering the uniqueness and operation mode of each power station, and improving the prediction accuracy of the model's hydropower generation. The present invention can more accurately capture the operating characteristics of different types of power stations and their impact on total power generation. By introducing multi-dimensional input features such as meteorological data and atmospheric circulation factors, the method can significantly improve the accuracy and adaptability of hydropower generation prediction. In addition, the present invention has clear implementation steps and strong practicality, and is suitable for provinces with complex hydropower station structures to optimize the configuration and management of power resources.
[0099] See also Figure 1 The present invention provides a method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning, comprising the following steps:
[0100] Step S1, divide the power stations in the study area into three types, namely, aggregated small hydropower stations, large hydropower stations and pumped storage power stations; collect the historical basic data related to power generation in the study area in the last t-1 months; the time scale of the historical basic data related to power generation is monthly.
[0101] In practical applications, the obtained historical basic data related to power generation is first preprocessed, for example, using the k-nearest neighbor algorithm (KNN) to fill in missing values in the data and remove outliers.
[0102] Taking the study area as an example, assuming that the current month is December 2020, the historical basic data related to power generation in a certain area from January 2003 to December 2020 is collected to realize the power generation forecast for January 2021. Therefore, the most recent t-1 month is from January 2003 to December 2020, with a total of 216 months, and the tth month is the 217th month. Through the analysis of the historical basic data related to power generation in the most recent 216 months, the power generation forecast for the 217th month is realized.
[0103] The collected historical basic data related to power generation include but are not limited to: meteorological and hydrological observation data sets of the target area, as well as the power generation, inflow and dispatching rules of each large hydropower station and the power generation of pumped storage power stations in the target area. The data to be collected specifically include: power generation, runoff, precipitation, temperature, evaporation observation data, provincial water storage and water to be stored, and hydropower station installed capacity data.
[0104] Specifically include:
[0105] Precipitation, evapotranspiration data, temperature, reservoir water level, reservoir capacity curve, reservoir capacity, inflow, outflow, and power generation water diversion flow of large hydropower stations;
[0106] Power generation data, temperature data, precipitation data and electricity demand data of pumped storage power stations;
[0107] Aggregate hydroelectric power generation from small hydropower stations and 130 atmospheric circulation factors;
[0108] As well as WRF meteorological data predicted by the numerical forecast model for large power plants in the coming month, January 2021.
[0109] The time scale of the above data is monthly.
[0110] Step S2, establishing a large hydropower station power generation prediction model; using the large hydropower station power generation prediction model, predicting the power generation of the large hydropower station in the tth month to be predicted, and obtaining the predicted value E0(t) of the power generation of the large hydropower station in the tth month;
[0111] Step S2.1: Use the water balance model to establish a large hydropower station inflow prediction model to predict the inflow Q of the tth month. in (t);
[0112] Step S2.1 is specifically as follows:
[0113] Step S2.1.1, selecting a monthly water balance model, for example, an ABCD monthly water balance model; using the NASH efficiency coefficient as the objective function, using historical observation monthly scale data to train the monthly water balance model, using the SCEUA algorithm to optimize parameters, and obtaining a trained monthly water balance model; wherein the historical observation monthly scale data includes precipitation and evapotranspiration data;
[0114] Step S2.1.2, selecting the WRF model as the meteorological numerical forecast model; using the meteorological numerical forecast model to predict the precipitation and evapotranspiration data of the tth month, and obtaining the precipitation and evapotranspiration data of the tth month;
[0115] The precipitation and evapotranspiration data of the tth month are input into the trained monthly water balance model, and the trained monthly water balance model outputs the predicted inflow Q of the tth month. in (t).
[0116] Step S2.2, defining a similarity index S by comprehensively considering precipitation, temperature, inflow and reservoir capacity; calculating the similarity index between each month in the most recent t-1 months and the t-th month to be predicted, and selecting the m months with the highest similarity index as the similar months of the t-th month to be predicted, thereby obtaining m similar months;
[0117] In step S2.2, the similarity index between each month in the most recent t-1 months and the tth month to be predicted is calculated using the following method:
[0118] The most recent t-1 months are called the 1st month, the 2nd month, ..., the t-1th month in chronological order; for the jth month, j = 1, 2, ..., t-1, using formula (2) and formula (3), the similarity index S between the jth month and the tth month to be predicted is obtained j :
[0119]
[0120] Where: X i,j is the value of the ith indicator in the jth month; X i (t) is the value of the ith indicator in the tth month predicted by the meteorological numerical forecast model; R i,j is the similarity between the i-th index in the j-th month and the t-th month; ω i is the similarity index weight of the i-th index; where i = 1, 2, 3, 4, representing precipitation index, temperature index, inflow index and reservoir capacity index respectively.
[0121] In the present invention, the similarity index weight ω of the i-th index is i The method for determining is:
[0122] Step S2.2.1: Set the value X of the i-th indicator in the j-th month i,j , use formula (4) to perform normalization and obtain the normalized value x i,j , represents the standardized value of the i-th indicator in the j-th month:
[0123]
[0124] Where: X i Represents the data X of the i-th indicator in the first month i,1 , the data X of the i-th indicator in the second month i,2,…, the data X of the i-th indicator in the t-1 month i,t-1 The data set formed; min(X i ) and max(X i ), respectively representing the minimum and maximum values in the data set;
[0125] Step S2.2.2: Use formula (5) to obtain the standardized value x of the ith indicator in the jth month. i,j The proportion p i,j :
[0126]
[0127] Step S2.2.3, using formula (6), obtain the entropy value e of the ith indicator i :
[0128]
[0129] Step S2.2.4, using formula (7), obtain the difference coefficient d of the i-th indicator i :
[0130] d i =1-e i (7)
[0131] Step S2.2.5, using formula (8), obtain the similarity index weight ω of the i-th index i :
[0132]
[0133] Thus, the similarity index weight of each index is determined.
[0134] Step S2.3, based on the outflow and power generation water diversion flow of m similar months, iterate the water balance formula to predict the power generation water diversion flow Q of the tth month gen (t) and the reservoir capacity V(t) in month t;
[0135] Step S2.3 is specifically as follows:
[0136] Step S2.3.1: Take the average of the outbound flow of m similar months as the outbound flow Q of the tth month out (t) initial value;
[0137] Step S2.3.2, establish the water balance formula shown in formula (9):
[0138] V(t)=V(t-1)+Q in (t)-Q out (t)-E(t)·A (9)
[0139] Where: V(t) is the reservoir capacity in the tth month, which is the value to be calculated; V(t-1) is the reservoir capacity in the t-1th month; Q out (t) is the outflow in the tth month; E(t) is the evaporation per unit area in the tth month, which is predicted by the meteorological numerical forecast model; A is the reservoir area;
[0140] The outbound flow Q out Substitute the value of (t) into the water balance formula to obtain the reservoir capacity V(t) in the tth month;
[0141] Step S2.3.3, read the reservoir capacity curve; according to the reservoir capacity curve, convert the reservoir capacity V(t) in the tth month into the water level H(t), and according to formula (10), obtain the flood discharge Q in the tth month flood (t):
[0142]
[0143] Where: H safe is the safe water level of the reservoir, k is the flood discharge coefficient;
[0144] Step S2.3.4, according to formula (11), the power generation water diversion flow Q in the tth month is obtained gen (t):
[0145] Q gen (t) = β·Q out (t) (11)
[0146] Where: β is the ratio coefficient of the power generation water diversion flow to the outflow flow; it is determined by the arithmetic average of the ratio of the power generation water diversion flow to the outflow flow in m similar months;
[0147] Step S2.3.5, take the arithmetic mean of the outflow flow of m similar months to obtain the ecological flow Q of the tth month eco (t);
[0148] Step S2.3.6, using formula (12), obtain the updated outbound flow Q out (t):
[0149] Q out (t) = Q gen (t)+Q flood (t)+Q eco (t) (12)
[0150] Step S2.3.7, set the outbound flow threshold τ; determine the outbound flow Q obtained in step S2.3.6 out (t) and the outflow Q input into the water balance formula in step S2.3.2out (t), whether the difference is less than the outbound flow threshold τ, if not, execute step S2.3.8; if less, determine whether two consecutive iterations meet the condition of being less than the outbound flow threshold τ, if yes, end the iteration and execute step S2.3.9; if not, execute step S2.3.8;
[0151] Step S2.3.8: convert the outbound flow Q obtained in step S2.3.6 into out (t), is input into the water balance formula in step S2.3.2, and the cycle is repeated;
[0152] Step S2.3.9, output the power generation water diversion flow Q of the tth month obtained in the last round of iteration gen (t) and the reservoir capacity V(t) in the tth month.
[0153] Step S2.4, obtaining the hydraulic head H(t) in the tth month according to the predicted reservoir capacity V(t) in the tth month;
[0154] Step S2.4 is specifically as follows:
[0155] Step S2.4.1, using formula (13), the average of the predicted reservoir capacity V(t) in the tth month and the reservoir capacity V(t-1) in the t-1st month is taken as the average reservoir capacity V mean :
[0156] V mean =(V(t)+V(t-1)) / 2 (13)
[0157] Step S2.4.2, use the average reservoir capacity V mean Find the reservoir capacity curve and get the water level H in the tth month m (t);
[0158] Step S2.4.3, using formula (14), obtain the water head H(t) in the tth month:
[0159] H(t)=H m (t)-H turbine (14)
[0160] Where: H turbine is the height of the turbine location.
[0161] Step S2.5, using the following formula, obtain the predicted value of power generation of large hydropower station in month t, E0(t):
[0162] E0(t)=η·ρ·g·Q gen (t)·H(t)·Δt
[0163] Where: η is the turbine efficiency, ρ is the density of water, g is the acceleration of gravity, Δt is the number of days in the tth month multiplied by 3600 seconds;
[0164] Step S3, establishing a pumped-storage power station power generation prediction model; using the pumped-storage power station power generation prediction model, predicting the power generation of the pumped-storage power station in the tth month to be predicted, and obtaining a predicted value E1(t) of the power generation of the pumped-storage power station in the tth month;
[0165] Step S3 is specifically as follows:
[0166] Step S3.1, for the jth month in the most recent t-1 months, j = 1, 2, ..., t-1, read its pumped storage power generation data P j , Temperature data T j , precipitation data R j and power demand data D j , forming a four-dimensional row vector; the four-dimensional row vector combination of month t-1 is the correlation variable matrix X shown in formula (15):
[0167]
[0168] Step S3.2, the length of the correlation variable matrix X is t-1, that is, there are t-1 four-dimensional row vectors; the time step is set to 1, and the sliding window length is set to 24; the sliding window matrix W shown in formula (16) is obtained in turn k :
[0169]
[0170] Where: k is the row number of the starting four-dimensional row vector of the sliding window; k is equal to 1, 2, ..., t-24 in sequence; therefore, t-24 sliding window matrices can be obtained, which are represented as: W1, W2, ..., W t-24 ;
[0171] Step S3.3, for t-24 sliding window matrices W1, W2, ..., W t-24 , sliding window matrix W t-24 is the sliding window matrix closest to the tth month to be predicted, and calculate W1, W2, ..., W respectively. t-23 Each sliding window matrix in t-24 The similarity between t-24 The sliding window matrix with the highest similarity is called the most approximate sliding window matrix. The pumped storage power generation data in the next row of adjacent four-dimensional row vectors in the relevant variable matrix X of the most approximate sliding window matrix is the predicted power generation value E1(t) of the pumped storage power station in the tth month.
[0172] For W1,W2,...,W t-23 Each sliding window matrix in t-24 The calculation method of the similarity is the same; therefore, only the sliding window matrix W1 and the sliding window matrix W t-24 The similarity calculation method is introduced as an example, including the following steps:
[0173] Step S3.3.1, for the sliding window matrix W1 and the sliding window matrix W t-24 , respectively:
[0174]
[0175]
[0176] Step S3.3.2, calculate the first row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the first row vector of :
[0177] d 1,1 =α 23 ((P1-P t-24 ) 2 +(T1-T t-24 ) 2 +(R1-R t-24 ) 2 +(D1-D t-24 ) 2 );
[0178] Calculate the second row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the second row vector of :
[0179] d 2,2 =α 22 ((P2-P t-23 ) 2 +(T2-T t-23 ) 2 +(R2-R t-23 ) 2 +(D2-D t-23 ) 2 );
[0180] And so on
[0181] Calculate the 24th row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the row vectors in row 24:
[0182] d 24,24 =α 0 ((P24 -P t-1 ) 2 +(T 24 -T t-1 ) 2 +(R 24 -R t-1 ) 2 +(D 24 -D t-1 ) 2 );
[0183] Where: α is the time attenuation factor, 0<α<1;
[0184] Step S3.3.3, using formula (17), obtain the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference d(W1,W t-24 ):
[0185]
[0186] Where: Difference degree d(W1,W t-24 ) is smaller, which means that the sliding window matrix W1 and the sliding window matrix W t-24 The smaller the difference between the sliding window matrix W1 and the sliding window matrix W t-24 The higher the similarity.
[0187] Step S4, establishing a prediction model for the power generation of aggregated small hydropower stations; using the prediction model for the power generation of aggregated small hydropower stations, predicting the power generation of the aggregated small hydropower stations in the tth month to be predicted, and obtaining a predicted value E2(t) of the power generation of the aggregated small hydropower stations in the tth month;
[0188] Step S4 is specifically as follows:
[0189] Step S4.1, using the random forest algorithm to evaluate the importance of atmospheric circulation factors to power generation, obtain relative importance scores, and select the top M atmospheric circulation factors;
[0190] Step S4.2, using the long short-term memory network LSTM model, the input variables include the hydropower generation, precipitation, maximum temperature, minimum temperature of each month in the last t-1 month, and the M atmospheric circulation factors and installed capacity obtained in step S4.1, and the target variable is the predicted value of power generation in the tth month; the root mean square error RMSE is used as the loss function, and the Adam optimization algorithm is selected as the model optimizer; the Bayesian optimization algorithm is used to optimize the hyperparameters of the model optimizer to determine the optimal long short-term memory network LSTM model; the hyperparameters that can be optimized include the number of hidden units, training rounds, number of model layers, learning rate, batch size, and time step; the specific parameter settings are shown in Table 1:
[0191] Table 1
[0192]
[0193] Step S4.3, using the optimized long short-term memory network LSTM model, predict the aggregated small hydropower station power generation forecast value E2(t) in the tth month.
[0194] Step S5, using formula (1), combining the predicted power generation value E0(t) of the large hydropower station in the tth month, the predicted power generation value E1(t) of the pumped storage power station in the tth month, and the predicted power generation value E2(t) of the aggregated small hydropower station in the tth month, to obtain the total power generation forecast value E(t) of the tth month:
[0195] E(t)=E0(t)+E1(t)+E2(t) (1)
[0196] This enables the prediction of hydropower generation in the region in the tth month.
[0197] Taking the prediction of power generation in a certain area as an example, after calculation, the relative error between the power generation prediction value and the true value of this method is 11.99%, the relative error of the conventional LSTM model is 13.57%, and the relative error of the ARIMA model is 30.31%. In summary, it can be seen that the accuracy of power generation prediction in the example of the present invention is significantly improved compared with the LSTM and ARIMA models.
[0198] The medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning provided by the present invention has the following advantages:
[0199] The present invention provides a medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning. The power stations in the region are divided into three types, namely, aggregated small hydropower stations, large hydropower stations and pumped storage power stations. Considering the characteristics of the three types of power stations, corresponding power generation prediction models are established respectively, and then the three types of power generation prediction values obtained are superimposed and restored to form a regional total power generation prediction value, which can effectively improve the prediction accuracy of regional hydropower generation.
[0200] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be considered as the scope of protection of the present invention.
Claims
1. A medium- and long-term prediction method for hydropower generation based on decomposition reduction and machine learning, characterized in that: The following steps are involved: Step S1, dividing the power stations in the study area into three types, namely, aggregated small hydropower stations, large hydropower stations and pumped storage power stations; collecting the historical basic data related to power generation in the study area in the last t-1 months; the time scale of the historical basic data related to power generation is monthly; Step S2, establishing a large hydropower station power generation prediction model; using the large hydropower station power generation prediction model, predicting the power generation of the large hydropower station in the tth month to be predicted, and obtaining the predicted value E0(t) of the power generation of the large hydropower station in the tth month; Step S2.1: Use the water balance model to establish a large hydropower station inflow prediction model to predict the inflow Q of the tth month. in (t); Step S2.2, defining a similarity index S by comprehensively considering precipitation, temperature, inflow and reservoir capacity; calculating the similarity index between each month in the most recent t-1 months and the t-th month to be predicted, and selecting the m months with the highest similarity index as the similar months of the t-th month to be predicted, thereby obtaining m similar months; Step S2.3, based on the outflow and power generation water diversion flow of m similar months, iterate the water balance formula to predict the power generation water diversion flow Q of the tth month gen (t) and the reservoir capacity V(t) in month t; Step S2.4, obtaining the hydraulic head H(t) in the tth month according to the predicted reservoir capacity V(t) in the tth month; Step S2.5, using the following formula, obtain the predicted value of power generation of large hydropower station in the tth month E0(t): E0(t)=η·ρ·g·Q gen (t)·H(t)·Δt Where: η is the turbine efficiency, ρ is the density of water, g is the acceleration of gravity, Δt is the number of days in the tth month multiplied by 3600 seconds; Step S3, establishing a pumped-storage power station power generation prediction model; using the pumped-storage power station power generation prediction model, predicting the power generation of the pumped-storage power station in the tth month to be predicted, and obtaining a predicted value E1(t) of the power generation of the pumped-storage power station in the tth month; Step S4, establishing a prediction model for the power generation of aggregated small hydropower stations; using the prediction model for the power generation of aggregated small hydropower stations, predicting the power generation of the aggregated small hydropower stations in the tth month to be predicted, and obtaining a predicted value E2(t) of the power generation of the aggregated small hydropower stations in the tth month; Step S5, using formula (1), combining the predicted power generation value E0(t) of the large hydropower station in the tth month, the predicted power generation value E1(t) of the pumped storage power station in the tth month, and the predicted power generation value E2(t) of the aggregated small hydropower station in the tth month, to obtain the total power generation forecast value E(t) of the tth month: E(t)=E0(t)+E1(t)+E2(t) (1) This enables the prediction of hydropower generation in the region in the tth month.
2. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 1 is characterized in that: Step S2.1 is specifically as follows: Step S2.1.1, select a monthly water balance model, use the NASH efficiency coefficient as the objective function, use historical observation monthly scale data to train the monthly water balance model, use the SCEUA algorithm to optimize parameters, and obtain a trained monthly water balance model; wherein the historical observation monthly scale data includes precipitation and evapotranspiration data; Step S2.1.2, selecting the WRF model as the meteorological numerical forecast model; using the meteorological numerical forecast model to predict the precipitation and evapotranspiration data of the tth month, and obtaining the precipitation and evapotranspiration data of the tth month; The precipitation and evapotranspiration data of the tth month are input into the trained monthly water balance model, and the trained monthly water balance model outputs the predicted inflow Q of the tth month. in (t).
3. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 1 is characterized in that: In step S2.2, the similarity index between each month in the most recent t-1 months and the tth month to be predicted is calculated using the following method: The most recent t-1 months are called the 1st month, the 2nd month, ..., the t-1th month in chronological order; for the jth month, j = 1, 2, ..., t-1, using formula (2) and formula (3), the similarity index S between the jth month and the tth month to be predicted is obtained j : Where: X i,j is the value of the ith indicator in the jth month; X i (t) is the value of the ith indicator in the tth month predicted by the meteorological numerical forecast model; R i,j is the similarity between the i-th index in the j-th month and the t-th month; ω i is the similarity index weight of the i-th index; where i = 1, 2, 3, 4, representing precipitation index, temperature index, inflow index and reservoir capacity index respectively.
4. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 3 is characterized in that: Similarity index weight ω of the i-th index i The method to determine is: Step S2.2.1: Set the value X of the i-th indicator in the j-th month i,j , use formula (4) to perform normalization and obtain the normalized value x i,j , represents the standardized value of the i-th indicator in the j-th month: Where: X i Represents the data X of the i-th indicator in the first month i,1 , the data X of the i-th indicator in the second month i,2 ,…, the data X of the i-th indicator in the t-1 month i,t-1 The data set formed; min(X i ) and max(X i ), respectively representing the minimum and maximum values in the data set; Step S2.2.2: Use formula (5) to obtain the standardized value x of the ith indicator in the jth month. i,j The proportion p i,j : Step S2.2.3, using formula (6), obtain the entropy value e of the ith indicator i : Step S2.2.4, using formula (7), obtain the difference coefficient d of the i-th indicator i : d i =1-e i (7) Step S2.2.5, using formula (8), obtain the similarity index weight ω of the i-th index i : Thus, the similarity index weight of each index is determined.
5. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 3 is characterized in that: Step S2.3 is specifically as follows: Step S2.3.1: Take the average of the outbound flow of m similar months as the outbound flow Q of the tth month out (t) initial value; Step S2.3.2, establish the water balance formula shown in formula (9): V(t)=V(t-1)+Q in (t)-Q out (t)-E(t)·A (9) Where: V(t) is the reservoir capacity in the tth month; V(t-1) is the reservoir capacity in the t-1th month; Q out (t) is the outflow in the tth month; E(t) is the evaporation per unit area in the tth month, which is predicted by the meteorological numerical forecast model; A is the reservoir area; The outbound flow Q out Substitute the value of (t) into the water balance formula to obtain the reservoir capacity V(t) in the tth month; Step S2.3.3, read the reservoir capacity curve; according to the reservoir capacity curve, convert the reservoir capacity V(t) in the tth month into the water level H(t), and according to formula (10), obtain the flood discharge Q in the tth month flood (t): Where: H safe is the safe water level of the reservoir, k is the flood discharge coefficient; Step S2.3.4, according to formula (11), the power generation water diversion flow Q in the tth month is obtained gen (t): Q gen (t)=β·Q out (t) (11) Where: β is the ratio coefficient of the power generation water diversion flow to the outflow flow; it is determined by the arithmetic average of the ratio of the power generation water diversion flow to the outflow flow in m similar months; Step S2.3.5, take the arithmetic mean of the outflow flow of m similar months to obtain the ecological flow Q of the tth month eco (t); Step S2.3.6, using formula (12), obtain the updated outbound flow Q out (t): Q out (t)=Q gen (t)+Q flood (t)+Q eco (t) (12) Step S2.3.7, set the outbound flow threshold τ; determine the outbound flow Q obtained in step S2.3.6 out (t) and the outflow Q input into the water balance formula in step S2.3.2 out (t), whether the difference is less than the outbound flow threshold τ, if not, execute step S2.3.8; if less, determine whether two consecutive iterations meet the condition of being less than the outbound flow threshold τ, if yes, end the iteration and execute step S2.3.9; if not, execute step S2.3.8; Step S2.3.8: convert the outbound flow Q obtained in step S2.3.6 into out (t), is input into the water balance formula in step S2.3.2, and the cycle is repeated; Step S2.3.9, output the power generation water diversion flow Q of the tth month obtained in the last round of iteration gen (t) and the reservoir capacity V(t) in the tth month.
6. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 1 is characterized in that: Step S2.4 is specifically as follows: Step S2.4.1, using formula (13), the average of the predicted reservoir capacity V(t) in the tth month and the reservoir capacity V(t-1) in the t-1st month is taken as the average reservoir capacity V mean : V mean =(V(t)+V(t-1)) / 2 (13) Step S2.4.2, use the average reservoir capacity V mean Find the reservoir capacity curve and get the water level H in the tth month m (t); Step S2.4.3, using formula (14), obtain the water head H(t) in the tth month: H(t)=H m (t)-H turbine (14) Where: H turbine is the height of the turbine location.
7. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 1 is characterized in that: Step S3 is specifically as follows: Step S3.1, for the jth month in the most recent t-1 months, j = 1, 2, ..., t-1, read its pumped storage power generation data P j , Temperature data T j , precipitation data R j and power demand data D j , forming a four-dimensional row vector; the four-dimensional row vector combination of month t-1 is the correlation variable matrix X shown in formula (15): Step S3.2, the length of the correlation variable matrix X is t-1, that is, there are t-1 four-dimensional row vectors; the time step is set to 1, and the sliding window length is set to 24; the sliding window matrix W shown in formula (16) is obtained in turn k : Where: k is the row number of the starting four-dimensional row vector of the sliding window; k is equal to 1, 2, ..., t-24 in sequence; therefore, t-24 sliding window matrices can be obtained, which are represented as: W1, W2, ..., W t-24 ; Step S3.3, for t-24 sliding window matrices W1, W2, ..., W t-24 , sliding window matrix W t-24 is the sliding window matrix closest to the tth month to be predicted, and calculate W1, W2, ..., W respectively. t-23 Each sliding window matrix in t-24 The similarity between the sliding window matrix W t-24 The sliding window matrix with the highest similarity is called the most approximate sliding window matrix. The pumped storage power generation data in the adjacent four-dimensional row vector of the next row of the most approximate sliding window matrix in the relevant variable matrix X is the predicted power generation value E1(t) of the pumped storage power station in the tth month.
8. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 7 is characterized in that: For W1,W2,...,W t-23 Each sliding window matrix in t-24 The calculation method of the similarity is the same; Step S3.3.1, for the sliding window matrix W1 and the sliding window matrix W t-24 , respectively: Step S3.3.2, calculate the first row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the first row vector of : d 1,1 =α 23 ((P1-P t-24 ) 2 +(T1-T t-24 ) 2 +(R1-R t-24 ) 2 +(D1-D t-24 ) 2 ); Calculate the second row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the second row vector of : d 2,2 α 22 ((P2-P t-23 ) 2 +(T2-T t-23 ) 2 +(R2-R t-23 ) 2 +(D2-D t-23 ) 2 )4 And so on Calculate the 24th row vector of the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference of the row vectors in row 24: d 24,24 =α 0 ((P 24 -P t-1 ) 2 +(T 24 -T t-1 ) 2 +(R 24 -R t-1 ) 2 +(D 24 -D t-1 ) 2 ); Where: α is the time attenuation factor, 0<α<1; Step S3.3.3, using formula (17), obtain the sliding window matrix W1 and the sliding window matrix W t-24 The degree of difference d(W1,W t-24 ): Where: Difference degree d(W1,W t-24 ) is smaller, which means that the sliding window matrix W1 and the sliding window matrix W t-24 The smaller the difference between the sliding window matrix W1 and the sliding window matrix W t-24 The higher the similarity.
9. The method for medium- and long-term prediction of hydropower generation based on decomposition reduction and machine learning according to claim 1, characterized in that: Step S4 is specifically as follows: Step S4.1, using the random forest algorithm to evaluate the importance of atmospheric circulation factors to power generation, obtain relative importance scores, and select the top M atmospheric circulation factors; Step S4.2, using a long short-term memory network LSTM model, the input variables include the hydropower generation, precipitation, maximum temperature, minimum temperature of each month in the most recent t-1 month, and the M atmospheric circulation factors and installed capacity obtained in step S4.1, and the target variable is the predicted value of power generation in the tth month; using the root mean square error RMSE as the loss function, and selecting the Adam optimization algorithm as the model optimizer; using the Bayesian optimization algorithm to optimize the hyperparameters of the model optimizer to determine the optimal long short-term memory network LSTM model; the hyperparameters that can be optimized include the number of hidden units, training rounds, number of model layers, learning rate, batch size, and time step; Step S4.3, using the optimized long short-term memory network LSTM model, predict the aggregated small hydropower station power generation forecast value E2(t) in the tth month.