Power grid safety assessment method and system based on gas-electricity market price coupling mechanism

By constructing a gas-electricity price chain conduction model and improving the optimal power flow model, and combining it with the differential-algebraic equation model to conduct grid security assessment, the problems of unclear price coupling mechanism and fragmented security assessment were solved, and high-accuracy grid security early warning and dynamic price limit adjustment were achieved.

CN120634249APending Publication Date: 2025-09-12STATE GRID JIANGSU ELECTRIC POWER CO LTD RESEARCH INSTITUTE +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510737709.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-04
Publication Date
2025-09-12

AI Technical Summary

Technical Problem

The price coupling mechanism in existing technologies is unclear, there is a lack of quantitative analysis of the price transmission path between the gas and electricity markets, safety impact assessments are insufficient, the indirect impact of market price fluctuations on unit scheduling behavior is ignored, and policy coordination design does not consider the potential risks of gas-electricity price linkage to system resilience.

Method used

Construct a gas-electricity price chain conduction model, conduct static safety analysis by improving the optimal power flow model, and conduct dynamic stability analysis by combining the differential-algebraic equation model. Use the random forest algorithm for joint analysis, output the risk level, and set up a dynamic linkage price limit mechanism.

Benefits of technology

The accuracy of power grid security early warning has been improved to over 90%, accounting for the differentiated impact of price coupling, covering both static power flow security and dynamic frequency stability. The generated linkage price limit threshold can be dynamically adjusted according to seasonal characteristics, avoiding a "one-size-fits-all" policy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120634249A_ABST
    Figure CN120634249A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of power grid safety assessment, in particular to a power grid safety assessment method and system based on a gas-electricity market price coupling mechanism, and the method comprises the steps: constructing a gas-electricity price chain type conduction model, and analyzing the gas-electricity market price coupling mechanism; improving the optimal power flow model, and performing static safety analysis on the power grid by improving the optimal power flow model to obtain a static analysis result; constructing a differential-algebraic equation model of the gas-electricity combined system by combining a dynamic response mechanism of the gas-electricity price chain type conduction model, and performing dynamic stability analysis on the power grid to obtain a dynamic analysis result; and performing conjoint analysis on the static analysis result and the dynamic analysis result through a random forest algorithm, and outputting a risk level. According to the invention, the problems of unclear price coupling mechanism, fragmentization of safety assessment and insufficient policy collaboration are effectively solved, the accuracy of power grid safety early warning can be improved, and decision support is provided for collaborative operation of multi-energy markets.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power grid security assessment, and in particular to a power grid security assessment method and system based on a gas-electricity market price coupling mechanism. Background Art

[0002] With the advancement of energy market-oriented reforms, the coupling between the electricity market and the natural gas market is becoming increasingly close. As an important regulating resource in the power system, the price fluctuations of gas-fired power generation directly affect the clearing results of the electricity market and the safe operation of the power grid.

[0003] Currently, research on gas-electricity price coupling primarily focuses on gas-electricity price transmission analysis methods based on the vector autoregression (VAR) model, which fails to consider the strategic behavior of market participants. Multi-energy market coupling analysis methods based on the dynamic stochastic general equilibrium (DSGE) model, however, are complex and difficult to apply in real time. Domestic scholars have used Granger causality tests to verify the unidirectional impact of natural gas prices on electricity prices, but have not quantified the magnitude of transmission. Elasticity coefficient analysis has been introduced in pilot projects in East China, but this has not been integrated with dynamic security assessments. Regarding power grid security impact assessment, traditional optimal power flow (OPF) models often assess static system security based on fixed cost parameters, ignoring the impact of market price fluctuations on unit output. Dynamic stability analysis of the system often focuses on physical equipment failures, with limited research examining the indirect frequency instability caused by market price fluctuations through dispatching behavior. Therefore, power grid security assessment methods and systems based on the mechanism of gas-electricity market price coupling have become a current research focus. Summary of the Invention

