A method and system for processing power producer electric-carbon market transaction data
By constructing a two-tier decision-making model for medium- and long-term and spot trading, and a joint market clearing model for electricity and carbon, the problem of multi-timescale coordination in electricity and carbon market trading was solved, thereby maximizing the comprehensive benefits for power generators and improving the scientific nature of their decisions.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- STATE GRID SHANGHAI MUNICIPAL ELECTRIC POWER CO
- Filing Date
- 2026-02-05
- Publication Date
- 2026-05-29
AI Technical Summary
The lack of multi-timescale collaborative modeling in existing electricity-carbon market trading decisions leads to uncoordinated trading, making it difficult to minimize carbon costs. Furthermore, the lack of tight coupling between spot trading decisions and joint electricity-carbon clearing affects the scientific nature of power generators' decisions and optimization objectives.
A two-tier decision-making model is constructed for the medium- and long-term and spot trading stages. The dynamic proportional decomposition method and the electricity price and carbon quota price prediction model are adopted. The linearization process is combined with KKT conditions to optimize the trading strategy of power generators. The optimization is further achieved by constructing an electricity-carbon joint market clearing model.
It has achieved synergistic optimization between medium- and long-term and spot trading, improved the overall returns and scientific decision-making of power generators in the electricity-carbon market, promoted effective connection between markets, and enhanced the trading strategy formulation capabilities of power generators.
Smart Images

