Event-driven based simulation method for security and stability control strategies of power system

Since the security and stability control strategies (SSCSs) play a pivotal role in maintaining system stability, devising the strategies accurately and reliably is of great significance. Currently, SSCSs are typically formulated according to the ‘offline simulation and online matching’ approach. However, existing commercial simulation software is difficult to simulate the dynamic triggering mechanisms and intricate control logic of SSCSs. To simulate the set of SSCSs systematically and comprehensively, this paper has proposed an event-driven approach for simulations. Firstly, the SSCS is modeled as an event-driven model containing three elements: event, event listening, and event processing. Then, on the basis of the event triggering mechanism presented in this paper, the complex control logics of SSCSs, such as the prioritization of tripping generators, are implemented. Through event-driven models of SSCSs and subsequent utilization of the event-triggered mechanism, independent and dynamic responses of SSCSs can be realized, thus avoiding interference in the simulation of multiple SSCSs. Finally, the effectiveness of the proposed method is verified based on the IEEE 39-bus system.


Introduction
In the context of peak carbon dioxide emissions and carbon neutrality, there has been dramatic advancements of establishing a new power system in China [1].Through the consistent integration of numerous renewable energy sources like wind and solar energy, coupled with the extensive application of power electronics technology, the power grid has evolved into a multilayered AC-DC hybrid grid structure, exhibiting intricate transient characteristics [2], [3].Consequently, the challenges pertaining to the security and stability of the power system have gained prominence [4].
To ensure the robust operation of the power system, in-depth investigations have been conducted into the security defense technology and the associated technical specifications of the grids, leading to the continuous refinement of three tiers of security and stability defenses [5].Within this framework, the security and stability control system plays an vital role in safeguarding grid operations by effectively countering perturbations in the security and stability guidelines.In instances of failures that precipitate the risk of instability, the security and stability control system executes corresponding security and stability control strategies (SSCSs), restoring stability to the system through measures such as generator cutoffs, load shedding, and power modulation of HVDC.Currently, due to the complexity and variability of the grid operation mode, the type and the control volume of SSCSs' action can cause different impacts.Consequently, it is necessary to model and simulate the security and stability control system to ensure its effectiveness.
At present, SSCSs are generally designed according to the 'offline simulation and online matching' approach [6], [7].Due to the diversity in grid structure, different power grids manifest various safety and stability characteristics.Moreover, diverse power grids confront distinct security risks.Therefore, SSCSs are closely related to factors such as the operation mode, as well as the type and location of faults.In a real system, the typical SSCS consists of the operation mode, equipment faults, tie-lines power flow and control [8].When the specified fault occurs under the matched operation mode and the tie-lines power flow exceeds limits, the corresponding SSCS acts to regulate the controlled entities.The process of devising SSCSs is shown in figure 1.Firstly, high-risk fault scenarios, such as N-2 faults, are filtered based on stability evaluation in the expected operation mode.Subsequently, the SSCS is manually designed under the unstable fault scenarios.Then, the effectiveness of SSCS are assessed across a broader range of operation modes for further strategy adjustments.Throughout this procedure, simulation plays a pivotal role.On one hand, the SSCS is designed based on the simulation.On the other hand, subsequent to devising of the SSCS, it undergoes validation through simulation.However, the existing commercial simulation software, such as BPA and PSASP, lacks a systematic approach to simulate SSCSs.These limitations manifest in the following ways: i) The existing software faces challenges in dynamically simulating the complex trigger condition.The actions of a SSCS correspond to the operation mode, equipment faults (e.g., line tripping), and tie-lines power flow, which means the trigger conditions of SSCSs are complex and the trigger time is unknown before simulation.However, these existing tools can only trigger control at pre-defined time or through simple signal processing.ii) Some intricate control logics of SSCSs are difficult to implement by existing tools, such as prioritization of tripping generators.iii) Multiple SSCS usually work simultaneously and collectively form a security and stability control strategy set (SSCSS), the existing tools fail to simulate this complicate case simultaneously.
These limitations arise from the fact that the existing software is not sufficiently open to users.The user can only observe and adjust parameters of simulation case through limited interaction ports.To address the aforementioned issues, based on the open interface and software development kit for the model layer, algorithm layer and application layer provided by CloudPSS [9] , this study introduces an event-driven approach for simulating SSCSs.By analyzing the strategy logic of SSCSs, the event-driven mechanism is employed to decouple the SSCSs.Finally, the dynamic simulation of SSCSs can be realized in CloudPSS.The rest of this paper is organized as follows.Section 2 constructs the eventdriven model of the SSCS and applies the event triggering mechanism to simulate SSCSs.Section 3 validates the effectiveness of the proposed methodology based on the IEEE 39-bus system.