[0004] The present invention provides a power grid security assessment method and system based on the gas-electricity market price coupling mechanism, which can effectively solve the problems existing in the background technology, such as unclear price coupling mechanism and lack of quantitative analysis of price transmission path between gas and electricity markets; insufficient safety impact assessment, and the existing power grid security analysis often ignores the indirect impact of market price fluctuations on unit scheduling behavior; lack of policy coordination, and the design of market rules does not consider the potential risks of gas-electricity price linkage to system resilience.

[0005] In order to achieve the above object, the technical solution adopted by the present invention is:

[0006] A power grid security assessment method based on a gas-electricity market price coupling mechanism, the method comprising:

[0007] Construct a gas-electricity price chain transmission model, analyze the price coupling mechanism of the gas-electricity market, and obtain price coupling analysis results;

[0008] Based on the price coupling analysis results, the optimal power flow model is improved, and the static security analysis of the power grid is carried out by improving the optimal power flow model to obtain the static analysis results;

[0009] Combining the dynamic response mechanism of the gas-electricity price chain conduction model, a differential-algebraic equation model of the gas-electricity combined system is constructed to conduct a dynamic stability analysis of the power grid and obtain dynamic analysis results;

[0010] The static analysis results and the dynamic analysis results are jointly analyzed using a random forest algorithm to output a risk level.

[0011] Furthermore, the gas-electricity price chain conduction model is constructed to analyze the gas-electricity market price coupling mechanism, and the price coupling analysis results obtained include:

[0012] Construct a gas-electricity price chain transmission model and establish the dynamic relationship between natural gas prices and electricity prices. The specific formula is:

[0013]

[0014] Among them, C gas is the marginal cost of gas-fired units (yuan / MWh), is the spot price of natural gas (yuan / cubic meter), Q gas is the gas purchase volume of the gas unit (cubic meters / hour), α is the price sensitivity coefficient, β is the gas purchase volume sensitivity coefficient, and ε is the random disturbance term.

[0015] The Granger causality test with lag order 3 is used to verify the unidirectional causal relationship between gas price and electricity price.

[0016] By wavelet coherence analysis, the time-frequency domain coherence coefficient R is calculated. 2 (f, t), identifying the coupling strength at different time scales.

[0017] Furthermore, to identify the coupling strength, the price elasticity coefficient is calculated using a partial least squares regression model, with the control variables including renewable energy output, load demand, and temperature.

[0018] Furthermore, the improved optimal power flow model introduces a gas price sensitive term into the objective function of the optimal power flow model, and the constraint conditions include the upper and lower limits of the gas unit output.

[0019] Furthermore, the improved OPF model is used to perform static security analysis on the power grid, and the static safety indicators line load rate and node voltage deviation are calculated.

[0020] Furthermore, the dynamic stability analysis of the power grid is performed, and the Jacobian matrix eigenvalue of the differential-algebraic equation model is solved by the QR algorithm. If the maximum value of the real part σ max >-0.1, it is judged as small interference instability and triggers the instability warning.

[0021] Furthermore, the output risk level classification is based on the Gini impurity minimization principle.

[0022] Furthermore, it also includes setting up a dynamic linkage price limit mechanism, the specific formula is:

[0023] η max =η base +γ·(L avg -L base );

[0024] Among them, η max is the dynamic price limit threshold, η base is the basic threshold, L avg is the average load growth rate of the month (%), L base is the basic load growth rate, γ is the adjustment coefficient, and the default value is 0.2.

[0025] A power grid security assessment system based on a gas-electricity market price coupling mechanism, the system comprising:

[0026] The coupling mechanism analysis module builds a gas-electricity price chain conduction model, analyzes the gas-electricity market price coupling mechanism, and obtains price coupling analysis results;

[0027] The static security analysis module improves the optimal power flow model based on the price coupling analysis results, performs static security analysis on the power grid by improving the OPF model, and obtains the static analysis results;