Figure CN122115104A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of electricity-carbon market transaction data processing, and specifically relates to a method and system for processing electricity-carbon market transaction data of power generators. Background Technology
[0002] With the advancement of the low-carbon energy transition, the coordinated operation of the electricity market and carbon market, as important mechanisms for promoting emission reduction, is receiving increasing attention. Power generators, as key participants in the electricity-carbon market, need to coordinate electricity trading and carbon quota management across multiple time scales to maximize overall benefits. Currently, power generators primarily use medium- and long-term contracts to lock in revenue in the electricity market and make flexible adjustments in the spot market; while in the carbon market, they need to make trading decisions based on quota gaps and price fluctuations to fulfill their annual obligations.
[0003] However, existing electricity-carbon market trading decisions have two significant limitations: First, traditional trading decisions often treat carbon trading as a static constraint, failing to consider multiple time scales and lacking systematic modeling for coordinated trading across multiple time scales. This leads to incoordination issues for power generators due to time differences, making it difficult to minimize carbon costs. Second, in spot trading decisions, the coupling between electricity-carbon market trading decisions and joint electricity-carbon clearing is not tight, and existing algorithms struggle to directly find the global optimum. Traditional models often ignore the impact of power generator bidding behavior on market clearing prices, lack a two-way feedback mechanism, and result in decisions deviating from actual market equilibrium. This leads to difficulties for power generators in decision-making and conflicting optimization objectives. Summary of the Invention
[0004] To address the shortcomings of existing technologies, this invention provides a method and system for processing data in the electricity-carbon market transactions of power generators, in order to solve the technical problems of insufficient coordination between power plants and the spot market in multi-scale electricity-carbon market transactions in the medium and long term, as well as the disconnect between power generator decision-making and market clearing in spot transactions.
[0005] To solve the above-mentioned technical problems, the present invention adopts the following technical solution.
[0006] This invention first discloses a method for processing power generator-carbon market transaction data, which includes the following steps: Step 1: Divide the power generation and carbon market transactions into medium- and long-term trading phases and spot trading phases. In the medium- and long-term trading phase, construct electricity price and carbon quota price prediction models, adopt the dynamic proportional decomposition method, adjust the daily decomposition volume based on wind and solar output prediction, and construct a trading decision model for the medium- and long-term trading phase that takes into account price fluctuations. Step 2: In the spot trading stage, a two-layer decision-making model is constructed. The upper layer constructs a power generator electricity-carbon trading decision-making model for the spot trading stage, decomposes the monthly contract volume to obtain the power generator's electricity market spot trading strategy and carbon market trading quota. The lower layer constructs an electricity-carbon joint market clearing model to optimize the trading decisions in the spot trading stage. Step 3: Linearize the lower-level market clearing model and the upper-level power generator decision-making model using KKT conditions, solve the mixed integer linear programming model, and obtain the electricity price, carbon price, and optimal output of each unit in the electricity-carbon market. The trading decision model for the medium- and long-term trading phase aims to maximize overall returns, taking into account both electricity revenue and carbon trading costs, and determines the monthly carbon quota trading volume for power generators. Its objective function is:
[0007] In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market transactions during the medium- and long-term trading phases. This refers to the monthly power generation under medium- to long-term contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m.
[0008] The present invention further includes the following preferred embodiments: The construction of the carbon quota price prediction model further includes: Collect historical data on carbon allowance prices for a preset trading period in the carbon market of the region to be predicted. The historical data is continuous data at the same time scale. The ADF unit root test is used to determine the stationarity of the historical carbon price series. If the test result shows that the carbon price series is non-stationary, it is differencing and the test process is repeated until it passes the stationarity test. The model is selected based on the characteristics of the autocorrelation function (ACF) and partial autocorrelation function (PACF) of the stationary carbon price series. If the ACF tails while the PACF is truncated at order p, an AR(p) model is established. If the PACF tails while the ACF is truncated at order q, an MA(q) model is established. If both tail, an ARMA(p, q) or ARIMA(p, d, q) model is established. p, d, and q represent the lag order of the autoregressive term, the difference order, and the moving average term, respectively. Based on the selected model, the relevant parameters are estimated, and the specific expression of the model is finally obtained. Using the model trained through the above steps, input historical carbon allowance price data to generate a predicted value for the future carbon allowance price.
[0009] The construction of the electricity price prediction model further includes: The factors that are associated with price changes are selected, including: historical electricity prices, load demand, and weather conditions; The above influencing factors were normalized:
[0010] In the formula These are the values after normalization. These are the original eigenvalues; , Let s be the minimum and maximum values in dataset s; Historical data is categorized into test sets. and training set To construct an SVR model, the basis function RBF is selected as the kernel function:
[0011] In the formula As a hyperparameter, a penalty coefficient C is set to control the SVR model's tolerance to errors, utilizing an insensitivity coefficient. This indicates the acceptable range of error between the predicted value and the actual value. The model is trained with the goal of finding the optimal hyperplane, and the training data is... The optimization objective is to minimize the fitting error within the specified range.
[0012]
[0013] In the formula For hyperplane weights; For bias; These are slack variables; Features are mapped to a high-dimensional space through a kernel function; The number of training samples; Using cross-validation, we iterate through all combinations of hyperparameters and select the parameters that optimize the model's performance on the validation set, using the root mean square error (RMSE) as the metric.
[0014] In the formula , For actual electricity prices and projected electricity prices; Collect feature data at the prediction time, process it according to the normalization method in the training phase, input the processed features into the trained SVR model to obtain the normalized predicted electricity price, and then restore the real electricity price scale through inverse normalization, finally outputting the electricity price prediction result.
[0015] The trading decision model for the medium- and long-term trading phase aims to maximize overall returns, taking into account both electricity revenue and carbon trading costs, and determines the monthly carbon quota trading volume for power generators. Its objective function is:
[0016] In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market transactions during the medium- and long-term trading phases. This refers to the monthly power generation under medium- to long-term contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m; Among them, the estimated carbon emissions from thermal power units for:
[0017] In the formula — This represents the thermal power output during period t in month m.
[0018] The upper-level construction of the power generation-carbon trading decision model in the spot trading stage further includes: The decision-making process for power generators in the spot market aims to maximize profits in both the electricity and carbon markets, with an optimization cycle of 30 days under the premise of medium- and long-term contract decomposition; the objective function is:
[0019] In the formula For profits during the spot trading phase; The electricity trading price for time period t; The amount of electricity generated by the power generator during time period t; For generator cost function; Let be the carbon price during time period t; , This represents the amount of carbon allowances sold and bought during period t. The upper-level transaction decision-making process also considers the following constraints: ①Monthly contract breakdown constraints:
[0020] for The amount of electricity generated by the power generator during the specified time period; The total contracted electricity volume for the power generator in the current month; In order to be in Minimum allowable power generation for time-of-use power generators; In order to be in The maximum permissible power generation capacity of power generators during specific time periods; ② Carbon quota settlement constraints: According to the carbon quota trading system, the annual carbon quota trading volume of a power generator shall not exceed the initial quota and the net carbon emissions from carbon quota trading.
[0021] For the first Month, First Actual carbon emissions for the period; This refers to the total amount of free initial carbon allowances obtained by power generators at the beginning of the year. For the first Month, First The total amount of carbon allowances purchased during the specified period; For the first Month, First The total amount of carbon allowances sold during a given period; ③ Price constraints imposed by power generators:
[0022]
[0023] In the formula For power generators, the segmented bidding prices in the electricity spot market are represented by k, where k is the segment number. , These are the lower and upper limits of the price for the k-th segment, respectively. ④ Unit output constraints:
[0024] In the formula For thermal power units in Actual output during the time period; The minimum technical output of the thermal power unit; This is the maximum output of the thermal power unit; ⑤ Dynamic constraints on energy storage:
[0025] In the formula Let be the remaining capacity of the energy storage device at time d; , The charging and discharging efficiency of energy storage devices; Minimum remaining capacity; This represents the maximum remaining capacity.
[0026] The lower-level construction of the electricity-carbon joint market clearing model further includes: In the lower-level spot trading stage, power generators participate in the day-ahead market and secondary carbon market clearing, with maximizing social welfare as the optimization objective. The objective function is:
[0027] In the formula Let i be the electricity consumption utility function for user i; The power generation cost for power generator i; Lower-level clearing considers the constraints during the clearing process: ① Power balance constraints: In the spot trading phase, power generators use segmented pricing, where the power generator's pricing satisfies the following:
[0028] In the formula The actual contribution of power generators during period d; For the user's day-ahead load demand; , The charging and discharging power of the energy storage device at time d; ② Renewable energy output restrictions:
[0029] In the formula , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively.
[0030] Solving the mixed-integer linear programming model further includes: Constructing the Lagrangian function for the lower-level clearing model and differentiating it yields the KKT conditions:
[0031] For the user's utility function; For the cost function of the generator; For the user's day-ahead load demand; For time period d, the first j The output of traditional power producers (such as thermal power plants); The actual contribution of power generators during period d; , The charging and discharging power of the energy storage device at time d; , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively. , These are the maximum discharge power limit and the maximum charging power limit for energy storage devices, respectively. These are the Lagrange multipliers corresponding to the power balance constraints; , These are the Lagrange multipliers for the upper limit constraints on wind power and thermal power output, respectively. , , , These are the Lagrange multipliers for the upper and lower limits of energy storage charging power, and the upper and lower limits of discharging power, respectively. Taking the first-order partial derivatives with respect to the decision variables, we obtain the necessary conditions and complementary relaxation conditions of KKT:
[0032]
[0033]
[0034] The KKT conditions of the lower-level problem are introduced into the upper-level optimization problem as constraints of the upper-level model, thereby transforming the original problem into an equivalent single-level nonlinear programming model, and linearizing the nonlinear terms in the model. Net carbon allowance trading introduces 0-1 variables to represent the trading direction and combines the Big M method to handle inequality constraints; let... ,when The time indicated that power generators sell carbon allowances. When it is indicated that carbon allowances are being purchased, then:
[0035]
[0036] Where M is a sufficiently large preset constant; By iteratively optimizing the power generator's bidding strategy, namely the electricity bidding strategy and carbon quota trading volume, the upper-level decision variables are updated. Initially, the power generator's initial bidding strategy is given, and then the bidding is continuously adjusted according to the lower-level market clearing results, so that the power generator's profit gradually increases. In each iteration, given the lower-level market parameters, the profit maximization problem of the upper-level power generator is solved. Given the power generator's bid, solve the lower-level market clearing model with the goal of maximizing social welfare to obtain the equilibrium prices of electricity and carbon in the market and the optimal output of each unit.
[0037] This invention also discloses a power generation-to-carbon market transaction data processing system utilizing the aforementioned power generation-to-carbon market transaction data processing method, comprising: The medium- and long-term trading model construction module is used to divide the power generation and carbon market trading into medium- and long-term trading stages and spot trading stages. In the medium- and long-term trading stage, the module constructs electricity price and carbon quota price prediction models, adopts the dynamic proportional decomposition method, adjusts the daily decomposition volume based on wind and solar output prediction, and constructs a trading decision model for the medium- and long-term trading stage that takes into account price fluctuations. The spot trading model construction module is used to build a two-layer decision model in the spot trading stage. The upper layer builds the power generator electricity-carbon trading decision model in the spot trading stage, decomposes the monthly contract volume to obtain the power generator electricity market spot trading strategy and carbon market trading quota. The lower layer builds the electricity-carbon joint market clearing model to optimize the trading decisions in the spot trading stage. The model solving module is used to linearize the lower-level market clearing model and the upper-level power generator decision model through KKT conditions, solve the mixed integer linear programming model, and obtain the electricity price, carbon price and the optimal output of each unit in the electricity-carbon market. The trading decision model for the medium- and long-term trading phase aims to maximize overall returns, taking into account both electricity revenue and carbon trading costs, and determines the monthly carbon quota trading volume for power generators. Its objective function is:
[0038] In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market transactions during the medium- and long-term trading phases. This refers to the monthly power generation under medium- to long-term contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m.
[0039] Accordingly, this application also discloses a terminal, including a processor and a storage medium; The storage medium is used to store instructions; The processor is configured to operate according to the instructions to perform the steps of the aforementioned generator-carbon market transaction data processing method.
[0040] Accordingly, this application also discloses a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the aforementioned power generation-carbon market transaction data processing method.
[0041] The beneficial effects of this invention are as follows: Compared with the prior art, this invention provides a method and system for processing electricity-carbon market transaction data for power generators. Through a multi-timescale collaborative mechanism, it organically connects medium- and long-term transactions with spot transactions on a time scale. Through contract decomposition and market clearing feedback, it achieves synergistic optimization of the electricity-carbon market. A two-layer decision-making model for power generators is constructed for the spot trading stage. Market clearing is embedded into the power generator's decision-making model using KKT conditions, reflecting the impact of power generator's strategic behavior on market prices. By constructing a multi-timescale trading model framework for the electricity-carbon market, it promotes the coupling and collaboration between the medium- and long-term markets and the spot market. This provides a basis for power generators to formulate scientific trading strategies, helping them achieve effective connection between markets and improving the overall returns and scientific rigor of their decisions under the dual-market model. Attached Figure Description
[0042] Figure 1 This is a flowchart of the two-tier trading process of the power generation and carbon market spot trading stage in this invention.
[0043] Figure 2 This is a schematic diagram of the improved prediction model of the BP neural network in this invention. Detailed Implementation
[0044] To make the objectives, technical solutions, and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
[0045] The embodiments described in this application are merely some, not all, embodiments of the present invention. Based on the spirit of the present invention, other embodiments obtained by those skilled in the art without inventive effort are all within the protection scope of the present invention.
[0046] To address the shortcomings of existing technologies, this invention proposes a data processing method and system for power generators' electricity-carbon market transactions. It considers the multiple benefits for power generators and achieves coordinated decision-making in medium- and long-term and spot trading. This invention considers multiple time scales in transaction decision-making, dividing transactions into medium- and long-term trading phases and spot trading phases. In the medium- and long-term trading phase, it constructs electricity price and carbon quota price prediction models, employs a dynamic proportional decomposition method, adjusts daily decomposition quantities based on wind and solar output forecasts, and constructs a transaction decision optimization model considering price fluctuations. In the spot trading phase, it constructs a two-layer decision-making model to assist power generators in formulating optimal strategies. The upper layer is for electricity-carbon trading decisions in the spot trading phase, decomposing monthly contract volumes to obtain electricity market spot trading strategies and secondary carbon market trading quota quantities. The lower layer embeds an electricity-carbon joint market clearing mechanism, thereby optimizing transaction decisions in the spot trading phase and providing support for power generator decision-making. The aim is to improve the overall benefits for power generators and promote their participation in multi-market transactions. By embedding the market clearing model into the power generator decision-making model using KKT conditions, it solves the problem that traditional algorithms cannot directly solve for global optima.
[0047] The data processing method for power generation and carbon market transactions disclosed in this invention covers three parts: a transaction decision model for the medium- and long-term trading phase considering price fluctuations, a decision optimization method for the spot trading model, and a solution algorithm. Specifically, it includes the following steps: Step 1: Divide the power generation and carbon market transactions into medium- and long-term trading phases and spot trading phases. In the medium- and long-term trading phase, construct electricity price and carbon quota price prediction models, adopt the dynamic proportional decomposition method, adjust the daily decomposition volume based on wind and solar output predictions, and construct a trading decision model for the medium- and long-term trading phase that takes into account price fluctuations.
[0048] In the medium- to long-term trading phase, the goal of power generators' trading decisions is to maximize profits over a longer timescale. If a power generator has already drafted a medium- to long-term contract, its monthly electricity generation is already determined. However, considering that participation in secondary carbon market trading is a flexible activity for power generators, the monthly carbon allowance constraint for power generation is not set to a fixed value. The steps for constructing this trading decision model are as follows: Step 1.1: Obtain input variables and constraints. Input variables include the value of medium- and long-term electricity contracts, the predicted carbon allowance price, and the electricity price. Carbon allowance trading, combined with predicted carbon prices, restricts carbon trading activities within a reasonable allowance range, including carbon allowance holding constraints and carbon allowance compliance constraints. Electricity balance constraints aim to ensure a balance between electricity supply and demand, guaranteeing supply and demand equilibrium in power generation, consumption, and energy storage regulation.
[0049] Step 1.2: With the goal of maximizing overall benefits, while taking into account electricity revenue and carbon trading costs, determine the carbon trading volume of the power generator. At this point, both the decision volume and the implementation volume are the monthly carbon quota trading volume of the power generator.
[0050] Step 1.3: Output monthly trading decisions that include carbon trading and electricity trading, guiding power generators in their specific operations during the medium- and long-term trading phase, and realizing a scientific and reasonable trading plan based on price forecasts and constraints. According to a further embodiment, in the carbon allowance price prediction in step 1.1, the present invention selects the differential autoregressive moving average (ARIMA) model to generate the predicted value of the future carbon allowance price, as follows: Step 1.111: Collect historical data of carbon quota prices for the carbon market in the region to be predicted during a preset trading period as the basis for model training. The historical data is continuous data on the same time scale. Step 1.112: Use the ADF unit root test to determine the stationarity of the historical carbon price series. If the test result indicates that the carbon price series is non-stationary, then perform differencing and repeat the test process until it passes the stationarity test.
[0051] Step 1.113: Select a model based on the characteristics of the autocorrelation function (ACF) and partial autocorrelation function (PACF) of the stationary carbon price series: If the ACF tails while the PACF is truncated at order p, then establish an AR(p) model; if the PACF tails while the ACF is truncated at order q, then establish an MA(q) model; if both tail, then establish an ARMA(p, q) or ARIMA(p, d, q) model, where p, d, and q are the core order parameters of the ARIMA model, representing the lag order of the autoregressive term, the difference order, and the moving average term, respectively. Based on the selected model, this invention uses methods such as maximum likelihood estimation to estimate the relevant parameters, ultimately deriving the specific expression of the model: (1) In the formula It is a carbon valence sequence; For lag operators, These are the coefficients of the autoregressive term; d represents the coefficients of the moving average term; d is the difference order. With zero mean and variance The white noise sequence, and all the above parameters were obtained by the maximum likelihood estimation method.
[0052] Step 1.114: Using the model trained in the above steps, input historical carbon quota price data to generate a predicted value for the future carbon quota price.
[0053] According to a further embodiment, in the electricity price prediction in step 1.1, the present invention uses a support vector regression model (SVR) to transform the original feature space into a high-dimensional separable space using a kernel function, effectively fitting the complex functional relationship between electricity price and influencing factors. The steps are as follows: Step 1.121: Select factors closely related to price changes, including: historical electricity prices, reflecting the time continuity of prices; load demand, considering the supply and demand relationship between electricity load and electricity production; and weather conditions, such as temperature, humidity, and sunlight, which affect electricity demand.
[0054] Step 1.122: To eliminate the influence of dimensions, normalize the above influencing factors: (2) In the formula These are the values after normalization. These are the original eigenvalues; , Let be the minimum and maximum values in the dataset s.
[0055] Step 1.123: Classify the historical data according to proportions, dividing it into test sets. and training set Based on this, an SVR model is constructed, and the basis function (RBF) is selected as the kernel function: (3) In the formula This is a hyperparameter that controls the width of the kernel function, determining the model's ability to fit the data. The penalty coefficient C controls the SVR model's tolerance to error, utilizing the insensitivity coefficient... This indicates the acceptable range of error between the predicted and actual values.
[0056] Step 1.124: Train the model with the goal of finding the optimal hyperplane, and let the training data be in... The optimization objective is to minimize the fitting error within the specified range. (4) (5) In the formula For hyperplane weights; For bias; These are slack variables; The number of training samples; Features are mapped to a high-dimensional space through a kernel function.
[0057] Then, cross-validation is used to iterate through all hyperparameter combinations, using the root mean square error (RMSE) as the metric, to select the parameters that optimize the model's performance on the validation set. (6) In the formula , For actual electricity prices and predicted electricity prices.
[0058] Step 1.125: Electricity Price Forecasting. Collect feature data at the forecast time, process it according to the normalization method used in the training phase, input the processed features into the trained SVR model to obtain the normalized predicted electricity price, and then restore the true electricity price scale through inverse normalization, finally outputting the electricity price forecast result, providing a basis for power generators' medium and long-term electricity trading decisions.
[0059] Specifically, in step 1.2, the primary objective is to ensure the economic viability of the medium- to long-term trading phase, including the combined benefits of the electricity market and the carbon market. The carbon market benefits take into account the projected price of carbon allowances and the projected carbon emissions.
[0060] The objective function is: (7) In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market transactions during the medium- and long-term trading phases. This refers to the monthly power generation under medium- to long-term contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m.
[0061] Among them, the estimated carbon emissions from thermal power units for: (8) In the formula For the thermal power output during period t in month m; This refers to the amount of carbon dioxide emissions corresponding to a unit of electricity generated.
[0062] In the decision-making process for medium- and long-term electricity market transactions, the carbon market trading behavior of power generators is introduced to ensure the coordination and stability of carbon market transactions. Therefore, based on factors such as the output characteristics of each unit and the volume of carbon quota trading, the following constraints are set.
[0063] ① Unit output constraints: (9) (10) (11) In the formula For wind turbines during the period The actual contribution of the individual; For wind turbines during the period Maximum available active power output; For photovoltaic units During the period The actual contribution of the individual; For photovoltaic units Minimum technical output; For photovoltaic units Maximum technical output; For thermal power units During the period The actual contribution of the individual; For photovoltaic units Minimum technical output; For thermal power units The maximum technical output. The above formulas represent the upper and lower limits of the operating output of wind power, photovoltaic, and thermal power units, respectively, which must be satisfied to operate within the specified output range.
[0064] ②Ramp-up constraints for thermal power plants: (12) In the formula , These are the equipment output at the current moment and the previous moment, respectively; , These represent the upper and lower limits of the effort required to climb the slope.
[0065] ③ Energy storage constraints: (13) In the formula Let t be the capacity of the energy storage device at time t; The maximum charging power of the energy storage device; This represents the maximum energy release of the energy storage device. Let t be the power of the energy storage device at time t.
[0066] ④ Carbon quota trading volume constraints: (14) In the formula For the first The projected carbon allowance trading volume for the month; , These are the minimum and maximum limits for monthly quota transactions, respectively.
[0067] ⑤ Annual quota constraints: (15) In the formula This represents the unit's carbon emissions in month m. This represents the initial carbon allowance allocated according to the baseline method.
[0068] ⑥ Carbon quota holding constraints: (16) (17) In the formula For the first Total carbon allowances held at the end of the month; For the first Total carbon allowances held at the end of the month; For the first Net purchases in the carbon market each month (purchases are positive, sales are negative). For the first Projected carbon emissions from the Lunar New Year power plant; Minimum quota holding limit; This is the maximum quota holding limit.
[0069] ⑦ Carbon quota compliance constraints (18) In the formula, M represents the last month of the year.
[0070] Step 2: In the spot trading stage, a two-layer decision-making model is constructed. The upper layer constructs a power generator electricity-carbon trading decision-making model for the spot trading stage, decomposing the monthly contract volume to obtain the power generator's electricity market spot trading strategy and carbon market trading quota. The lower layer constructs a joint electricity-carbon market clearing model to optimize the trading decisions in the spot trading stage.
[0071] In the spot trading phase for power generators, based on the aforementioned medium- and long-term trading phases, the monthly contract decomposition results serve as constraints for participation in spot market trading and secondary carbon market trading. Considering the coordinated trading of power generators in the electricity and carbon markets, the model is divided into a spot trading phase, a power generator electricity-carbon trading decision-making process, and an electricity-carbon market clearing model. The trading decision-making process is as follows: Figure 1 As shown. The upper layer represents the trading decisions during the spot market trading phase for power generators. The objective is profit maximization, specifically maximizing the net revenue from both the spot electricity market and the secondary carbon market. First, the monthly contract is decomposed. Since the proposed medium-to-long-term contract in this invention is a monthly electricity contract, the contract is decomposed to a daily (30-day) basis, with the decomposed trading volume as one of the constraints. This yields the power generator's electricity market bidding strategy and carbon market trading quota during the spot market trading phase. The lower layer represents the power generator market clearing model. Market clearing aims to maximize social welfare, with constraints such as electricity balance and carbon quota trading, enabling flexible clearing of power generator entities in both the spot and secondary carbon markets.
[0072] When building the model, we first construct a medium- and long-term contract decomposition model and use a dynamic proportional decomposition method to adjust the daily decomposition amount based on wind and solar power output forecasts.
[0073] The BP neural network model maps the input signal layer by layer to the hidden and output layers through activation functions. Based on the error between the output and the actual value, it uses gradient descent to adjust the network weights and thresholds in reverse to achieve model training. However, the performance of the BP network is significantly affected by the initial weights, making it prone to getting trapped in local optima. Furthermore, inappropriate initial weights can lead to gradient saturation, affecting convergence stability and prediction accuracy. This invention utilizes a genetic algorithm with global optimization capabilities to improve the initial weights and thresholds, aiming to enhance its prediction performance. Figure 2 As shown.
[0074] The optimization steps are as follows: Step 2.1: Initialize the population weights and thresholds; Step 2.2: Calculate fitness: (19) In the formula , These are the actual value and the predicted value of the output, respectively.
[0075] Step 2.3: Selection Operation. The smaller the fitness value of an individual, the smaller the error, and the better. The probability of it being selected is set according to the following formula: (20) In the formula The probability of an individual being selected; For the corresponding number The fitness value of each individual; Population size; This is the scaling factor; For the first The ranking of individual individuals.
[0076] Step 2.4: Crossover operation, performing a crossover operation on the t-th and v-th chromosomes at position k: (twenty one) In the formula , After the crossover operation at position k , chromosome; It is a random number located in the interval [0, 1].
[0077] Step 2.5: For the t-th chromosome, the first... Perform mutation operations on each gene: (twenty two) In the formula It is a mutated gene; , These represent the upper and lower limits of the mutated gene; Here, g represents the mutation rate, and g represents the number of iterations. This represents the maximum number of evolutions. , It is a random number located in the interval [0, 1].
[0078] Step 2.6: Number of iterations ,like If no other convergence conditions are met, return to step 2.3; otherwise, stop iterating and output the optimal weight and threshold in the current population.
[0079] Wind and solar power have significant uncertainties, with output varying at different times. Therefore, the medium- and long-term contract decomposition model constructed in this invention will prioritize decomposition to the trading day with the highest wind and solar power output to ensure the consumption of renewable energy, while still ensuring the effective execution of conventional thermal power contract electricity.
[0080] First, renewable energy contracted electricity volume is allocated, with daily contracted volume distributed according to the predicted output ratio: (twenty three) In the formula This refers to the daily power generation after the decomposition of renewable energy sources. The total contracted electricity volume of renewable energy in the current month; This represents the predicted renewable energy generation for period d.
[0081] Secondly, the allocation of thermal power generation capacity will be completed, with the remaining demand filled by thermal power, while ensuring a balanced progress: (twenty four) In the formula , This refers to the daily power generation and monthly contracted power generation after thermal power plant decomposition. It is an index for the sequence number of a specific day in a month.
[0082] Finally, energy storage is used to smooth out power fluctuations from combined wind and solar power output, and charging and discharging requirements are calculated: (25) In the formula This represents the deviation value of wind and solar power output. , Decomposed to the th Daily wind power contract variables and solar power contract volume; and The first Forecasted wind power output and forecasted solar power output for the day; , The amount of charging and discharging for energy storage.
[0083] The decision-making of power generators in the upper-level spot market aims to maximize profits in the electricity and carbon markets, and optimizes the cycle by 30 days under the premise of decomposing medium- and long-term contracts.
[0084] The objective function is: (26) In the formula For profits during the spot trading phase; The electricity trading price for time period t; The amount of electricity generated by the power generator during time period t; For generator cost function; Let be the carbon price during time period t; , This represents the amount of carbon allowances sold and bought during time period t.
[0085] The upper-level transaction decision-making process also considers the following constraints: ①Monthly contract breakdown constraints: (27) In the formula for The amount of electricity generated by the power generator during the specified time period; The total contracted electricity volume for the power generator in the current month; In order to be in Minimum allowable power generation for time-of-use power generators; In order to be in The maximum allowable power generation for power generators during a given time period.
[0086] ② Carbon quota settlement constraints: According to the carbon quota trading system, the annual carbon quota trading volume of a power generator shall not exceed the initial quota and the net carbon emissions from carbon quota trading. (28) In the formula For the first Month, First Actual carbon emissions for the period; This refers to the total amount of free initial carbon allowances obtained by power generators at the beginning of the year. For the first Month, First The total amount of carbon allowances purchased during the specified period; For the first Month, First The total amount of carbon allowances sold during a given period.
[0087] ③ Price constraints imposed by power generators: (29) (30) In the formula For power generators, the segmented bidding prices in the electricity spot market are represented by k, where k is the segment number. , These are the lower and upper limits of the price quote for the k-th segment, respectively.
[0088] ④ Unit output constraints: (31) In the formula For thermal power units in Actual output during the time period; The minimum technical output of the thermal power unit; This represents the maximum output of the thermal power unit. The above formula represents the upper and lower limits of the operating output of the thermal power unit, which must operate within these limits.
[0089] ⑤ Dynamic constraints on energy storage: (32) In the formula Let be the remaining capacity of the energy storage device at time d; , The charging and discharging efficiency of energy storage devices; , The charging and discharging power of the energy storage device at time d; Minimum remaining capacity; This represents the maximum remaining capacity.
[0090] In the lower-level model, during the spot trading phase, power generators participate in the day-ahead market and the secondary carbon market clearing process. The optimization objective for this phase is to maximize social welfare. The objective function is: (33) In the formula Let i be the electricity consumption utility function for user i; The power generation cost for power generator i.
[0091] Lower-level clearing considers the constraints during the clearing process: ① Power balance constraints: In the spot trading phase, power generators use segmented pricing, where the power generator's pricing satisfies the following: (34) In the formula The actual contribution of power generators during period d; For the user's day-ahead load demand; , This represents the charging and discharging power of the energy storage device at time d.
[0092] ② Renewable energy output restrictions: (35) In the formula , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively.
[0093] Step 3: Linearize the lower-level market clearing model and the upper-level generator decision-making model using KKT conditions, solve the mixed-integer linear programming model, and obtain the market electricity price, carbon price, and optimal output of each unit.
[0094] When solving the above model, the linprog solver in MATLAB is used to obtain the global optimum and output a monthly trading strategy that satisfies the power supply and demand balance, unit operation constraints, and carbon quota constraints. In the spot trading stage, since the power generator trading decision optimization model constructed in this invention is a two-layer mixed-integer nonlinear model, it is difficult to directly solve its global optimum. To overcome the difficulty of solving the two-layer optimization problem, this invention proposes an efficient solution strategy based on KKT conditions and linearization. Specifically, KKT conditions are used to integrate the lower-level market clearing problem into the upper-level model, realizing the transformation from a two-layer model to a single-layer model; after linearization, the mixed-integer nonlinear programming model is transformed into a mixed-integer linear programming model solvable by CPLEX, thereby obtaining the exact solution.
[0095] First, the lower-level clearing model is transformed into a single-level nonlinear programming problem based on the KKT conditions. A Lagrangian function is constructed for the lower-level problem, and the KKT conditions are obtained by taking its derivative. (36) In the formula For the user's utility function; For the cost function of the generator; For the user's day-ahead load demand; For time period d, the first j The output of traditional power producers (such as thermal power plants); The actual contribution of power generators during period d; , The charging and discharging power of the energy storage device at time d; , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively. , These are the maximum discharge power limit and the maximum charging power limit for energy storage devices, respectively. These are the Lagrange multipliers corresponding to the power balance constraints; , These are the Lagrange multipliers for the upper limit constraints on wind power and thermal power output, respectively. , , , These are the Lagrange multipliers constraining the upper and lower limits of energy storage charging power, and the upper and lower limits of discharging power, respectively.
[0096] Taking the first-order partial derivatives with respect to the decision variables, we obtain the following necessary conditions and complementary relaxation conditions of KKT: (37) (38) (39) By introducing the KKT conditions of the lower-level problem into the upper-level optimization problem as constraints for the upper-level model, the original problem is transformed into an equivalent single-level nonlinear programming model. To solve this problem, the nonlinear terms in the model need to be linearized.
[0097] Net carbon allowance trading introduces 0-1 variables to represent the trading direction and uses the Big M method to handle inequality constraints. Let... ,when The time indicated that power generators sell carbon allowances. When it is indicated that carbon allowances are being purchased, then: (40) (41) Where M is a sufficiently large preset constant.
[0098] The upper-level decision variables are updated by iteratively optimizing the power generator's bidding strategy, namely the electricity bidding strategy and carbon quota trading volume. Initially, the power generator's initial bidding strategy is given, and then the bid is continuously adjusted based on the lower-level market clearing results, so that the power generator's profit gradually increases. In each iteration, given the lower-level market parameters, the profit maximization problem of the upper-level power generator is solved.
[0099] Given the power generator's bid, solve the lower-level market clearing model with the goal of maximizing social welfare to obtain the equilibrium prices of electricity and carbon in the market and the optimal output of each unit.
[0100] The beneficial effects of this invention are as follows: Compared with the prior art, this invention provides a method and system for processing electricity-carbon market transaction data for power generators. Through a multi-timescale collaborative mechanism, it organically connects medium- and long-term transactions with spot transactions on a time scale. Through contract decomposition and market clearing feedback, it achieves synergistic optimization of the electricity-carbon market. A two-layer decision-making model for power generators is constructed for the spot trading stage. Market clearing is embedded into the power generator's decision-making model using KKT conditions, reflecting the impact of power generator's strategic behavior on market prices. By constructing a multi-timescale trading model framework for the electricity-carbon market, it promotes the coupling and collaboration between the medium- and long-term markets and the spot market. This provides a basis for power generators to formulate scientific trading strategies, helping them achieve effective connection between markets and improving the overall returns and scientific rigor of their decisions under the dual-market model.
[0101] This invention can be a system, method, and / or computer program product. This invention also discloses a power generation-to-carbon market transaction data processing system based on the aforementioned power generation-to-carbon market transaction data processing method, comprising: The medium- and long-term trading model construction module is used to divide the power generation and carbon market trading into medium- and long-term trading stages and spot trading stages. In the medium- and long-term trading stage, the module constructs electricity price and carbon quota price prediction models, adopts the dynamic proportional decomposition method, adjusts the daily decomposition volume based on wind and solar output prediction, and constructs a trading decision model for the medium- and long-term trading stage that takes into account price fluctuations. The spot trading model construction module is used to build a two-layer decision model in the spot trading stage. The upper layer builds the power generator electricity-carbon trading decision model in the spot trading stage, decomposes the monthly contract volume to obtain the power generator electricity market spot trading strategy and carbon market trading quota. The lower layer builds the electricity-carbon joint market clearing model to optimize the trading decisions in the spot trading stage. The model solving module is used to linearize the lower-level market clearing model and the upper-level power generator decision model using KKT conditions, solve the mixed integer linear programming model, and obtain the electricity price, carbon price, and optimal output of each unit in the electricity-carbon market.
[0102] Based on the spirit of this invention, those skilled in the art will readily conceive of a computer program product that can be obtained based on the aforementioned power generation-electricity-carbon market transaction data processing method. The computer program product may include a computer-readable storage medium on which computer-readable program instructions are loaded to cause a processor to implement various aspects of this disclosure. That is, this application also includes a terminal comprising a processor and a storage medium; the storage medium is used to store instructions; the processor is used to operate according to the instructions to execute the steps according to the aforementioned power generation-electricity-carbon market transaction data processing method.
[0103] Computer-readable storage media can be tangible devices capable of holding and storing instructions for use by an instruction execution device. Computer-readable storage media can be, for example, but not limited to, electrical storage devices, magnetic storage devices, optical storage devices, electromagnetic storage devices, semiconductor storage devices, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of computer-readable storage media include: portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disc read-only memory (CD-ROM), digital multifunction disc (DVD), memory sticks, floppy disks, mechanical encoding devices, such as punch cards or recessed protrusions storing instructions thereon, and any suitable combination of the foregoing. The computer-readable storage media used herein are not to be construed as transient signals themselves, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses through fiber optic cables), or electrical signals transmitted through wires.
[0104] The computer-readable program instructions described herein can be downloaded from computer-readable storage media to various computing / processing devices, or downloaded via a network, such as the Internet, local area network, wide area network, and / or wireless network, to an external computer or external storage device. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to the computer-readable storage media in the respective computing / processing device.
[0105] Computer program instructions used to perform the operations of this disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, status setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages such as Smalltalk, C++, etc., and conventional procedural programming languages such as the "C" language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry, such as programmable logic circuitry, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs), is personalized by utilizing the status information of the computer-readable program instructions to implement various aspects of this disclosure.
[0106] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the protection scope of the claims of the present invention.
Claims
1. A method for processing data from power generator-carbon market transactions, characterized in that, Includes the following steps: Step 1: Divide the power generation and carbon market transactions into medium- and long-term trading phases and spot trading phases. In the medium- and long-term trading phase, construct electricity price and carbon quota price prediction models, adopt the dynamic proportional decomposition method, adjust the daily decomposition volume based on wind and solar output prediction, and construct a trading decision model for the medium- and long-term trading phase that takes into account price fluctuations. Step 2: In the spot trading stage, a two-layer decision-making model is constructed. The upper layer constructs a power generator electricity-carbon trading decision-making model for the spot trading stage, decomposes the monthly contract volume to obtain the power generator's electricity market spot trading strategy and carbon market trading quota. The lower layer constructs an electricity-carbon joint market clearing model to optimize the trading decisions in the spot trading stage. Step 3: Linearize the lower-level market clearing model and the upper-level power generator decision-making model using KKT conditions, solve the mixed integer linear programming model, and obtain the electricity price, carbon price, and optimal output of each unit in the electricity-carbon market. The trading decision model for the medium- and long-term trading phase aims to maximize overall returns, taking into account both electricity revenue and carbon trading costs, and determines the monthly carbon quota trading volume for power generators. Its objective function is: In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market trading during the medium- and long-term trading phases. This refers to the power generation under medium- to long-term monthly contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m.
2. The data processing method for power generator-carbon market transactions according to claim 1, characterized in that, The construction of the carbon quota price prediction model further includes: Collect historical data on carbon allowance prices for a preset trading period in the carbon market of the region to be predicted. The historical data is continuous data at the same time scale. The ADF unit root test is used to determine the stationarity of the historical carbon price series. If the test result shows that the carbon price series is non-stationary, it is differencing and the test process is repeated until it passes the stationarity test. The model is selected based on the characteristics of the autocorrelation function (ACF) and partial autocorrelation function (PACF) of the stationary carbon price series. If the ACF tails while the PACF is truncated at order p, an AR(p) model is established. If the PACF tails while the ACF is truncated at order q, an MA(q) model is established. If both tail, an ARMA(p, q) or ARIMA(p, d, q) model is established. p, d, and q represent the lag order of the autoregressive term, the difference order, and the moving average term, respectively. Based on the selected model, the relevant parameters are estimated, and the specific expression of the model is finally obtained. Using the model trained through the above steps, input historical carbon allowance price data to generate a predicted value for the future carbon allowance price.
3. The data processing method for power generator-carbon market transactions according to claim 2, characterized in that, The construction of the electricity price prediction model further includes: The factors that are associated with price changes are selected, including: historical electricity prices, load demand, and weather conditions; The above influencing factors were normalized: In the formula These are the values after normalization. These are the original eigenvalues; , Let s be the minimum and maximum values in dataset s; Historical data is classified into test sets. and training set To construct an SVR model, the basis function RBF is selected as the kernel function: In the formula As a hyperparameter, a penalty coefficient C is set to control the SVR model's tolerance to errors, utilizing an insensitivity coefficient. This indicates the acceptable range of error between the predicted value and the actual value. The model is trained with the goal of finding the optimal hyperplane, and the training data is... The optimization objective is to minimize the fitting error within the specified range. In the formula For hyperplane weights; For bias; These are slack variables; Features are mapped to a high-dimensional space through a kernel function; The number of training samples; Using cross-validation, we iterate through all combinations of hyperparameters and select the parameters that optimize the model's performance on the validation set, using the root mean square error (RMSE) as the metric. In the formula , For actual electricity prices and projected electricity prices; Collect feature data at the prediction time, process it according to the normalization method in the training phase, input the processed features into the trained SVR model to obtain the normalized predicted electricity price, and then restore the real electricity price scale through inverse normalization, finally outputting the electricity price prediction result.
4. The data processing method for power generator-carbon market transactions according to claim 3, characterized in that, Among them, the estimated carbon emissions from thermal power units for: In the formula — This represents the thermal power output during period t in month m.
5. The data processing method for power generator-carbon market transactions according to claim 4, characterized in that, The upper-level construction of the power generation-carbon trading decision model in the spot trading stage further includes: The decision-making process for power generators in the spot market aims to maximize profits in both the electricity and carbon markets, with an optimization cycle of 30 days under the premise of medium- and long-term contract decomposition; the objective function is: In the formula For profits during the spot trading phase; The electricity trading price for time period t; The amount of electricity generated by the power generator during time period t; For generator cost function; Let be the carbon price during time period t; , This represents the amount of carbon allowances sold and bought during period t. The upper-level transaction decision-making process also considers the following constraints: ①Monthly contract breakdown constraints: for The amount of electricity generated by the power generator during the specified time period; The total contracted electricity volume for the power generator in the current month; In order to be in Minimum allowable power generation for time-limited power generators; In order to be in The maximum permissible power generation capacity of power generators during specific time periods; ② Carbon quota settlement constraints: According to the carbon quota trading system, the annual carbon quota trading volume of a power generator shall not exceed the initial quota and the net carbon emissions from carbon quota trading. For the first Month, First Actual carbon emissions for the period; This refers to the total amount of free initial carbon allowances obtained by power generators at the beginning of the year. For the first Month, First The total amount of carbon allowances purchased during the specified period; For the first Month, First The total amount of carbon allowances sold during a given period; ③ Price constraints imposed by power generators: In the formula For power generators, the segmented bidding prices in the electricity spot market are represented by k, where k is the segment number. , These are the lower and upper limits of the price quote for the k-th segment, respectively. ④ Unit output constraints: In the formula For thermal power units in Actual output during the time period; The minimum technical output of the thermal power unit; This is the maximum output of the thermal power unit; ⑤ Dynamic constraints on energy storage: In the formula Let be the remaining capacity of the energy storage device at time d; , The charging and discharging efficiency of energy storage devices; Minimum remaining capacity; This represents the maximum remaining capacity.
6. The data processing method for power generator-carbon market transactions according to claim 5, characterized in that, The lower-level construction of the electricity-carbon joint market clearing model further includes: In the lower-level spot trading stage, power generators participate in the day-ahead market and secondary carbon market clearing, with maximizing social welfare as the optimization objective. The objective function is: In the formula Let i be the electricity consumption utility function for user i; The power generation cost for power generator i; Lower-level clearing considers the constraints during the clearing process: ① Power balance constraints: In the spot trading phase, power generators use segmented pricing, where the power generator's pricing satisfies the following: In the formula The actual contribution of power generators during period d; For the user's day-ahead load demand; , The charging and discharging power of the energy storage device at time d; ②Renewable energy output restrictions: In the formula , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively.
7. The data processing method for power generator-carbon market transactions according to claim 6, characterized in that, Solving the mixed-integer linear programming model further includes: Constructing the Lagrangian function for the lower-level clearing model and differentiating it yields the KKT conditions: For the user's utility function; For the cost function of the generator; For the user's day-ahead load demand; For time period d, the first j The output of traditional power producers (such as thermal power plants); The actual contribution of power generators during period d; , The charging and discharging power of the energy storage device at time d; , The actual cleared electricity volume of wind and solar power generators during period d; , These represent the available power for wind power generators and solar power generators during time period d, respectively. , These are the maximum discharge power limit and the maximum charging power limit for energy storage devices, respectively. These are the Lagrange multipliers corresponding to the power balance constraints; , These are the Lagrange multipliers for the upper limit constraints on wind power and thermal power output, respectively. , , , These are the Lagrange multipliers for the upper and lower limits of energy storage charging power, and the upper and lower limits of discharging power, respectively. Taking the first-order partial derivatives with respect to the decision variables, we obtain the necessary conditions and complementary relaxation conditions of KKT: The KKT conditions of the lower-level problem are introduced into the upper-level optimization problem as constraints of the upper-level model, thereby transforming the original problem into an equivalent single-level nonlinear programming model, and linearizing the nonlinear terms in the model. Net carbon allowance trading introduces 0-1 variables to represent the trading direction and combines the Big M method to handle inequality constraints; let... ,when The time indicated that power generators sell carbon allowances. When it is indicated that carbon allowances are being purchased, then: Where M is a sufficiently large preset constant; By iteratively optimizing the power generator's bidding strategy, namely the electricity bidding strategy and carbon quota trading volume, the upper-level decision variables are updated. Initially, the power generator's initial bidding strategy is given, and then the bidding is continuously adjusted according to the lower-level market clearing results, so that the power generator's profit gradually increases. In each iteration, given the lower-level market parameters, the profit maximization problem of the upper-level power generator is solved. Given the power generator's bid, solve the lower-level market clearing model with the goal of maximizing social welfare to obtain the equilibrium prices of electricity and carbon in the market and the optimal output of each unit.
8. A data processing system for power generator-carbon market transactions, characterized in that, include: The medium- and long-term trading model construction module is used to divide the power generation and carbon market trading into medium- and long-term trading stages and spot trading stages. In the medium- and long-term trading stage, the module constructs electricity price and carbon quota price prediction models, adopts the dynamic proportional decomposition method, adjusts the daily decomposition volume based on wind and solar output prediction, and constructs a trading decision model for the medium- and long-term trading stage that takes into account price fluctuations. The spot trading model construction module is used to build a two-layer decision model in the spot trading stage. The upper layer builds the power generator electricity-carbon trading decision model in the spot trading stage, decomposes the monthly contract volume to obtain the power generator electricity market spot trading strategy and carbon market trading quota. The lower layer builds the electricity-carbon joint market clearing model to optimize the trading decisions in the spot trading stage. The model solving module is used to linearize the lower-level market clearing model and the upper-level power generator decision model through KKT conditions, solve the mixed integer linear programming model, and obtain the electricity price, carbon price and the optimal output of each unit in the electricity-carbon market. The trading decision model for the medium- and long-term trading phase aims to maximize overall returns, taking into account both electricity revenue and carbon trading costs, and determines the monthly carbon quota trading volume for power generators. Its objective function is: In the formula For medium- to long-term trading profits; , This includes revenue from the electricity market and carbon market trading during the medium- and long-term trading phases. This refers to the power generation under medium- to long-term monthly contracts. The projected electricity price for month m; The projected carbon market price for month m; The estimated carbon emissions of thermal power units in month m; The estimated carbon quota for thermal power units in month m.
9. A terminal, comprising a processor and a storage medium; characterized in that: The storage medium is used to store instructions; The processor is configured to operate according to the instructions to perform the steps of the power generator-carbon market transaction data processing method according to any one of claims 1-7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the power generation-carbon market transaction data processing method according to any one of claims 1-7.