Event-driven model
In practice, SSCSs typically manifest as a collection, characterized by intricate and diverse control logics.Consequently, it becomes imperative to prevent interference among different SSCSs during simulations.The event-driven mechanism, a widely employed programming paradigm in the domains of computer science and software engineering, offers a viable solution for ensuring the independent operation of SSCSs [10], [11].An event in this context often denotes a factual occurrence that triggers a change in the system's state or serves to characterize the state of the system [12]- [14].Within the control logic framework of SSCSs, equipment failures serve as the cause for altering the system state, while tie-lines power flows describe the state.Therefore, equipment failures and tie-lines power flow overlimits within the power system are considered as events.Correspondingly, we regard the corresponding control measures as actions triggered following the occurrence of these events.Then, the event-driven model of SSCSs encompasses the following elements: Event: as the trigger event of control measures, it usually includes device fault information and system status identification, such as line tripping, frequency exceeding limits, and tie-lines power flow exceeding limits.
Event Listening: in time-domain simulation, the simulation script continuously monitors the status of preset events.Once an event occurs, the corresponding control measures are automatically triggered.
Event Processing: the action triggered by the occurrence of the event, i.e., the control measure, including the control object and the control volume.
In this way, the event-driven model for power system transient simulation considering SSCSs is shown in figure 2.

Event triggering mechanism
Drawing from the aforementioned modeling approach, within a standard SSCS model, the occurrence of equipment failures matching and tie-lines power flow overlimits is requisite to activate a control measure.Consequently, the conventional one-to-one correspondence between events and actions is inapplicable in this current context.Moreover, during simulation, these events are essentially monitoring of system state variables, potentially leading to a substantial number of duplicate events when multiple SSCSs are configured.Thus, in order to better simulate SSCSs and simultaneously save the resources for state monitoring during configuration, this paper introduces the SSCS triggering mechanism illustrated in figure 3  1) Combined outputs of events Figure 4 illustrates the configuration of trigger events for SSCSs in the simulation.Specifically, Monitor1 and Monitor2 are used to configure the events of lines tripping and tie-lines power flow exceedances, respectively.Furthermore, Monitor3 is introduced to execute logical operations involving the outputs of Monitor1 and Monitor2, ultimately initiating the control measures of the SSCS through the output of Monitor3.The cascade design of the MC offers flexibility in combining the outputs of independent events to realize the triggering and response of SSCSs.
Line L 1 , L 2 tripping Tie-lines power flow P 3 +P 4 +P 5 exceeds limit P L Control measure

2) Multi-stage event processing
In practical scenarios, certain SSCSs require multi-stage control measures.Leveraging the cascading design of the MC, we implement these multi-stage control measures in simulation by logically dividing them into stages and combining them using an event-based combined output approach.To illustrate this approach, we refer to figure 5, which demonstrates the prioritization of tripping generators.Initially, Event1 is assigned to Monitor4, triggering control measure Ⅰ (Tripping the generator set A with the highest priority).Subsequently, the logical judgment within control measure (determining whether PA ≥ 100MW?) and the logic output of Monitor4 are fed into Monitor5.Monitor5 initiates control measure Ⅱ (Tripping the generator set B with a lower priority).This example illustrates how the cascade design of MCs is capable of handling intricate logic for control measures.

Trigger Event：Event1 Control Measure：
The total active power output of the removed generator units P all is 100MW.Generator set A is prioritized for removal.If the cutting capacity is less than 100MW, generator set B is also cut.The effectiveness of the event-driven SSCS simulation method is validated through the SSCM implemented on the CloudPSS cloud simulation platform.In this paper, the IEEE 39-bus system is used as a test case.The system structure is depicted in figure 6 below.

Conclusion
This paper introduces an event-driven based simulation method for SSCSs of power systems, which is applied to build the SSCM on CloudPSS.The event-driven model of SSCSs ensures mutual independence during simulations and enables the implementation of complex control logic.To conclude, the accuracy and effectiveness of this proposed methodology and the constructed module are validated based on the IEEE 39-bus system.

Figure 1 .
Figure 1.The process of developing a SSCS.

Figure 2 .
Figure 2. The event-driven simulation of power systems considering SSCSs.

Figure 3 .
Figure 3. Event triggering mechanism of SSCS in simulation.

3 .
Case study Building upon the above theoretical foundation, this study constructs an event-driven SSCS simulation module on the CloudPSS simulation platform, named the Security and Stability Control Module (SSCM).It encompasses four functional domains: Operation Mode, Fault Setting, Event Monitoring, and Control Measure, aligning with the strategic logic of the SSCS.The centralized configuration of triggering conditions is executed through the event monitoring function.This function comprises monitor cards, with each card representing the monitoring configuration of a class of signals.Each monitor card is a MC.Additionally, multiple control measures can share the same monitor card, preventing redundancy in signal monitoring configuration.Once monitor cards are configured, users can proceed to define specific control measure configurations, such as generator tripping, load shedding, and other operations.In this function, users have the flexibility to establish multiple security and stable control strategy tables.Each strategy table incorporates multiple measure cards.Each measure card corresponds to a control measure, activated by the output signal from the monitoring card.

Table 1 .
Configuration of SSCSsNo generators or transmission lines are out of service in the system.Lines 1-2 and 2-3 are tripped at 4s; lines 16-17 and 16-24 are tripped at 6s.The monitor cards of the case are listed in table 1, and the measure cards are detailed in table 2. Configuration of event monitoring.