[0028] The dynamic stability analysis module combines the dynamic response mechanism of the gas-electricity price chain conduction model to construct a differential-algebraic equation model of the gas-electricity combined system, conducts dynamic stability analysis on the power grid, and obtains dynamic analysis results;

[0029] The risk level output module jointly analyzes the static analysis results and the dynamic analysis results through a random forest algorithm and outputs a risk level.

[0030] Furthermore, the coupling mechanism analysis module includes:

[0031] The transmission model construction unit builds a gas-electricity price chain transmission model and establishes the dynamic relationship between natural gas prices and electricity prices;

[0032] Granger causality test unit, which uses Granger causality test to verify the unidirectional causal relationship between gas price and electricity price;

[0033] Wavelet coherence analysis unit calculates the time-frequency domain coherence coefficient R through wavelet coherence analysis 2 (f, t), identifying the coupling strength at different time scales.

[0034] A computer-readable storage medium storing a program for executing the method according to any one of claims 1 to 8.

[0035] The technical solution of the present invention can achieve the following technical effects:

[0036] This method effectively addresses the issues of unclear price coupling mechanisms, fragmented security assessments, and insufficient policy coordination, improving the accuracy of grid security warnings to over 90% and providing decision support for the coordinated operation of multiple energy markets. This method uses wavelet coherence analysis to identify the differentiated impacts of short-term speculation and long-term supply and demand on price coupling, increasing explanatory power by 40%. The explanation of price coupling mechanisms is more precise, covering both static power flow security and dynamic frequency stability. The warning accuracy can reach over 90%, providing a more comprehensive assessment of grid security. The generated linkage price limit threshold can be dynamically adjusted based on seasonal characteristics, avoiding a "one-size-fits-all" policy.

[0037] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments recorded in the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0039] Figure 1 This is a flowchart of a power grid security assessment method based on the gas-electricity market price coupling mechanism;

[0040] Figure 2 This is a schematic diagram of the gas-electricity price transmission path;

[0041] Figure 3 Schematic diagram of the structure of the power grid security assessment system based on the gas-electricity market price coupling mechanism. DETAILED DESCRIPTION

[0042] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.

[0043] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this invention pertains. The terms used in this specification are for the purpose of describing specific embodiments only and are not intended to limit the invention. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.

[0044] Example 1:

[0045] like Figure 1 As shown in FIG, a grid security assessment method based on the gas-electricity market price coupling mechanism includes:

[0046] S1: Construct a gas-electricity price chain transmission model, analyze the price coupling mechanism of the gas-electricity market, and obtain price coupling analysis results;

[0047] This example quantitatively analyzes the price transmission path between the gas and electricity markets. Figure 2 As shown in the figure, a chain transmission model of natural gas price → marginal cost of gas-fired units → electricity clearing price is constructed, which clarifies the price linkage mechanism between markets and reveals the transmission path of market fluctuations to the physical system. This chain transmission model is the theoretical basis for the subsequent quantification of the impact of gas price fluctuations on power grid security.

[0048] S2: Based on the price coupling analysis results, the optimal power flow model is improved, and a static security analysis of the power grid is performed by improving the optimal power flow model to obtain the static analysis results;

[0049] S3: Combined with the dynamic response mechanism of the gas-electricity price chain conduction model, a differential-algebraic equation model of the gas-electricity combined system is constructed to conduct dynamic stability analysis of the power grid and obtain dynamic analysis results;

