Day-ahead multi-power-grid transaction method considering multiple uncertainty factors
By constructing an uncertainty set and generating typical scenarios using a Copula function, and combining it with a two-stage stochastic optimization model, the problem of insufficient uncertainty handling in multi-grid transactions is solved, achieving a balance between economic efficiency and risk, and improving the practicality and reliability of transaction decisions.
Patent Information
- Application Number
- CN202511744462.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-25
- Publication Date
- 2026-03-20
AI Technical Summary
Existing multi-grid trading methods fail to effectively handle uncertainties, resulting in large deviations in the execution of trading plans, severe economic losses in extreme scenarios, and difficulty in balancing economic benefits and operational risks.
An uncertain set of inflow and load is constructed, and a Copula function is used to represent the joint uncertainty, generating a set of typical scenarios. Then, by minimizing the conditional regret, a two-stage stochastic optimization model is used to adjust the risk coefficient α to control the tail risk of regret, and the optimal day-ahead power purchase and sale plan is generated.
It provides superior risk management capabilities and fairer decision-making standards. By adjusting the α parameter to quantify the trade-off between cost and risk, it generates near-optimal decision solutions, thereby improving the practicality and reliability of trading decisions.
Smart Images

Figure CN121707718A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of power system optimization dispatching and power market trading technology, and in particular relates to a day-ahead multi-grid trading method that takes into account multiple uncertainties. Background Technology
[0002] With the rapid development of the energy internet and the deepening of power market reform, multi-grid trading has become an important means to improve energy utilization and promote the consumption of renewable energy. Existing deterministic optimization methods ignore uncertainty and have large deviations in actual operation; two-stage stochastic programming considers scenarios but targets the expected value, making it difficult to control extreme risks; robust optimization is too conservative and has poor economic efficiency.
[0003] Existing methods have shortcomings in uncertainty characterization, scenario handling, and decision-making criteria. Uncertainty characterization fails to fully consider spatiotemporal correlations, scenario generation is computationally intensive and may lose key information, traditional decision-making criteria cannot effectively distinguish the quality of different scenarios, and lack flexible risk adjustment mechanisms. This leads to large deviations in the actual execution of transaction plans, severe economic losses in extreme scenarios, and difficulty in balancing economic benefits and operational risks.
[0004] Therefore, there is a need for a multi-grid day-ahead trading method that can effectively handle uncertainty and control decision-making risks, thereby improving the practicality and reliability of trading decisions. Summary of the Invention
[0005] The purpose of this invention is to overcome the shortcomings of existing technologies and provide a day-ahead multi-grid trading method based on conditional regret that can effectively handle multiple uncertainties and balance economic efficiency and risk. First, uncertain sets for interval inflow and load are constructed separately, yielding marginal distribution functions for interval inflow and load. Second, joint uncertainties are characterized using a Copula function to generate a large number of scenarios, which are then reduced using clustering methods. Finally, a two-stage stochastic optimization model minimizing conditional regret is established, flexibly controlling the tail risk of regret by adjusting the risk coefficient α. The objective function comprehensively considers day-ahead planning costs, planned capacity costs, and real-time deviation costs, ultimately outputting the optimal day-ahead power purchase and sale plan and generating curves showing the changes in conditional regret and day-ahead dispatch costs for decision-making reference.
[0006] To achieve the above-mentioned technical features, the objective of this invention is as follows: a day-ahead multi-grid trading method considering multiple uncertainty factors, specifically including the following steps: Step 1: Construct a set of uncertainty scenarios, and build mathematical models to represent their uncertainties based on the data characteristics of load and interval inflow; Step 2: Use the Monte Carlo method to simulate and generate an initial random scenario set from the load and interval inflow scenario set, and use scenario reduction technology to reduce the initial random scenario set to a typical scenario set containing 5 typical scenarios and their corresponding occurrence probabilities. Step 3: For the generated set of typical scenarios, with the goal of minimizing the total operating cost, solve for the optimal scheduling plan and its minimum operating cost for each typical scenario, and use this as the benchmark for calculating regret. Step 4: Establish a two-stage stochastic optimization model with the objective of minimizing conditional regret, solve the model, and output the optimal day-ahead power purchase and sale plan.
[0007] Furthermore, the detailed steps for constructing the set of uncertain scenarios in step 1 are as follows: Step 1-1: Uncertainty modeling of inter-regional inflow is achieved through the following sub-steps. Its core is to construct a joint probability distribution that can reflect the spatial correlation of each watershed and generate representative scenarios. Specifically, five probability distribution functions are used to fit the marginal distribution of historical inter-regional inflow data. Then, five evaluation indicators are used to evaluate the goodness of fit, thereby selecting the optimal marginal distribution function. Step 1-2: Uncertainty modeling of power load focuses on describing the fluctuation range of prediction error. The specific operation steps are as follows: (1) Based on historical load data and its predicted values, analyze the statistical characteristics of load prediction error; assume that the load prediction error approximately follows a normal distribution with zero mean; (2) Based on the normal distribution characteristics, a polyhedral uncertainty set is constructed to define the possible range of load fluctuations.
[0008] Furthermore, in step 1-1: The five probability distribution functions refer to the Gamma distribution, Lognormal distribution, Weibull distribution, generalized extreme value distribution, and Pearson Type III distribution, respectively. The five evaluation metrics refer to the Kolmogorov-Smirnov test, Anderson-Darling test, root mean square error, Kling-Gupta efficiency, and Nash-Sutcliffe efficiency, respectively. (1) The Kolmogorov-Smirnov test is used to calculate the maximum difference between the candidate distribution of the inflow data in the historical interval and its empirical cumulative distribution function, so as to quantitatively evaluate the overall goodness of fit between the theoretical distribution and the empirical distribution of the inflow data in the historical interval. The specific calculation method is as follows: (1) In the formula, qIt is the inflow rate value of the interval, in cubic meters per second; n It refers to the number of historical inflow data periods; It is the empirical distribution function of the interval inflow data; It is the theoretical cumulative distribution function after estimating the distribution parameters using historical data; It is the maximum difference between the fitted distribution and the empirical distribution of the interval inflow data; (2) The Anderson-Darling test is used to measure the difference between the candidate distribution of historical inflow data and the cumulative distribution function of its empirical distribution at the tail, so as to select the probability distribution suitable for describing extreme inflow events. The specific calculation method is as follows: (2) In the formula, n It refers to the number of historical inflow data periods; It is the first i The inflow values of each interval are sorted in ascending order, in cubic meters per second; It corresponds to the interval inflow value The theoretical cumulative distribution function value; It corresponds to the interval inflow value The theoretical cumulative distribution function value; (3) The root mean square error (RMSE) is used to measure the dispersion between the theoretical value and the actual historical observation value of the inflow data under the candidate distribution in the historical interval, so as to quantify the overall numerical accuracy of the distribution fitting. The specific calculation method is as follows: (3) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; (4) The Kling-Gupta efficiency is used to measure the ability of candidate distributions of historical inflow data to reproduce trends, central locations and dispersion, and then to quantitatively evaluate the multi-objective goodness of fit between theoretical distributions and observed data. The specific calculation method is as follows: (4) In the formula, It is the correlation coefficient between the actual inflow rate in the interval and the fitted flow rate generated based on the candidate distribution; It is the ratio between the standard deviation of the historical interval inflow data and the standard deviation of the interval inflow data generated by the fitted distribution; It is the ratio of the mean inflow rate of the interval generated by the fitted distribution to the mean of the actual inflow rate of the interval; n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second; It is the average value of the interval inflow calculated based on the candidate distribution, in cubic meters per second; It is the standard deviation of the actual inflow rate in the interval, in cubic meters per second; It is the standard deviation calculated based on the candidate distribution, in cubic meters per second; (5) The Nash-Sutcliffe efficiency is used to measure the relative residual variance between the theoretical predicted value of the fitted distribution and the inflow data of the historical interval, so as to quantitatively evaluate the prediction accuracy of the model relative to the mean of the inflow data of the historical interval. The specific calculation method is as follows: (5) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second.
[0009] Furthermore, in steps 1-2, based on the normal distribution characteristics, a polyhedral uncertainty set is constructed to define the possible fluctuation range of the load. U The mathematical expression of is defined by the following equation: (6) In the formula, This is the actual load value, in megawatts; t It refers to time, measured in hours; This is the load forecast, in megawatts (MW). It is a random variable; It is a time period t Maximum load deviation, in megawatts; It refers to the level of uncertainty in variable fluctuations.
[0010] Furthermore, the detailed steps for constructing the set of uncertain scenarios in step 2 are as follows: Step 2-1: Based on the fitted single-basin interval inflow marginal distribution function, construct the multi-basin interval inflow joint distribution. The detailed construction method of the multi-basin interval inflow joint distribution is as follows: (1) According to Sklar's theorem, different Copula functions are used to connect the marginal distribution of inflow in a single watershed interval determined in step 1, thereby constructing a joint distribution of inflow in multiple watershed intervals; wherein, the different Copula functions refer to any one of GaussianCopula, t-Copula, Clayton Copula, Gumbel Copula and Frank Copula; (7) In the formula, Inflow from interval The obtained multivariate joint distribution function; It is the first i The interval inflow of each watershed is less than or equal to The probability of; Connected via copula functions The resulting inter-regional inflow joint distribution, It is the correlation coefficient; (2) Using the Akaike information criterion, the Bayesian information criterion, and the log-likelihood constant value, the optimal copula model suitable for constructing the joint distribution of inflows in multiple watersheds is selected; ①The Akaike Information Criterion (AIC) is a model selection criterion based on information theory. Its core function is to provide a quantitative evaluation of the relative merits of competing statistical models; its calculation formula is as follows: (8) In the formula, k It is the number of parameters in the copula model; L The maximum likelihood constant value; ② The Bayesian Information Criterion (BIC) is a model selection criterion based on Bayesian statistical theory. This criterion is used to evaluate the goodness of fit of a copula model with a joint distribution of inflows across multiple watersheds to historical inflow data. It introduces a penalty term proportional to the number of model parameters and the logarithm of the sample size, effectively preventing overfitting of the copula model in high-dimensional cases. Its calculation formula is as follows: (9) In the formula, k It is the number of parameters in the copula model; n It represents the inflow data volume over a historical period. L The maximum likelihood constant value; ③ The log-likelihood constant is calculated when constructing the joint inflow distribution across multiple watersheds. It is used to measure the log-likelihood function value of each candidate Copula model and reflects the overall goodness of fit of the Copula model to historical inflow data. The calculation formula is as follows: (10) In the formula, It is the parameter vector of the copula model; n It refers to the number of historical inflow data periods; It is the first in the interval inflow sample i Inflow values for each interval; It is the probability density function of the copula function; Step 2-2: Generate the joint distribution scenario of inflow within the interval and the load scenario respectively; (1) Based on the optimal copula model determined in step 2-1, a uniformly distributed random variable with spatial correlation is generated. Then, the uniformly distributed random variable is converted into the actual interval inflow through the inverse cumulative distribution function of the single watershed edge distribution constructed in step 1-1. Finally, the interval inflows of different watersheds are combined to generate a set of joint interval inflow scenarios with spatial correlation. (2) Based on the load uncertainty model constructed in steps 1-2, a set of random load scenarios is generated using the Monte Carlo simulation method; Steps 2-3: Use the K-means clustering algorithm to perform cluster analysis on the load scenario set and the joint interval inflow scenario set to obtain a typical scenario set composed of cluster centers; wherein, the probability of occurrence of each typical scenario is determined by the ratio of the number of scenarios contained in its corresponding cluster to the total number of scenarios.
[0011] Furthermore, the detailed steps for determining the optimal cost after the fact in step 3 are as follows: Step 3-1: The objective function includes the electricity price and capacity price for purchasing electricity from the external power grid; (11) In the formula, During the time period t No. s In each scenario, during the time period t The ex-post optimal cost, in yuan; It is the first s In each scenario, during the time period t The cost of purchased electricity capacity, in yuan; It is the first s In each scenario, during the time period t The cost of electricity purchased, in yuan; yes g The network is in the time periodt No. s Electricity purchase volume in each scenario, in megawatts; yes g The network is in the time period t No. s Electricity sales in each scenario, in megawatts; yes g The network is in the time period t The electricity purchase price, in yuan; g The network is in the time period t The electricity price, in yuan; yes g The network is in the time period t The unit capacity electricity price, in yuan; Step 3-2: The hydraulic constraints included in the model are: (1) Water balance constraint: (12) In the formula, It is the first i The hydropower station during the period t The storage capacity, in cubic meters; It is the first i The hydropower station during the period t +1 storage capacity, in cubic meters; It is the first i The hydropower station during the period t Inflow rate, in cubic meters per second; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; The time step is calculated in seconds. It is the first i The hydropower station during the period t The inflow interval, in cubic meters per second; It is the first i The hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; (2) Relationship between water level and reservoir capacity: (13) In the formula, It is the firsti The hydropower station during the period t The upper reservoir water level, in meters; The upper reservoir water level With storage capacity Relational functions; (3) Relationship between tailwater level and discharge flow: (14) In the formula, It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; Tailwater level and discharge flow Relational functions; (4) Relationship between turbine output, water head, and power generation flow rate: (15) In the formula, It is the first i A hydroelectric power station u Unit 1 during the period t Power output, measured in megawatts; It is the first i A hydroelectric power station u Unit 1 output With water head and power generation flow Relational functions; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t Hydropower head, measured in meters; (5) Power plant and unit flow constraints: (16) In the formula, It is the first i The hydropower station during the period t Outflow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The minimum power generation flow rate of a hydropower station, in cubic meters per second; It is the first i The maximum power generation flow of each hydropower station, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u Maximum power generation flow, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u The minimum power generation flow rate, in cubic meters per second; (6) Head and water level constraints: (17) In the formula, It is the first i The hydropower station during the period t Hydropower head, measured in meters; It is the first i The minimum generating head of a hydroelectric power station, in meters; It is the first i The maximum generating head of a hydroelectric power station, in meters; It is the first i The hydropower station during the period t The upper reservoir water level, in meters; It is the first i The hydropower station during the period t -1 represents the upper reservoir water level, in meters; It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The head loss constant, in meters; Step 3-3: The electrical constraints included in the model are: (1) Relationship between voltage phase and line power flow: (18) In the formula, It is a node m The voltage phase; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; m It is a side road mb The starting node on; b They are branch roads mb End nodes on; It is a side road mb The resistance; It is a side road mb The reactance; For nodesm The voltage amplitude.
[0012] (2) Relationship between voltage amplitude and line power flow (19) In the formula, For nodes m The voltage amplitude; branch road mb The current flowing above; It is a side road mb The resistance; It is a side road mb The reactance; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; (3) Node power balance constraints: (20) In the formula, It is with nodes m The connected first k The active power flowing in each branch; It is with nodes m The connected first k The reactive power flowing in each branch; It is a side road km Active power flowing upwards; It is a side road km The reactive power flowing upwards; branch road jm The current flowing above; It is a node m The electrical conductivity; It is a node m susceptance; It is a node m Active load; It is a node m reactive load; j For nodes m Connected upstream nodes; b For nodes m Connected downstream nodes; (4) Auxiliary second-order cone constraint: (twenty one) In the formula, It is a node m The voltage amplitude; It is a side road mb The current flowing above; It is a side road mnActive power flowing upwards; It is a side road mv The reactive power flowing upwards; (5) Branch capacity constraints: (twenty two) In the formula, It is a side road mb The maximum value of the active power flowing upward; It is a side road mb The maximum value of reactive power flowing upwards; It is a side road mb The minimum value of active power flowing upward; It is a side road mb The minimum value of reactive power flowing upward; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; (6) Node voltage amplitude constraints: (twenty three) In the formula, It is a node m The voltage amplitude; It is a node m The maximum value of the voltage amplitude; It is a node m Minimum voltage amplitude; (7) Node voltage phase angle constraint: (twenty four) In the formula, It is the phase of the reference node; It is a node m The voltage phase; It is a node m The maximum voltage phase; It is a node m The minimum voltage phase; (8) Output constraints of hydropower stations and generating units: (25) In the formula, It is the first i The generating units of the hydroelectric power station u During the period t Power output, measured in megawatts; It is the firsti A hydroelectric power station u Maximum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u Minimum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u The maximum reactive power output of Unit No. 1, in Mvar; They are the first i A hydroelectric power station u Minimum reactive power output of Unit No. 1, in Mvar; (9) Physical connection constraints: (26) In the formula, It is the main power grid A during the time period t With external power grid g Electricity trading volume, in megawatts; M It is a constant with a value of 500; It is the power grid g During the period t Connection status with main power grid A Indicates that the main power grid A is in the time period t Not allowed to the power grid g Purchase electricity Indicates that the main power grid A is in the time period t No electricity allowed to the power grid g Electricity sales.
[0013] Furthermore, the detailed steps for generating the optimal daily plan and decision in step 4 are as follows: Step 4-1: The conditional regret method can flexibly control the tail risk of regret in the day-ahead power purchase plan by adjusting the risk coefficient α, avoiding overly conservative scheduling plans. The objective function can be expressed as: (27) In the formula, The risk value of regret for day-ahead electricity purchase plans, in yuan; The confidence level for the conditional value-at-risk model; For the scene s The probability of occurrence; For the scene s Excess regret value exceeding the regret threshold of the current day's electricity purchase plan, in yuan; For the scene s Total daily regret rate, in yuan; Step 4-2: The calculation of scenario regret is as follows: (28) In the formula, For the scene s Total daily regret rate, in yuan; For the scene s During the period t The actual operating cost, in yuan; In fully foreseeable scenarios s In the case of, during the time period t Achievable ex-post optimal hourly cost, in yuan; (29) In the formula, During the period t The day-ahead planned cost of the China-Japan power purchase program, in yuan; During the period t The planned capacity cost for the day in, in yuan; It is a scene s During the period t Real-time deviation cost, in yuan; They are in the scene s Time period t The cost of network loss penalties in the data is expressed in yuan. It is the power grid g During the period t The planned electricity purchase volume, in megawatts; These are the power grids g During the period t Planned electricity sales, in megawatts; It is the power grid g During the period t The day-ahead electricity purchase price, in yuan / megawatt; It is the power grid g During the period t The current day's electricity price, in yuan / megawatt; It is the power grid g The unit capacity electricity price, in yuan / megawatt; It is a scene s China Power Grid g During the period t The positive deviation between the actual purchased electricity volume and the planned purchased electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The negative deviation between the actual purchased and sold electricity volume and the planned purchased and sold electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The settlement price for positive deviations, in yuan / megawatt; It is a scene sChina Power Grid g During the period t The settlement price for negative deviations, in yuan / megawatt; Step 4-3: Solve the conditional risk value with the objective function of minimizing the regret of the day-ahead scheduling plan to generate the day-ahead scheduling plan. Generate the change curves of conditional regret and day-ahead scheduling cost by adjusting the risk coefficient α.
[0014] The present invention has the following beneficial effects: 1. Provides adjustable and superior risk management capabilities: Unlike traditional risk-neutral (expected value) models or overly conservative minimum-maximum regret models, this invention employs CVaR—a measure of regret. This allows decision-makers to quantify the trade-off between cost and risk by adjusting the α parameter.
[0015] 2. It provides a fairer decision-making standard: the model seeks the difference between the current decision and the optimal decision after the fact. This means that the solution it looks for is the one that performs as close to the optimal solution as possible in all scenarios. This is a fairer decision-making standard. Attached Figure Description
[0016] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0017] Picture 1 This is the overall flowchart of the present invention.
[0018] Picture 2 This is the distribution fitting result of watershed one in the embodiment of the present invention.
[0019] Picture 3 This is the distribution fitting result of watershed two in this embodiment of the invention.
[0020] Picture 4 This is a copula surface diagram of the inflow between two watersheds in an embodiment of the present invention.
[0021] Picture 5 This is a sensitivity analysis chart of the risk aversion coefficient value on cost and conditional regret in an embodiment of the present invention.
[0022] Picture 6 This is a comparison of power purchase plans using different methods in Power Grid 1 in this embodiment of the invention.
[0023] Picture 7 This is a comparison of power purchase plans using different methods in Power Grid 2 in this embodiment of the invention. Detailed Implementation
[0024] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.
[0025] Example 1: like Picture 1 As shown, this embodiment provides a day-ahead multi-grid trading method that considers multiple uncertainties, specifically including the following steps: Step 1: Construct a set of uncertainty scenarios, and build mathematical models to represent their uncertainties based on the data characteristics of load and interval inflow; Step 2: Use the Monte Carlo method to simulate and generate an initial random scenario set from the load and interval inflow scenario set, and use scenario reduction technology to reduce the initial random scenario set to a typical scenario set containing 5 typical scenarios and their corresponding occurrence probabilities. Step 3: For the generated set of typical scenarios, with the goal of minimizing the total operating cost, solve for the optimal scheduling plan and its minimum operating cost for each typical scenario, and use this as the benchmark for calculating regret. Step 4: Establish a two-stage stochastic optimization model with the objective of minimizing conditional regret, solve the model, and output the optimal day-ahead power purchase and sale plan.
[0026] Furthermore, the detailed steps for constructing the set of uncertain scenarios in step 1 are as follows: Step 1-1, uncertainty modeling of inter-regional inflow, is achieved through the following sub-steps. The core of this step is to construct a joint probability distribution that reflects the spatial correlation between different watersheds and generate representative scenarios. Five probability distribution functions (Gamma distribution, Lognormal distribution, Weibull distribution, generalized extreme value distribution, and Pearson Type III distribution) are used to fit the marginal distribution of historical inter-regional inflow data. Then, five evaluation metrics (Kolmogorov-Smirnov test, Anderson-Darling test, root mean square error, Kling-Gupta efficiency, and Nash-Sutcliffe efficiency) are used to assess the goodness of fit, thereby selecting the optimal marginal distribution function. The specific descriptions of the five evaluation metrics are as follows: (1) The Kolmogorov-Smirnov test was used to calculate the maximum difference between the candidate distribution and the empirical cumulative distribution function of the inflow data in historical intervals. The purpose was to quantitatively evaluate the overall goodness of fit between the theoretical and empirical distributions of the inflow data in historical intervals. The specific calculation method is as follows: (1) In the formula, q It is the inflow rate value of the interval, in cubic meters per second; n It refers to the number of historical inflow data periods; It is the empirical distribution function of the interval inflow data; It is the theoretical cumulative distribution function after estimating the distribution parameters using historical data; It is the maximum difference between the fitted distribution and the empirical distribution of the interval inflow data; (2) The Anderson-Darling test is used to measure the difference between the candidate distribution of historical inflow data and the cumulative distribution function at the tail of its empirical distribution. The aim is to select a probability distribution suitable for describing extreme inflow events. The specific calculation method is as follows: (2) In the formula, n It refers to the number of historical inflow data periods; It is the first i The inflow values of each interval are sorted in ascending order, in cubic meters per second; It corresponds to the interval inflow value The theoretical cumulative distribution function value; It corresponds to the interval inflow value The theoretical cumulative distribution function value; (3) The root mean square error (RMSE) is used to measure the dispersion between the theoretical values and actual historical observations of the inflow data under the candidate distribution in the historical interval. The purpose is to quantify the overall numerical accuracy of the distribution fitting. The specific calculation method is as follows: (3) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; (4) The Kling-Gupta efficiency is used to measure the reproducibility of candidate distributions in terms of trend, central location, and dispersion of historical inflow data. The aim is to quantitatively evaluate the multi-objective goodness of fit between the theoretical distribution and the observed data. The specific calculation method is as follows: (4) In the formula, It is the correlation coefficient between the actual inflow rate in the interval and the fitted flow rate generated based on the candidate distribution; It is the ratio between the standard deviation of the historical interval inflow data and the standard deviation of the interval inflow data generated by the fitted distribution; It is the ratio of the mean inflow rate of the interval generated by the fitted distribution to the mean of the actual inflow rate of the interval; n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second; It is the average value of the interval inflow calculated based on the candidate distribution, in cubic meters per second; It is the standard deviation of the actual inflow rate in the interval, in cubic meters per second; It is the standard deviation calculated based on the candidate distribution, in cubic meters per second; (5) The Nash-Sutcliffe efficiency measure is used to evaluate the relative residual variance between the theoretical predicted values of the fitted distribution and the historical inflow data. The purpose is to quantitatively assess the model's predictive accuracy relative to the mean of the historical inflow data. The specific calculation method is as follows: (5) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second.
[0027] Step 1-2: Uncertainty modeling of power load focuses on describing the fluctuation range of prediction error. The specific operation steps are as follows: (1) Based on historical load data and its predicted values, analyze the statistical characteristics of load prediction error; assume that the load prediction error approximately follows a normal distribution with zero mean; (2) Based on the normal distribution characteristics, a polyhedral uncertainty set is constructed to define the possible fluctuation range of the load. U The mathematical expression of is defined by the following equation: (6) In the formula, This is the actual load value, in megawatts; t It refers to time, measured in hours; This is the load forecast, in megawatts (MW). It is a random variable; It is a time period t Maximum load deviation, in megawatts; It refers to the level of uncertainty in variable fluctuations.
[0028] Furthermore, the detailed steps for constructing the set of uncertain scenarios in step 2 are as follows: Step 2-1: Based on the fitted single-basin interval inflow marginal distribution function, construct the multi-basin interval inflow joint distribution. The detailed construction method of the multi-basin interval inflow joint distribution is as follows: (1) According to Sklar's theorem, the marginal distributions of inflows in the single-basin intervals determined in step 1 are connected using different Copula functions to construct a joint distribution of inflows in multiple basin intervals. The different Copula functions refer to one of GaussianCopula, t-Copula, Clayton Copula, Gumbel Copula, and Frank Copula.
[0029] (7) In the formula, Inflow from interval The obtained multivariate joint distribution function; It is the first i The interval inflow of each watershed is less than or equal to The probability of; Connected via copula functions The resulting inter-regional inflow joint distribution, It is the correlation coefficient; (2) Using the Akaike information criterion, the Bayesian information criterion, and the log-likelihood constant value, the optimal copula model suitable for constructing the joint distribution of inflows in multiple watersheds is selected; ①The Akaike Information Criterion (AIC) is a model selection criterion based on information theory. Its core function is to provide a quantitative evaluation of the relative merits of competing statistical models; its calculation formula is as follows: (8) In the formula, k It is the number of parameters in the copula model; L The maximum likelihood constant value; ② The Bayesian Information Criterion (BIC) is a model selection criterion based on Bayesian statistical theory. This criterion is used to evaluate the goodness of fit of a copula model with a joint distribution of inflows across multiple watersheds to historical inflow data. It introduces a penalty term proportional to the number of model parameters and the logarithm of the sample size, effectively preventing overfitting of the copula model in high-dimensional cases. Its calculation formula is as follows: (9) In the formula, k It is the number of parameters in the copula model; n It represents the inflow data volume over a historical period. L The maximum likelihood constant value; ③ The log-likelihood constant is calculated when constructing the joint inflow distribution across multiple watersheds. It is used to measure the log-likelihood function value of each candidate Copula model and reflects the overall goodness of fit of the Copula model to historical inflow data. The calculation formula is as follows: (10) In the formula, It is the parameter vector of the copula model; n It refers to the number of historical inflow data periods; It is the first in the interval inflow sample i Inflow values for each interval; It is the probability density function of the copula function; Step 2-2: Generate the joint distribution scenario of inflow within the interval and the load scenario respectively; (1) Based on the optimal copula model determined in step 2-1, a uniformly distributed random variable with spatial correlation is generated. Then, the uniformly distributed random variable is converted into the actual interval inflow through the inverse cumulative distribution function of the single watershed edge distribution constructed in step 1-1. Finally, the interval inflows of different watersheds are combined to generate a set of joint interval inflow scenarios with spatial correlation. (2) Based on the load uncertainty model constructed in steps 1-2, a set of random load scenarios is generated using the Monte Carlo simulation method; Steps 2-3: The K-means clustering algorithm is used to perform cluster analysis on the load scenario set and the joint interval inflow scenario set to obtain a typical scenario set composed of cluster centers; wherein, the probability of occurrence of each typical scenario is determined by the ratio of the number of scenarios contained in its corresponding cluster to the total number of scenarios.
[0030] Furthermore, the detailed steps for determining the optimal cost after the fact in step 3 are as follows: Step 3-1, the objective function includes the electricity price and capacity price for purchasing electricity from the external power grid; (11) In the formula, During the time period t No. s In each scenario, during the time period t The ex-post optimal cost, in yuan; It is the first s In each scenario, during the time period t The cost of purchased electricity capacity, in yuan; It is the first s In each scenario, during the time period t The cost of electricity purchased, in yuan; yes g The network is in the time period t No. s Electricity purchase volume in each scenario, in megawatts; yes g The network is in the time period t No. s Electricity sales in each scenario, in megawatts; yes g The network is in the time period t The electricity purchase price, in yuan; g The network is in the time period t The electricity price, in yuan; yes g The network is in the time period t The unit capacity electricity price, in yuan; Step 3-2, the hydraulic constraints included in the model are: (1) Water balance constraint: (12) In the formula, It is the first i The hydropower station during the period t The storage capacity, in cubic meters; It is the first i The hydropower station during the period t +1 storage capacity, in cubic meters; It is the first i The hydropower station during the period t Inflow rate, in cubic meters per second; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; The time step is calculated in seconds. It is the first i The hydropower station during the period t The inflow interval, in cubic meters per second; It is the first iThe hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; (2) Relationship between water level and reservoir capacity: (13) In the formula, It is the first i The hydropower station during the period t The upper reservoir water level, in meters; The upper reservoir water level With storage capacity Relational functions; (3) Relationship between tailwater level and discharge flow: (14) In the formula, It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; Tailwater level and discharge flow Relational functions; (4) Relationship between turbine output, water head, and power generation flow rate: (15) In the formula, It is the first i A hydroelectric power station u Unit 1 during the period t Power output, measured in megawatts; It is the first i A hydroelectric power station u Unit 1 output With water head and power generation flow Relational functions; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t Hydropower head, measured in meters; (5) Power plant and unit flow constraints: (16) In the formula, It is the first i The hydropower station during the period t Outflow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The minimum power generation flow rate of a hydropower station, in cubic meters per second; It is the first i The maximum power generation flow of each hydropower station, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u Maximum power generation flow, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u The minimum power generation flow rate, in cubic meters per second; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; (6) Head and water level constraints: (17) In the formula, It is the first i The hydropower station during the period t Hydropower head, measured in meters; It is the first i The minimum generating head of a hydroelectric power station, in meters; It is the first i The maximum generating head of a hydroelectric power station, in meters; It is the first i The hydropower station during the period t The upper reservoir water level, in meters; It is the first i The hydropower station during the period t -1 represents the upper reservoir water level, in meters; It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The head loss constant, in meters; Step 3-3, the electrical constraints included in the model are: (1) Relationship between voltage phase and line power flow: (18) In the formula, It is a node m The voltage phase; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; m It is a side road mb The starting node on; b They are branch roads mb End nodes on; It is a side road mb The resistance; It is a side road mb The reactance; For nodes m The voltage amplitude.
[0031] (2) Relationship between voltage amplitude and line power flow (19) In the formula, For nodes m The voltage amplitude; branch road mb The current flowing above; It is a side road mb The resistance; It is a side road mb The reactance; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; (3) Node power balance constraints: (20) In the formula, It is with nodes m The connected first k The active power flowing in each branch; It is with nodes m The connected first k The reactive power flowing in each branch; It is a side road km Active power flowing upwards; It is a side road km The reactive power flowing upwards; branch road jm The current flowing above; It is a nodem The electrical conductivity; It is a node m susceptance; It is a node m Active load; It is a node m reactive load; j For nodes m Connected upstream nodes; b For nodes m Connected downstream nodes; (4) Auxiliary second-order cone constraint: (twenty one) In the formula, It is a node m The voltage amplitude; It is a side road mb The current flowing above; It is a side road mn Active power flowing upwards; It is a side road mv The reactive power flowing upwards; (5) Branch capacity constraints: (twenty two) In the formula, It is a side road mb The maximum value of the active power flowing upward; It is a side road mb The maximum value of reactive power flowing upwards; It is a side road mb The minimum value of active power flowing upward; It is a side road mb The minimum value of reactive power flowing upward; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; (6) Node voltage amplitude constraints: (twenty three) In the formula, It is a node m The voltage amplitude; It is a node m The maximum value of the voltage amplitude; It is a node m Minimum voltage amplitude; (7) Node voltage phase angle constraint: (twenty four) In the formula, It is the phase of the reference node; It is a node m The voltage phase; It is a node m The maximum voltage phase; It is a node m The minimum voltage phase; (8) Output constraints of hydropower stations and generating units: (25) In the formula, It is the first i The generating units of the hydroelectric power station u During the period t Power output, measured in megawatts; It is the first i A hydroelectric power station u Maximum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u Minimum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u The maximum reactive power output of Unit No. 1, in Mvar; They are the first i A hydroelectric power station u Minimum reactive power output of Unit No. 1, in Mvar; (9) Physical connection constraints: (26) In the formula, It is the main power grid A during the time period t With external power grid g Electricity trading volume, in megawatts; M It is a constant with a value of 500; It is the power grid g During the period t Connection status with main power grid A Indicates that the main power grid A is in the time period t No electricity allowed to the power grid g Purchase electricity Indicates that the main power grid A is in the time period t No electricity allowed to the power grid g Electricity sales.
[0032] Furthermore, the detailed steps for generating the optimal daily plan and decision in step 4 are as follows: The conditional regret method in step 4-1 can flexibly control the tail risk of regret in the day-ahead power purchase plan by adjusting the risk coefficient α, thus avoiding overly conservative scheduling plans. The objective function can be expressed as: (27) In the formula, The risk value of regret for day-ahead electricity purchase plans, in yuan; The confidence level for the conditional value-at-risk model; For the scene s The probability of occurrence; For the scene s Excess regret value exceeding the regret threshold of the current day's electricity purchase plan, in yuan; For the scene s Total daily regret rate, in yuan; The calculation of scenario regret in step 4-2 is as follows: (28) In the formula, For the scene s Total daily regret rate, in yuan; For the scene s During the period t The actual operating cost, in yuan; In fully foreseeable scenarios s In the case of, during the time period t Achievable ex-post optimal hourly cost, in yuan; (29) In the formula, During the period t The day-ahead planned cost of the China-Japan power purchase program, in yuan; During the period t The planned capacity cost for the day in, in yuan; It is a scene s During the period t Real-time deviation cost, in yuan; They are in the scene s Time period t The cost of network loss penalties in the data is expressed in yuan. It is the power grid g During the period t The planned electricity purchase volume, in megawatts; These are the power grids g During the period t Planned electricity sales, in megawatts; It is the power grid g During the period t The day-ahead electricity purchase price, in yuan / megawatt; It is the power grid g During the period t The current day's electricity price, in yuan / megawatt; It is the power grid gThe unit capacity electricity price, in yuan / megawatt; It is a scene s China Power Grid g During the period t The positive deviation between the actual purchased electricity volume and the planned purchased electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The negative deviation between the actual purchased and sold electricity volume and the planned purchased and sold electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The settlement price for positive deviations, in yuan / megawatt; It is a scene s China Power Grid g During the period t The settlement price for negative deviations, in yuan / megawatt; Step 4-3: Solve the conditional risk value with the objective function of minimizing the regret of the day-ahead scheduling plan to generate the day-ahead scheduling plan. Generate the change curves of conditional regret and day-ahead scheduling cost by adjusting the risk coefficient α.
[0033] Example 2: The following study uses a river basin in southwestern my country as a model, selecting five hydropower stations on two rivers within this basin as research objects. These include hydropower stations with varying regulation capacities, such as reservoir-type and run-of-river type, with a total installed capacity of 351.5 MW. An additional 100 MW thermal power station serves as the base load.
[0034] Picture 2 and Picture 3 These figures show the results of uncertainty modeling for the interval inflow of two watersheds in this embodiment of the invention. Each figure contains two sub-figures, showing the fitting results of the probability density function and the cumulative distribution function, respectively. The left figure shows a comparison of the probability density functions of the empirical distribution and the five theoretical distributions in watershed one. The flow rate in watershed one is mainly distributed in the range of 60-160 m³ / s, while the flow rate in watershed two is mainly distributed in the range of 20-70 m³ / s. It can be seen that there are significant differences in the distribution characteristics between the two watersheds. The optimal marginal distribution was selected for each watershed from the candidate distributions, laying a solid foundation for the subsequent construction of an accurate joint probability distribution.
[0035] Table 1 shows the results of fitting the joint distribution function of inter-basin inflow between five copula functions using three evaluation indicators. The three evaluation indicators are AIC, BIC, and LogLikelihood; lower values indicate better copula function performance. It can be seen that the Gaussian copula function has the lowest AIC and BIC values among the five copula functions, and its LogLikelihood value is also relatively good. Therefore, the Gaussian copula function is selected as the optimal copula function for inter-basin inflow during this water season. Picture 4 The joint dependency structure between the two watersheds is shown, and it can be seen that the model effectively fits the positive correlation between the two watersheds. The high density of the two points (0,0) and (1,1) verifies this.
[0036] Table 2 shows the total cost of this method under different risk coefficients and different methods. Taking the conditional regret model with α=0, which has the lowest cost, as the economic benchmark, the total cost of minimizing maximum regret and the traditional robust optimization method is 5.45% and 1.82% higher, respectively. Picture 5 The trends of day-ahead costs and conditional regret are shown under different risk aversion parameters (α). A value of α=0 represents a risk-neutral stance, where the model aims to minimize the average regret across all possible scenarios. In contrast, α>0 represents a risk-averse stance, where the model focuses only on minimizing the average regret at the worst (1-α) tail. The CVaR value exhibits a smooth change as the risk aversion parameter α increases. This indicates that the model's focus is shifting from the average regret across all scenarios to focusing only on the worst (1-α) extreme case that could cause significant economic loss. The smoothness of the model demonstrates its ability to produce predictable and accurate results despite changes in risk appetite.
[0037] Picture 6 and Picture 7 The performance of the traditional optimization method and the model under three different risk aversion parameters are presented respectively. It can be seen that the difference in cost is due to the different electricity purchase strategies employed by the different methods: conditional regret (α=0) avoids purchasing electricity from the high-cost X grid during off-peak hours, while minimizing maximum regret involves continuously purchasing more electricity in all periods to prevent the worst-case scenario. The traditional robust optimization method is a trade-off between these two extreme approaches. Therefore, it can be seen that the proposed framework outperforms the traditional method in terms of pure economic efficiency.
[0038] Table 1 shows the specific performance of different copula functions in fitting interval inflow.
[0039] Table 2 Comparison of total cost and relative cost ratios under different methods
[0040] Although the preferred embodiments of the present invention have been described above in conjunction with the accompanying drawings, the present invention is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many specific modifications under the guidance of the present invention without departing from the spirit of the invention and the scope of protection of the claims, and these modifications all fall within the scope of protection of the present invention.
Claims
1. A day-ahead multi-grid trading method considering multiple uncertainties, characterized in that, First, a set of scenarios with uncertainties in load and inter-regional inflow is constructed, and mathematical models representing these uncertainties are established for each scenario. Second, the Monte Carlo method is used to simulate and generate initial scenarios of load and inter-regional inflow, and a clustering algorithm is used to reduce the number of scenarios, thereby obtaining representative typical scenarios of load and inter-regional inflow and their probabilities of occurrence. Then, the optimal scheduling plan and its operating cost under each typical scenario are calculated. Finally, a two-stage stochastic optimization model is established with the goal of minimizing conditional regret, and the optimal day-ahead power purchase and sale plan is output to achieve an effective balance between economic efficiency and risk.
2. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, Specifically, the steps include the following: Step 1: Construct a set of uncertainty scenarios, and build mathematical models to represent their uncertainties based on the data characteristics of load and interval inflow; Step 2: Use the Monte Carlo method to simulate and generate an initial random scenario set from the load and interval inflow scenario set, and use scenario reduction technology to reduce the initial random scenario set to a typical scenario set containing 5 typical scenarios and their corresponding occurrence probabilities. Step 3: For the generated set of typical scenarios, with the goal of minimizing the total operating cost, solve for the optimal scheduling plan and its minimum operating cost for each typical scenario, and use this as the benchmark for calculating regret. Step 4: Establish a two-stage stochastic optimization model with the objective of minimizing conditional regret, solve the model, and output the optimal day-ahead power purchase and sale plan.
3. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, The detailed steps for constructing the set of uncertain scenarios in step 1 are as follows: Step 1-1: Uncertainty modeling of inter-regional inflow is achieved through the following sub-steps. Its core is to construct a joint probability distribution that can reflect the spatial correlation of each watershed and generate representative scenarios. Specifically, five probability distribution functions are used to fit the marginal distribution of historical inter-regional inflow data. Then, five evaluation indicators are used to evaluate the goodness of fit, thereby selecting the optimal marginal distribution function. Step 1-2: Uncertainty modeling of power load focuses on describing the fluctuation range of prediction error. The specific operation steps are as follows: (1) Based on historical load data and its forecast values, analyze the statistical characteristics of load forecast error; assume that the load forecast error approximately follows a normal distribution with zero mean; (2) Based on the normal distribution characteristics, a polyhedral uncertainty set is constructed to define the possible range of load fluctuations.
4. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, In step 1-1: The five probability distribution functions refer to the Gamma distribution, Lognormal distribution, Weibull distribution, generalized extreme value distribution, and Pearson Type III distribution, respectively. The five evaluation metrics refer to the Kolmogorov-Smirnov test, Anderson-Darling test, root mean square error, Kling-Gupta efficiency, and Nash-Sutcliffe efficiency, respectively. (1) The Kolmogorov-Smirnov test is used to calculate the maximum difference between the candidate distribution of the inflow data in the historical interval and its empirical cumulative distribution function, so as to quantitatively evaluate the overall goodness of fit between the theoretical distribution and the empirical distribution of the inflow data in the historical interval. The specific calculation method is as follows: (1) In the formula, q It is the inflow rate value of the interval, in cubic meters per second; n It refers to the number of historical inflow data periods; It is the empirical distribution function of the interval inflow data; It is the theoretical cumulative distribution function after estimating the distribution parameters using historical data; It is the maximum difference between the fitted distribution and the empirical distribution of the interval inflow data; (2) The Anderson-Darling test is used to measure the difference between the candidate distribution of historical inflow data and the cumulative distribution function of its empirical distribution at the tail, so as to select the probability distribution suitable for describing extreme inflow events. The specific calculation method is as follows: (2) In the formula, n It refers to the number of historical inflow data periods; It is the first i The inflow values of each interval are sorted in ascending order, in cubic meters per second; It corresponds to the interval inflow value The theoretical cumulative distribution function value; It corresponds to the interval inflow value The theoretical cumulative distribution function value; (3) The root mean square error (RMSE) is used to measure the dispersion between the theoretical value and the actual historical observation value of the inflow data under the candidate distribution in the historical interval, so as to quantify the overall numerical accuracy of the distribution fitting. The specific calculation method is as follows: (3) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; (4) The Kling-Gupta efficiency is used to measure the ability of candidate distributions of historical inflow data to reproduce trends, central locations and dispersion, and then to quantitatively evaluate the multi-objective goodness of fit between theoretical distributions and observed data. The specific calculation method is as follows: (4) In the formula, It is the correlation coefficient between the actual inflow rate in the interval and the fitted flow rate generated based on the candidate distribution; It is the ratio between the standard deviation of the historical interval inflow data and the standard deviation of the interval inflow data generated by the fitted distribution; It is the ratio of the mean inflow rate of the interval generated by the fitted distribution to the mean of the actual inflow rate of the interval; n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second; It is the average value of the interval inflow calculated based on the candidate distribution, in cubic meters per second; It is the standard deviation of the actual inflow rate in the interval, in cubic meters per second; It is the standard deviation calculated based on the candidate distribution, in cubic meters per second; (5) The Nash-Sutcliffe efficiency is used to measure the relative residual variance between the theoretical predicted value of the fitted distribution and the inflow data of the historical interval, so as to quantitatively evaluate the prediction accuracy of the model relative to the mean of the inflow data of the historical interval. The specific calculation method is as follows: (5) In the formula, n It refers to the number of historical inflow data periods; It is the first i The actual inflow rate values for each interval, in cubic meters per second; It is the first one calculated based on the candidate distribution. i Flow rate value, in cubic meters per second; It is the average value of the actual inflow rate in the interval, in cubic meters per second.
5. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, In steps 1-2, based on the normal distribution characteristics, a polyhedral uncertainty set is constructed to define the possible range of load fluctuations. U The mathematical expression of is defined by the following equation: (6) In the formula, This is the actual load value, in megawatts; t It refers to time, measured in hours; This is the load forecast, in megawatts (MW). It is a random variable; It is a time period t Maximum load deviation, in megawatts; It refers to the level of uncertainty in variable fluctuations.
6. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, The detailed steps for constructing the set of uncertain scenarios in step 2 are as follows: Step 2-1: Based on the fitted single-basin interval inflow marginal distribution function, construct the multi-basin interval inflow joint distribution. The detailed construction method of the multi-basin interval inflow joint distribution is as follows: (1) According to Sklar's theorem, different Copula functions are used to connect the marginal distribution of inflow in a single watershed interval determined in step 1, thereby constructing a joint distribution of inflow in multiple watershed intervals; wherein, the different Copula functions refer to any one of GaussianCopula, t-Copula, Clayton Copula, Gumbel Copula and Frank Copula; (7) In the formula, Inflow from interval The obtained multivariate joint distribution function; It is the first i The interval inflow of each watershed is less than or equal to The probability of; Connected via copula functions The resulting inter-regional inflow joint distribution, It is the correlation coefficient; (2) Using the Akaike information criterion, the Bayesian information criterion, and the log-likelihood constant value, the optimal copula model suitable for constructing the joint distribution of inflows in multiple watersheds is selected; ①The Akaike Information Criterion (AIC) is a model selection criterion based on information theory, and its calculation formula is as follows: (8) In the formula, k It is the number of parameters in the copula model; L The maximum likelihood constant value; ② The Bayesian Information Criterion (BIC) is a model selection criterion based on Bayesian statistical theory. This criterion is used to evaluate the goodness of fit of a copula model with a joint distribution of inflows across multiple watersheds to historical inflow data. It introduces a penalty term proportional to the number of model parameters and the logarithm of the sample size, effectively preventing overfitting of the copula model in high-dimensional cases. Its calculation formula is as follows: (9) In the formula, k It is the number of parameters in the copula model; n It represents the inflow data volume over a historical period. L The maximum likelihood constant value; ③ The log-likelihood constant value is calculated when constructing the joint inflow distribution across multiple watersheds, using the log-likelihood function value of each candidate Copula model. The calculation formula is as follows: (10) In the formula, It is the parameter vector of the copula model; n It refers to the number of historical inflow data periods; It is the first in the interval inflow sample i Inflow values for each interval; It is the probability density function of the copula function; Step 2-2: Generate the joint distribution scenario of inflow within the interval and the load scenario respectively; (1) Based on the optimal copula model determined in step 2-1, a uniformly distributed random variable with spatial correlation is generated. Then, the uniformly distributed random variable is converted into the actual interval inflow through the inverse cumulative distribution function of the single watershed edge distribution constructed in step 1-1. Finally, the interval inflows of different watersheds are combined to generate a set of joint interval inflow scenarios with spatial correlation. (2) Based on the load uncertainty model constructed in steps 1-2, a set of random load scenarios is generated using the Monte Carlo simulation method; Steps 2-3: The K-means clustering algorithm is used to perform cluster analysis on the load scenario set and the joint interval inflow scenario set to obtain a typical scenario set composed of cluster centers; wherein, the probability of occurrence of each typical scenario is determined by the ratio of the number of scenarios contained in its corresponding cluster to the total number of scenarios.
7. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, The detailed steps for determining the optimal cost after the fact in step 3 are as follows: Step 3-1: The objective function includes the electricity price and capacity price for purchasing electricity from the external power grid; (11) In the formula, During the time period t No. s In each scenario, during the time period t The ex-post optimal cost, in yuan; It is the first s In each scenario, during the time period t The cost of purchased electricity capacity, in yuan; It is the first s In each scenario, during the time period t The cost of electricity purchased, in yuan; yes g The network is in the time period t No. s Electricity purchase volume in each scenario, in megawatts; yes g The network is in the time period t No. s Electricity sales in each scenario, in megawatts; yes g The network is in the time period t The electricity purchase price, in yuan; g The network is in the time period t The electricity price, in yuan; yes g The network is in the time period t Electricity price per unit capacity, in yuan; Step 3-2: The hydraulic constraints included in the model are: (1) Water balance constraint: (12) In the formula, It is the first i The hydropower station during the period t The storage capacity, in cubic meters; It is the first i The hydropower station during the period t +1 storage capacity, in cubic meters; It is the first i The hydropower station during the period t Inflow rate, in cubic meters per second; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; The time step is calculated in seconds. It is the first i The hydropower station during the period t The inflow interval, in cubic meters per second; It is the first i The hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t The power generation flow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; (2) Relationship between water level and reservoir capacity: (13) In the formula, It is the first i The hydropower station during the period t The upper reservoir water level, in meters; It is the water level of the upper reservoir. With storage capacity Relational functions; (3) Relationship between tailwater level and discharge flow: (14) In the formula, It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The discharge flow rate, in cubic meters per second; Tailwater level and discharge flow Relational functions; (4) Relationship between turbine output, water head, and power generation flow rate: (15) In the formula, It is the first i A hydroelectric power station u Unit 1 during the period t Power output, measured in megawatts; It is the first i A hydroelectric power station u Unit 1 output With water head and power generation flow Relational functions; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The hydropower station during the period t Hydropower head, measured in meters; (5) Power plant and unit flow constraints: (16) In the formula, It is the first i The hydropower station during the period t Outflow rate, in cubic meters per second; It is the first i A hydroelectric power station u Unit 1 during the period t The power generation flow rate, in cubic meters per second; It is the first i The minimum power generation flow rate of a hydropower station, in cubic meters per second; It is the first i The maximum power generation flow of each hydropower station, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u Maximum power generation flow, in cubic meters per second; It is the first i The generating units of the hydroelectric power station u The minimum power generation flow rate, in cubic meters per second; (6) Head and water level constraints: (17) In the formula, It is the first i The hydropower station during the period t Hydropower head, measured in meters; It is the first i The minimum generating head of a hydroelectric power station, in meters; It is the first i The maximum generating head of a hydroelectric power station, in meters; It is the first i The hydropower station during the period t The upper reservoir water level, in meters; It is the first i The hydropower station during the period t -1 represents the upper reservoir water level, in meters; It is the first i The hydropower station during the period t The tailwater level, in meters; It is the first i The hydropower station during the period t The head loss constant, in meters; Step 3-3, the electrical constraints included in the model are: (1) Relationship between voltage phase and line power flow: (18) In the formula, It is a node m The voltage phase; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; m It is a side road mb The starting node on; b They are branch roads mb End nodes on; It is a side road mb The resistance; It is a side road mb The reactance; For nodes m The voltage amplitude; (2) Relationship between voltage amplitude and line power flow (19) In the formula, For nodes m The voltage amplitude; branch road mb The current flowing above; It is a side road mb The resistance; It is a side road mb The reactance; It is a side road mb Active power flowing upwards; It is a side road mb The reactive power flowing upwards; (3) Node power balance constraints: (20) In the formula, It is with nodes m The connected first k The active power flowing in each branch; It is with nodes m The connected first k The reactive power flowing in each branch; It is a side road km Active power flowing upwards; It is a side road km The reactive power flowing upwards; branch road jm The current flowing above; It is a node m The electrical conductivity; It is a node m susceptance; It is a node m Active load; It is a node m reactive load; j For nodes m Connected upstream nodes; b For nodes m Connected downstream nodes; (4) Auxiliary second-order cone constraint: (21) In the formula, It is a node m The voltage amplitude; It is a side road mb The current flowing above; It is a side road mn Active power flowing upwards; It is a side road mv The reactive power flowing upwards; (5) Branch capacity constraints: (22) In the formula, It is a side road mb The maximum value of the active power flowing upward; It is a side road mb The maximum value of reactive power flowing upwards; It is a side road mb The minimum value of active power flowing upward; It is a side road mb The minimum value of reactive power flowing upward; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; It is a side road mb The maximum apparent power of the upward flow; It is a side road mb The minimum apparent power of the upward flow; (6) Node voltage amplitude constraints: (23) In the formula, It is a node m The voltage amplitude; It is a node m The maximum value of the voltage amplitude; It is a node m Minimum voltage amplitude; (7) Node voltage phase angle constraint: (24) In the formula, It is the phase of the reference node; It is a node m The voltage phase; It is a node m The maximum voltage phase; It is a node m The minimum voltage phase; (8) Output constraints of hydropower stations and generating units: (25) In the formula, It is the first i The generating units of the hydroelectric power station u During the period t Power output, measured in megawatts; It is the first i A hydroelectric power station u Maximum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u Minimum active power output of Unit No. 1, in megawatts; It is the first i A hydroelectric power station u The maximum reactive power output of Unit No. 1, in Mvar; They are the first i A hydroelectric power station u Minimum reactive power output of Unit No. 1, in Mvar; (9) Physical connection constraints: (26) In the formula, It is the main power grid A during the time period t With external power grid g Electricity trading volume, in megawatts; M It is a constant with a value of 500; It is the power grid g During the period t Connection status with main power grid A Indicates that the main power grid A is in the time period t No electricity allowed to the power grid g Purchase electricity Indicates that the main power grid A is in the time period t No electricity allowed to the power grid g Electricity sales.
8. The day-ahead multi-grid trading method considering multiple uncertainties according to claim 1, characterized in that, The detailed steps for generating the optimal day-ahead plan and decision in step 4 are as follows: Step 4-1: The conditional regret method can flexibly control the tail risk of regret in the day-ahead power purchase plan by adjusting the risk coefficient α, avoiding overly conservative scheduling plans. The objective function can be expressed as: (27) In the formula, The risk value of regret for day-ahead electricity purchase plans, in yuan; The confidence level for the conditional value at risk model; For the scene s The probability of occurrence; For the scene s Excess regret value exceeding the regret threshold of the current day's electricity purchase plan, in yuan; For the scene s Total daily regret rate, in yuan; The calculation of scenario regret in step 4-2 is as follows: (28) In the formula, For the scene s Total daily regret rate, in yuan; For the scene s During the period t The actual operating cost, in yuan; In fully foreseeable scenarios s In the case of, during the time period t Achievable ex-post optimal hourly cost, in yuan; (29) In the formula, During the period t The day-ahead planned cost of the China-Japan power purchase program, in yuan; During the period t The planned capacity cost for the day in, in yuan; It is a scene s During the period t Real-time deviation cost, in yuan; They are in the scene s Time period t The cost of network loss penalties in the data is expressed in yuan. It is the power grid g During the period t The planned electricity purchase volume, in megawatts; These are the power grids g During the period t Planned electricity sales, in megawatts; It is the power grid g During the period t The day-ahead electricity purchase price, in yuan / megawatt; It is the power grid g During the period t The current day's electricity price, in yuan / megawatt; It is the power grid g The unit capacity electricity price, in yuan / megawatt; It is a scene s China Power Grid g During the period t The positive deviation between the actual purchased electricity volume and the planned purchased electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The negative deviation between the actual purchased and sold electricity volume and the planned purchased and sold electricity volume, in megawatts; It is a scene s China Power Grid g During the period t The settlement price for positive deviations, in yuan / megawatt; It is a scene s China Power Grid g During the period t The settlement price for negative deviations, in yuan / megawatt; Step 4-3: Solve the conditional risk value with the objective function of minimizing the regret of the day-ahead scheduling plan to generate the day-ahead scheduling plan. Generate the change curves of conditional regret and day-ahead scheduling cost by adjusting the risk coefficient α.