[0050] Specifically, in order to solve the problem of fragmented power grid security assessment, this embodiment improves the OPF and DAE joint framework through the analysis of the gas-electricity market price coupling mechanism, and uses the improved optimal power flow model (OPF) as the core tool for static security analysis of the power grid, while the differential-algebraic equation model (DAE) is the core tool for dynamic stability analysis of the power grid; the traditional optimal power flow model (OPF) assumes that the unit cost function is constant, but the marginal cost of the gas unit is directly dominated by the gas price. In order to avoid the model from seriously underestimating the risk of gas units exiting the market when gas prices soar, this step improves the optimal power flow model based on market signals, and converts abstract market fluctuations into quantifiable power grid security parameters; in the differential-algebraic equation model (DAE), algebraic equations describe the steady-state operation constraints of the power grid, and differential equations describe dynamic processes. The gas-electricity price transmission mechanism is combined with the differential-algebraic equation model to solve the problem of hidden instability of the power grid caused by market price fluctuations.

[0051] When constructing the differential-algebraic equation model, the output adjustment process of the gas turbine can be described as a first-order inertia link. Combined with the market price feedback mechanism, the specific formula is:

[0052]

[0053] Wherein, τ is the dynamic response time constant (seconds), the typical value is 30 to 120 seconds. is the output change rate of the gas turbine unit (MW / s), T gas is the real-time output of the gas unit (MW), K is the price sensitivity coefficient (MW / (yuan / MWh)), which reflects the response intensity of the unit to the real-time electricity price, P elec is the real-time clearing price of the electricity market (yuan / MWh), C gas (P gas ) is the marginal cost function of the gas-fired unit (yuan / MWh).

[0054] S4: Combine the static analysis results and dynamic analysis results through the random forest algorithm to output the risk level.

[0055] In order to further realize the real-time mapping between market price fluctuations and power grid security status, when generating risk level warning strategy through random forest algorithm, not only the static safety index obtained by static safety analysis and the dynamic stability index obtained by dynamic stability analysis are used as inputs of random forest algorithm, but also the gas price elasticity coefficient η, load growth rate ΔL, and spinning reserve capacity ratio R are used as inputs of random forest algorithm. reserve Market parameters such as ΔL and ΔS are also included in the input of the random forest algorithm. The feature importance of the random forest risk prediction model is: load growth rate ΔL > spinning reserve capacity ratio R reserve >Gas price elasticity coefficient η.

[0056] This invention effectively addresses the issues of unclear price coupling mechanisms, fragmented security assessments, and insufficient policy coordination, improving the accuracy of grid security early warnings to over 90% and providing decision support for the coordinated operation of multiple energy markets. This invention uses wavelet coherence analysis to identify the differentiated impacts of short-term speculation and long-term supply and demand on price coupling, increasing explanatory power by 40% and providing a more precise explanation of the price coupling mechanism. It also covers both static power flow security and dynamic frequency stability, achieving an early warning accuracy of over 90%, providing a more comprehensive assessment of grid security, and dynamically adjusting the resulting linkage price limit thresholds based on seasonal characteristics to avoid a "one-size-fits-all" policy.

[0057] Based on the above embodiment, a gas-electricity price chain transmission model is constructed to analyze the price coupling mechanism of the gas-electricity market. The price coupling analysis results include:

[0058] S11: Construct a gas-electricity price chain transmission model to establish the dynamic relationship between natural gas prices and electricity prices. The specific formula is:

[0059]

[0060] Among them, C gas is the marginal cost of gas-fired units (yuan / MWh), is the spot price of natural gas (yuan / cubic meter), Q gas is the gas purchase volume of the gas unit (cubic meters / hour), α is the price sensitivity coefficient, β is the gas purchase volume sensitivity coefficient, and ε is the random disturbance term.

[0061] S12: Granger causality test with lag order 3 is used to verify the unidirectional causal relationship between gas price and electricity price;

[0062] The electricity spot market generally adopts multi-stage transactions. The Granger causality test with a lag of 3 can cover the entire transaction chain and capture the transmission process of gas prices from decision-making to clearing. In this embodiment, the lag order k=3 is used to determine the natural gas spot price P through the F test. gas Is it significantly ahead of the real-time clearing price P in the electricity market? elec (significance level α = 0.05), the Granger causality test (p < 0.05) verified the unidirectional impact of gas prices on electricity prices, ensuring the scientific nature of subsequent analysis. Without this verification, the subsequent model may lead to misjudgment due to false correlation.

[0063] S13: Calculate the time-frequency domain coherence coefficient R through wavelet coherence analysis 2 (f, t), identifying the coupling strength at different time scales.

[0064] Specifically, this step uses the Morlet wavelet basis function to calculate the time-frequency domain coherence coefficient R 2 (f, t), identify the price elasticity coefficient (η) at different time scales (such as intraday and weekly). Wavelet coherence analysis and price elasticity coefficient quantify the price linkage intensity at different time scales, providing data support for the time constant and risk warning threshold in dynamic security analysis.

[0065] The formula for price elasticity is:

[0066]

[0067] Where η is the gas-electricity price elasticity coefficient, which indicates the response intensity of electricity price to gas price fluctuations, ΔP elec is the change in electricity price (yuan / MWh), ΔP gas is the change in gas price (yuan / cubic meter).

[0068] Furthermore, to identify the coupling strength, the price elasticity coefficient is calculated using a partial least squares regression model, with the control variables including renewable energy output, load demand, and temperature.

[0069] Specifically, when calculating the price elasticity coefficient using the partial least squares regression model, control variables are used to isolate the interference of other factors on the relationship between the dependent variable electricity price and the independent variable gas price, ensuring that the estimated price elasticity coefficient only reflects the net causal effect of gas price on electricity price, and avoiding other variables affecting gas price and electricity price at the same time, leading to incorrect estimation of transmission intensity and false regression.

[0070] As a preferred embodiment of this embodiment, the optimal power flow model is improved, a gas price sensitive term is introduced into the objective function of the optimal power flow model, and the constraint conditions include the upper and lower limits of the gas unit output.

[0071] A gas price-sensitive term is introduced into the improved OPF model, which converts gas price fluctuations into changes in the cost of gas-fired units, directly affecting the market clearing results. The constraints include the upper and lower limits of the gas-fired unit output, which depend on the price elasticity coefficient η in the first step. The upper and lower limits of the gas-fired unit output are dynamically adjusted with the gas price, avoiding the limitations of fixed parameters in traditional OPF.

[0072] Furthermore, the static security analysis of the power grid is carried out by improving the OPF model, and the static safety indicators line load rate and node voltage deviation are calculated.

[0073] This embodiment calculates the line load rate and node voltage deviation after gas price fluctuations by improving the OPF model, and converts gas price fluctuations into quantitative risks of line load rate and node voltage deviation.

[0074] Line load factor:

[0075] Node voltage deviation: ΔVi=|V i -V nom |.

[0076] On the basis of the above embodiment, the dynamic stability analysis of the power grid is performed, and the Jacobian matrix eigenvalue of the differential-algebraic equation model is solved by the QR algorithm. If the maximum value of the real part σ max >-0.1, it is judged as small interference instability and triggers the instability warning.

[0077] As a preferred embodiment of this invention, the output risk level classification is based on the Gini impurity minimization principle.

[0078] The Gini impurity minimization principle offers three core advantages for grid risk classification: computational efficiency, robustness against noise, and prioritization of physical safety. It is particularly well-suited for the high-dimensional, real-time data characteristics of gas-electricity coupling scenarios. This step constructs a decision tree based on Gini impurity minimization, objectively classifying risk levels. The Gini impurity minimization principle prioritizes dynamic instability as the primary splitting node, ensuring physical safety. Furthermore, the Gini criterion's computational efficiency allows for real-time early warning, resulting in an accuracy improvement of 28.8% compared to manual thresholding methods.

[0079] Furthermore, it also includes setting up a dynamic linkage price limit mechanism, the specific formula is:

[0080] η max =η base +γ·(L avg -L base );

[0081] Among them, η max is the dynamic price limit threshold, η base is the basic threshold, L avg is the average load growth rate of the month (%), L base is the basic load growth rate, γ is the adjustment coefficient, and the default value is 0.2.

[0082] In this embodiment, the natural gas market is affected by factors such as geopolitics, extreme weather, and supply-demand imbalances, and prices may fluctuate dramatically. Traditional fixed price limit thresholds cannot adapt to such sudden fluctuations. For the static safety of the power grid, the withdrawal of gas-fired units leads to power flow redistribution, which may cause line overload. For the dynamic stability of the power grid, gas-fired units are fast-adjusting resources, and their withdrawal may reduce system damping and cause low-frequency oscillations. Therefore, this embodiment provides a threshold-triggered compensation mechanism. This mechanism dynamically adjusts the price limit threshold to prevent large-scale withdrawal of gas-fired units due to drastic fluctuations in gas prices, thereby avoiding static overload and dynamic instability of the power grid. For example, when the gas price rises and triggers the price limit threshold, the standby coal-fired units are automatically started to compensate for the capacity and fill the power gap.

[0083] Example 2:

[0084] like Figure 3 As shown in the figure, the power grid security assessment system based on the gas-electricity market price coupling mechanism includes:

[0085] The coupling mechanism analysis module builds a gas-electricity price chain conduction model, analyzes the gas-electricity market price coupling mechanism, and obtains price coupling analysis results;

[0086] The static security analysis module improves the optimal power flow model based on the price coupling analysis results, performs static security analysis on the power grid by improving the OPF model, and obtains the static analysis results;

[0087] The dynamic stability analysis module combines the dynamic response mechanism of the gas-electricity price chain conduction model to construct a differential-algebraic equation model of the gas-electricity combined system, conducts dynamic stability analysis on the power grid, and obtains dynamic analysis results;

[0088] The risk level output module jointly analyzes the static analysis results and dynamic analysis results through the random forest algorithm and outputs the risk level.

[0089] The above-mentioned adjustment system in the present invention can effectively implement the power grid security assessment method based on the gas-electricity market price coupling mechanism. The technical effects that can be achieved are as described in the above-mentioned embodiments and will not be repeated here.

[0090] Furthermore, the coupling mechanism analysis module includes:

[0091] The transmission model construction unit builds a gas-electricity price chain transmission model and establishes the dynamic relationship between natural gas prices and electricity prices;

[0092] Granger causality test unit, which uses Granger causality test to verify the unidirectional causal relationship between gas price and electricity price;

[0093] Wavelet coherence analysis unit calculates the time-frequency domain coherence coefficient R through wavelet coherence analysis 2 (f, t), identifying the coupling strength at different time scales.

[0094] Similarly, the above-mentioned optimization schemes for the system can also respectively achieve the corresponding optimization effects of the method in Example 1, which will not be repeated here.

[0095] A computer-readable storage medium stores a program for executing any one of the methods of claims 1 to 8, including modules for data preprocessing, model solving, and result visualization.

[0096] Although the present application has been described with reference to specific features and embodiments thereof, it is apparent that various modifications and combinations may be made thereto without departing from the spirit and scope of the present application. Accordingly, this specification and drawings are merely illustrative of the present application as defined herein and are deemed to cover any and all modifications, variations, combinations or equivalents within the scope of the present application. It is apparent that various modifications and variations of the present application may be made by those skilled in the art without departing from the scope of the present application. Thus, the present application is intended to include such modifications and variations as fall within the scope of the present application and its equivalents.

Claims

1. A grid security assessment method based on the gas-electricity market price coupling mechanism is characterized by: The method comprises: Construct a gas-electricity price chain transmission model, analyze the price coupling mechanism of the gas-electricity market, and obtain price coupling analysis results; Based on the price coupling analysis results, the optimal power flow model is improved, and the static security analysis of the power grid is carried out by improving the optimal power flow model to obtain the static analysis results; Combining the dynamic response mechanism of the gas-electricity price chain conduction model, a differential-algebraic equation model of the gas-electricity combined system is constructed to conduct a dynamic stability analysis of the power grid and obtain dynamic analysis results; The static analysis results and the dynamic analysis results are jointly analyzed using a random forest algorithm to output a risk level.

2. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 1 is characterized in that: The gas-electricity price chain conduction model is constructed to analyze the gas-electricity market price coupling mechanism, and the price coupling analysis results obtained include: Construct a gas-electricity price chain transmission model and establish the dynamic relationship between natural gas prices and electricity prices. The specific formula is: Among them, C gas is the marginal cost of gas-fired units (yuan / MWh), is the spot price of natural gas (yuan / cubic meter), Q gas is the gas purchase volume of the gas unit (cubic meters / hour), α is the price sensitivity coefficient, β is the gas purchase volume sensitivity coefficient, and ε is the random disturbance term. The Granger causality test with lag order 3 is used to verify the unidirectional causal relationship between gas price and electricity price. By wavelet coherence analysis, the time-frequency domain coherence coefficient R is calculated. 2 (f, t), identifying the coupling strength at different time scales.

3. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 2 is characterized in that: To identify the coupling strength, the price elasticity coefficient is calculated using a partial least squares regression model, with the control variables including renewable energy output, load demand, and temperature.

4. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 1 is characterized in that: The improved optimal power flow model introduces a gas price sensitive term into the objective function of the optimal power flow model, and the constraint conditions include the upper and lower limits of the gas unit output.

5. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 4 is characterized in that: The improved OPF model is used to perform static security analysis on the power grid, and static safety indicators such as line load rate and node voltage deviation are calculated.

6. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 1 is characterized in that: The dynamic stability analysis of the power grid is performed by solving the Jacobian matrix eigenvalue of the differential-algebraic equation model through the QR algorithm. If the maximum value of the real part σ max >-0.1, it is judged as small interference instability and triggers the instability warning.

7. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 1 is characterized in that: The output risk level classification is based on the Gini impurity minimization principle.

8. The power grid security assessment method based on the gas-electricity market price coupling mechanism according to claim 1 is characterized in that: It also includes setting a dynamic linkage price limit mechanism. The specific formula is: or max =the base +γ·(L avg -L base ); Among them, η max is the dynamic price limit threshold, η base is the basic threshold, L avg is the average load growth rate of the month (%), L base is the basic load growth rate, γ is the adjustment coefficient, and the default value is 0.

2.

9. A power grid security assessment system based on the gas-electricity market price coupling mechanism is characterized by: The system comprises: The coupling mechanism analysis module builds a gas-electricity price chain conduction model, analyzes the gas-electricity market price coupling mechanism, and obtains price coupling analysis results; The static security analysis module improves the optimal power flow model based on the price coupling analysis results, performs static security analysis on the power grid by improving the OPF model, and obtains the static analysis results; The dynamic stability analysis module combines the dynamic response mechanism of the gas-electricity price chain conduction model to construct a differential-algebraic equation model of the gas-electricity combined system, conducts dynamic stability analysis on the power grid, and obtains dynamic analysis results; The risk level output module jointly analyzes the static analysis results and the dynamic analysis results through a random forest algorithm and outputs a risk level.

10. The power grid security assessment system based on the gas-electricity market price coupling mechanism according to claim 9, characterized in that: The coupling mechanism analysis module includes: The transmission model construction unit builds a gas-electricity price chain transmission model and establishes the dynamic relationship between natural gas prices and electricity prices; Granger causality test unit, which uses Granger causality test to verify the unidirectional causal relationship between gas price and electricity price; Wavelet coherence analysis unit calculates the time-frequency domain coherence coefficient R through wavelet coherence analysis 2 (f, t), identifying the coupling strength at different time scales.

11. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a program for executing the method according to any one of claims 1 to 8.