Layered fuzzy color petri net micro-grid fault diagnosis method considering time constraint

By employing a layered fuzzy color Petri net method, and utilizing bidirectional temporal inference and Gaussian function optimization to determine the time reference point and confidence assignment, the problem of insufficient time constraints in existing technologies is solved, achieving rapid, accurate, and adaptable microgrid fault diagnosis.

CN121385531APending Publication Date: 2026-01-23SHIHEZI UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511618480.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-06
Publication Date
2026-01-23

AI Technical Summary

Technical Problem

Existing Petri net-based microgrid fault diagnosis technologies have shortcomings in the selection of time reference points and the handling of time constraints, resulting in limited diagnostic accuracy and reliability, making it difficult to meet the microgrid's requirements for speed and adaptability.

Method used

A hierarchical fuzzy color Petri net method considering time constraints is adopted. The timestamp of alarm information is verified by bidirectional temporal inference. Alarm information that does not meet the time constraints is processed by combining a probabilistic inference model and a Gaussian function. A hierarchical weighted fuzzy Petri net model is constructed to optimize the selection of time reference points and the assignment of confidence scores.

Benefits of technology

It improves the accuracy and reliability of microgrid fault diagnosis, meets the requirements of speed and adaptability, and enhances the model's versatility and diagnostic efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121385531A_ABST
    Figure CN121385531A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of power grid fault diagnosis, and discloses a hierarchical fuzzy color petri net micro-grid fault diagnosis method considering time constraint, which comprises the following steps: determining a suspicious fault element through a junction line analysis method according to alarm information, micro-grid topology and protection configuration information; constructing a time sequence reasoning and probabilistic reasoning model for each suspicious fault element, verifying an alarm information timestamp by adopting bidirectional time sequence reasoning, and endowing the alarm information timestamp with initial confidence; probabilistic reasoning is carried out based on a hierarchical weighted fuzzy petri net, and an actual fault element is determined and abnormal alarm information is found out in combination with a reasoning result; reasoning a time reference point according to the priority sequence of each suspicious fault element and a time constraint condition, and attenuating the confidence coefficient of alarm information which does not meet the time constraint by using a Gaussian function according to the time distance; the technical problem that in the prior art based on the petri net, defects exist in time reference point selection and time constraint processing, and consequently diagnosis accuracy and reliability are limited is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of power grid fault diagnosis technology, and specifically to a fault diagnosis method for a layered fuzzy color Petri net microgrid that takes time constraints into account. Background Technology

[0002] As a crucial component of smart grids, the safe and stable operation of microgrids heavily relies on rapid and accurate fault diagnosis systems. Due to the flexible operation and diverse topologies of microgrids, fault diagnosis methods must possess high versatility and adaptability to address different network structures and fault scenarios. Furthermore, constrained by construction costs, microgrids require more lightweight diagnostic solutions than traditional distribution networks, which places even greater demands on the speed of fault diagnosis.

[0003] Currently, power scientists have proposed various methods for power system fault diagnosis using switching and electrical quantities, including expert systems, artificial neural networks, analytical models, Bayesian networks, and fuzzy set theory. While these methods can effectively identify and locate faults to some extent, they may face problems of high computational complexity and slow inference speed when dealing with complex faults in practical applications, making it difficult to meet the rapid fault diagnosis requirements of microgrids.

[0004] To overcome these limitations, Petri nets, with their inherent support for parallel triggering of multiple events, simple and direct inference process, high computational efficiency, and clear physical meaning, exhibit unique advantages in the field of power system fault diagnosis. However, existing Petri net-based fault diagnosis techniques often use fixed time reference points or directly select the timestamp of the first alarm message as the starting point for inference, without verifying their accuracy, and are susceptible to factors such as maloperation and failure to operate of protection devices and circuit breakers. Furthermore, these methods typically assign low confidence levels directly to alarm messages that do not meet time constraints, without fully considering the degree of time deviation of the alarm information, thus affecting the accuracy and reliability of fault diagnosis. Summary of the Invention

[0005] The present invention aims to provide a fault diagnosis method for microgrids based on hierarchical fuzzy color Petri nets that takes into account time constraints, in order to solve the technical problems that existing Petri net-based technologies have shortcomings in the selection of time reference points and the handling of time constraints, which lead to limited diagnostic accuracy and reliability.

[0006] To achieve the above objectives, the present invention adopts the following technical solution: a time-constrained hierarchical fuzzy color Petri net microgrid fault diagnosis method, comprising: S1. Obtain alarm information from protection devices and circuit breakers at all levels, and determine suspected faulty components based on alarm information, microgrid topology, and protection configuration information using the wiring analysis method; S2. Construct temporal reasoning and probabilistic reasoning models for each suspected faulty component, and use bidirectional temporal reasoning to verify the alarm information timestamp and assign an initial confidence level. S3. Based on hierarchical weighted fuzzy Petri net, perform probabilistic reasoning, combine the reasoning results to determine the actual faulty components and find abnormal alarm information; In S2, the time reference point is inferred based on the priority sequence of each suspected faulty component and the time constraint conditions, and the confidence level of alarm information that does not meet the time constraint is attenuated by a Gaussian function according to the time distance.

[0007] The principle and advantages of this scheme are as follows: It verifies alarm information timestamps through bidirectional temporal reasoning, ensuring the accuracy of time information, and combines this with a probabilistic reasoning model to assess the likelihood of faults. A hierarchical weighted fuzzy Petri net model is constructed, leveraging the parallel triggering and efficient reasoning capabilities of Petri nets, and the hierarchical structure enhances the model's versatility and adaptability. Time reference points are inferred based on the priority sequence of each suspected faulty component and time constraints, avoiding errors caused by fixing time reference points or directly selecting the timestamp of the first alarm message. For alarm messages that do not meet time constraints, a Gaussian function is used to attenuate their confidence over time, fully considering the degree of time deviation of the alarm information and improving diagnostic accuracy.

[0008] By employing bidirectional temporal inference and dynamic time reference point selection, the impact of inaccurate time information on diagnostic results is reduced, improving the accuracy of fault diagnosis. The hierarchical weighted fuzzy Petri net model can flexibly adapt to different microgrid topologies and fault scenarios, enhancing the model's versatility and adaptability. Using a Gaussian function to decay the confidence of alarm information that does not meet time constraints over time distance fully considers the degree of time deviation of alarm information, avoiding misjudgments caused by directly assigning low confidence levels. The parallel triggering and efficient inference capabilities of the Petri net, combined with a lightweight model design, enable this method to maintain high accuracy while also possessing fast inference speed, meeting the microgrid's demand for rapid fault diagnosis.

[0009] Preferably, as an improvement, S2 specifically involves receiving alarm information, establishing a priority sequence based on the operating times of the protection device and the circuit breaker, and using time constraints and the priority sequence to filter time reference points from the alarm information time list. Based on a defined time reference point and time constraints, the fault time interval of the fault occurrence is inferred. Based on time constraints, the action delay information of protection and circuit breakers at all levels, the reference time interval of protection and circuit breakers is further inferred. The actual protection time point and circuit breaking time point are compared with the inferred reference time interval for judgment. If the actual time point is within the reference time interval, a high confidence level is set for the corresponding protection device; if the actual time point is not within the reference time interval, a confidence level is assigned using a Gaussian decay function based on the difference between its timestamp and its reference time interval.

[0010] The beneficial effects of this improvement are as follows: By establishing a priority sequence, alarm information from different protection devices and circuit breakers can be processed more rationally, making the selection of time reference points more logical. Inferring fault time intervals and reference time intervals for protection devices and circuit breakers based on time reference points provides a more accurate basis for time judgment. Comparing actual time points with reference time intervals and setting confidence levels, especially by using a Gaussian decay function to assign values ​​to time points outside the interval, fully considers the impact of time deviations, making the confidence level setting more scientific and reasonable, and improving the accuracy and reliability of fault diagnosis.

[0011] Preferably, as an improvement, in step S2, for protection devices that receive alarm information but whose actual time point is not within the reference time interval, the confidence level calculation formula is as follows: ; ; ; in, To protect the confidence level of the equipment; The confidence level when the alarm information from the protection device is received and the time constraint is met; Its timestamp The minimum absolute value at the boundary of the reference time interval T(a), and These represent the lower and upper limits of the time interval, respectively; σ is the tolerance for time difference, and σ is half the length of the reference time interval T(a).

[0012] The beneficial effects of this improvement are: by using parameters such as the confidence level when receiving alarm information and meeting time constraints, the minimum absolute value of the timestamp to the boundary of the reference time interval, the upper and lower limits of the time interval, and the tolerance for time differences, the confidence level can be calculated more accurately based on the degree of time deviation. This avoids simply assigning low confidence values, making the confidence level calculation more consistent with reality, improving the accuracy and rationality of handling alarm information at abnormal time points, and thus enhancing the overall accuracy of fault diagnosis.

[0013] Preferably, as an improvement, in S2, the earlier the action time in the priority sequence sorting, the higher the priority of the corresponding protection device.

[0014] The beneficial effects of this improvement are: protection devices with earlier response times generally respond to faults more directly and promptly. Prioritizing them allows for faster focus on core fault clues during fault diagnosis, reducing unnecessary calculations and analysis and improving diagnostic efficiency. Simultaneously, it helps to more accurately determine the initial stage and related circumstances of the fault, providing a more reliable foundation for subsequent fault location and cause analysis, thus enhancing the overall accuracy and timeliness of fault diagnosis.

[0015] Preferably, as an improvement, a bidirectional temporal reasoning model and a hierarchical probabilistic reasoning model constructed using CPN Tools are adopted; The modular construction of the temporal inference model includes a time reference point inference module, a fault time interval inference module, and an initial assignment module; The time reference point reasoning module is responsible for time reference point reasoning. It starts by receiving a list of alarm information time information sorted by priority from the initial library, combines the library of delay information of each protection and circuit breaker, and the library that provides iterative variables, performs time constraint verification and iterative calculation through transitions, and finally outputs the time reference point. The fault time interval reasoning module is responsible for fault time interval reasoning. Based on the time reference point library and the alarm information time list library, it calculates the reference time interval of the fault event through transitions and outputs it. The initial assignment module is responsible for the inference and verification of the reference time interval of protection and circuit breakers. By extracting the alarm information time and status parameters, combining them with the fault event reference time interval database, and after transition judgment and assigning initial confidence, it outputs the initial state list of alarm information. The transitions within the module include conditional judgments, time calculations, and confidence assignments. The parameter definition section includes time delays, variable declarations, and function declarations.

[0016] The beneficial effect of this improvement is that when the system topology changes, the modular design of the model allows each module to operate relatively independently. For example, if a new line is added to the system or the location of a circuit breaker is changed, only the locations, transitions, or parameters related to that line or circuit breaker need to be modified. For instance, in the protection equipment layer, if a distance protection device is added, only the device's information needs to be added to the corresponding location, and the relevant transition parameters need to be adjusted, without needing to reconstruct the entire model.

[0017] Preferably, as an improvement, the hierarchical probabilistic inference model includes: The protection device layer includes multiple protection device locations, receives an initial state list of alarm information output by time-series inference, and assigns initial confidence levels through transitions; The fault propagation path layer includes multiple fault propagation path libraries. The confidence level of each fault propagation path is obtained by transitioning the confidence level of the protection and circuit breaker. The protection composite probability layer, including the protection composite probability module, selects the maximum confidence of each fault propagation path through transitions, which serves as the comprehensive confidence of the main protection, near backup protection, and far backup protection. The fault element probability layer performs Gaussian calculations on the overall protection confidence level through transitions, selects the maximum value as the final confidence level of the fault element, and outputs it. The layers are connected by directed arcs. Data flows sequentially from the protection device layer to the fault component probability layer. The parameter definition section includes color sets, variables, and Gaussian function declarations. The transitions within the module include confidence synthesis, Gaussian calculation, and maximum value selection.

[0018] The beneficial effects of this improvement are as follows: The hierarchical probabilistic inference model, through step-by-step analysis and calculation, comprehensively considers multiple factors such as monitoring information from protection equipment, fault propagation paths, and the synthetic probability of protection actions, making the final confidence level of faulty components more accurate and reliable, thereby improving the accuracy of microgrid fault diagnosis. The hierarchical structure makes the fault diagnosis process clearly visible, and the calculation results of each layer can serve as the basis for subsequent analysis. Developers and maintenance personnel can easily check and debug the model, locate the problem, and improve the maintainability and interpretability of the fault diagnosis method.

[0019] Preferably, as an improvement, in step S3, the confidence level of each suspected faulty component is compared with a set threshold. If the confidence level of a suspected faulty component is greater than the threshold, the component is identified as an actual faulty component. Alarm information with a confidence level lower than the confidence level threshold is combined with evaluation indicators to make judgments and analyses to find the abnormal judgment results.

[0020] The beneficial effects of this improvement are: by setting a threshold and comparing it with the confidence level of suspected faulty components, the actual faulty component can be quickly and accurately identified, improving the efficiency and accuracy of fault diagnosis. For alarm messages with a confidence level below the threshold, further analysis combined with evaluation indicators can identify abnormal judgment results, avoiding misjudgments and omissions. This approach ensures both accurate identification of the main faulty components and in-depth investigation of possible anomalies, improving the reliability and comprehensiveness of the entire fault diagnosis system.

[0021] Preferably, as an improvement, the evaluation indicators include malfunction judgment indicators, refusal to operate judgment indicators, loss judgment indicators, and timing inconsistency judgment indicators; The criteria for judging maloperation include fault models and non-fault models. The prerequisite for faulty components is the status and operation of the main protection and the main protection circuit breaker. The operation / status of the protection equipment being evaluated for the faulty component is the operation of the backup protection or the operation of the backup protection circuit breaker. There are no prerequisites for non-faulty models. The operation / status of the protection equipment being evaluated for non-faulty models is the operation of the protection or the operation of the circuit breaker. The failure to operate judgment index is judged on the faulty component. The prerequisite is that the main protection / main protection circuit breaker does not operate and the backup protection operates, or the backup protection circuit breaker operates. The operation / state of the protected equipment being evaluated is that the main protection / main protection circuit breaker does not operate. The missing judgment index is judged as a faulty component. The prerequisite is that the main protection / main protection circuit breaker has not operated and the backup protection / backup protection circuit breaker has not operated. The operation / status of the protected equipment being evaluated is that the main protection / main protection circuit breaker has not operated. The timing inconsistency judgment index judges all components. The prerequisite is that an alarm message from the protection / circuit breaker is received, and the action / status of the evaluated protection device is that the protection or circuit breaker has not acted.

[0022] The beneficial effects of this improvement are: it allows for in-depth analysis of alarm information from multiple perspectives, and these indicators complement each other, enabling a comprehensive and accurate identification of anomalies. This enhances the fault diagnosis system's ability to identify various abnormal situations, thereby improving the accuracy and reliability of fault diagnosis.

[0023] Preferably, as an improvement, in step S2, the low confidence level for the protection device that has not received the corresponding alarm information is set to 0.2; A high confidence level is set for protection devices that receive alarm information and meet the time constraints. Specifically, the confidence level is 0.9 for the main protection device, 0.8 for the near backup protection device, 0.7 for the far backup protection device, and 0.95 for the circuit breaker device.

[0024] The beneficial effects of this improvement are: setting low confidence levels avoids over-reliance or misjudgment due to lack of information; different types of protection devices are set with different high confidence levels, which fully considers their importance and reliability differences in fault protection. The main protection device and circuit breaker device are set with higher confidence levels, while the confidence levels of near backup and far backup protection devices decrease sequentially, which conforms to the actual protection logic and helps to more accurately judge the fault situation and improve the accuracy of fault diagnosis.

[0025] Preferably, as an improvement, the priority sequence of S2, from high to low, is: main protection, main protection circuit breaker, near backup protection, near backup protection circuit breaker, far backup protection and far backup protection circuit breaker.

[0026] The beneficial effects of this improvement are as follows: The main protection provides rapid protection directly against faults, with the highest priority, ensuring swift action upon fault occurrence; the main protection circuit breaker interrupts the fault current and follows immediately after the main protection. Near-backup protection functions when the main protection fails, with the next highest priority; the same applies to near-backup protection circuit breakers. Far-backup protection, acting as a further downstream protection line, has a lower priority; the same applies to far-backup protection circuit breakers. This prioritization allows for the priority assessment of critical protection information during the time reference point selection process, improving fault response speed and diagnostic accuracy, aligning with the protection logic and practical needs of the power system. Attached Figure Description

[0027] Figure 1 This is a flowchart illustrating the fault diagnosis process according to an embodiment of the present invention.

[0028] Figure 2 This is a flowchart of bidirectional temporal reasoning in an embodiment of the present invention.

[0029] Figure 3 This is a schematic diagram showing the time distance between various protection devices and circuit breakers in an embodiment of the present invention.

[0030] Figure 4 This is a schematic diagram of bidirectional temporal reasoning modeling in an embodiment of the present invention.

[0031] Figure 5 This is a schematic diagram of the bidirectional temporal inference CPN Tools modeling in an embodiment of the present invention.

[0032] Figure 6 This is a schematic diagram of hierarchical probabilistic reasoning modeling in an embodiment of the present invention.

[0033] Figure 7 This is a schematic diagram of the hierarchical probabilistic inference CPN Tools modeling in an embodiment of the present invention.

[0034] Figure 8 This is a schematic diagram of the IEEE 14-bus system according to an embodiment of the present invention. Detailed Implementation

[0035] The following detailed description illustrates the specific implementation method: Example 1 The basics are as follows: Figure 1 As shown, a time-constrained hierarchical fuzzy color Petri net microgrid fault diagnosis method includes: S1. Obtain alarm information from protection devices and circuit breakers at all levels, and determine suspected faulty components based on alarm information, microgrid topology, and protection configuration information using the wiring analysis method; S2. Construct temporal reasoning and probabilistic reasoning models for each suspected faulty component, and use bidirectional temporal reasoning to verify the alarm information timestamp and assign an initial confidence level. S3. Based on hierarchical weighted fuzzy Petri net, perform probabilistic reasoning, combine the reasoning results to determine the actual faulty components and find abnormal alarm information.

[0036] In S2, the time reference point is inferred based on the priority sequence of each suspected faulty component and the time constraint conditions, and the confidence level of alarm information that does not meet the time constraint is attenuated by a Gaussian function according to the time distance.

[0037] In S1, the microgrid topology data includes relationships such as busbars and line connections, and the protection configuration includes the protection ranges of main protection, near-backup protection, and far-backup protection. The connection analysis method infers the possible fault areas by judging the correlation between circuit breaker tripping and protection actions, combined with the topology structure. For example, if the main protection of a line operates and the circuit breaker trips, then that line is a suspected faulty element. Finally, a list of suspected faulty elements is output.

[0038] The knot analysis method is the starting point of the entire hierarchical fuzzy color Petri net fault diagnosis process, providing basic data for subsequent temporal and probabilistic inference. Its role is similar to "coarse screening," quickly locating potential fault points through topology and protection information, and then performing "fine diagnosis" using the Petri net model.

[0039] In S2, as shown in the appendix Figure 2 As shown, bidirectional timing reasoning includes reverse timing reasoning and forward timing reasoning. Reverse timing reasoning includes time reference point reasoning and fault time interval, while forward timing reasoning includes reference time interval reasoning for protection and circuit breakers, and verification of whether protection and circuit breakers meet the reference time interval.

[0040] Specifically, S2 receives alarm information and establishes a priority sequence based on the expected operating time of the protection device and the circuit breaker.

[0041] By combining time constraints with a priority sequence, a reasonable time reference point is found from the alarm information time list. This time reference point serves as the basis for subsequent reasoning.

[0042] Based on a defined time reference point and time constraints, the approximate time range of the fault occurrence can be inferred, i.e., the fault time interval. Simultaneously, the relevant time ranges for protection devices and circuit breakers can also be derived.

[0043] Based on known time constraints and other information, we can further refine our reasoning regarding the reference time interval that the protection and circuit breaker should be in.

[0044] The actual protection and circuit breaker times are compared with the inferred reference time interval. If the actual time is within the reference time interval, it indicates that the expected result is met; otherwise, there may be an anomaly. A confidence level is then assigned based on this judgment.

[0045] In the priority sequence, the earlier the action time, the higher the priority. The sequence is as follows: main protection, main protection circuit breaker, near backup protection, near backup protection circuit breaker, far backup protection, and far backup protection circuit breaker. The order of circuit breakers of the same level does not affect the reasoning result.

[0046] Reverse temporal reasoning determines the time reference point by traversing the alarm information time list, utilizing time constraints, and employing iterative calculations and conditional judgments. Time constraints include unary and binary time constraints.

[0047] Univariate time constraint, the time of occurrence of a single event 'a' Should meet ,in, For time interval and , and These represent the lower and upper limits of the time interval, respectively.

[0048] Binary time constraint, the distance between the times of occurrence of two times a and b. Should meet , for Time constraints and , and These are the lower and upper limits of the time interval, respectively. , .

[0049] The specific constraint data for univariate and bivariate time constraints are obtained from the configuration information.

[0050] When filtering time reference points, it is necessary to iterate through the list of alarm information times and check whether each alarm time meets the univariate time constraint of the corresponding protection device or circuit breaker. If an alarm time exceeds the time interval specified by the device or circuit breaker, then the rationality of this time as a time reference point will be reduced.

[0051] It is also necessary to analyze whether the relationship between this time and the alarm times of other relevant events conforms to the binary time constraints. For example, the time difference between the main protection action time and the main protection circuit breaker action time should be within the specified range. By checking multiple relevant binary time constraints, candidates for time reference points that meet the conditions can be further screened.

[0052] Among multiple candidate time reference points, the time point that satisfies the time constraints and has the highest priority sequence is selected as the time reference point.

[0053] Based on a defined time reference point, and combining univariate and bivariate time constraints, the approximate time range of the fault occurrence can be inferred, i.e., the fault time interval.

[0054] Forward timing reasoning, based on known time constraints and inferred fault time intervals, further refines the reference time intervals that the protection and circuit breakers should be in.

[0055] When reasoning over time intervals The triggering, setting, or operation of protection devices and circuit breakers may have a certain time delay error. After a fault, the protection relay operates according to the set operating delay, and then triggers the corresponding circuit breaker to trip, resulting in a certain disconnection delay. The timing reasoning of this invention is determined based on considering this time delay error. Based on the operating times of the protection devices and circuit breakers contained in the alarm information, and obtaining time constraints and operating delay information of each level of protection and circuit breaker from the configuration information, the time distance between each level of protection and circuit breaker is calculated. The time distance between each protection and circuit breaker can be calculated based on its own operating delay. The time distance between the fault event and the circuit breaker, between protection and the circuit breaker, between different protections, and between different circuit breakers can be calculated based on the operating delay information obtained from the configuration information.

[0056] The operating delay of protection devices and circuit breakers at all levels, for example: Action delay: The action delay of the main protection is in the range of [10, 40]; the action delay of the near backup protection is in the range of [260, 340]; the action delay of the far backup protection is between [950, 1070]; the action delay of the circuit breaker is [20, 40].

[0057] These time ranges reflect the time span required for each protection device and circuit breaker to actually perform protection actions from detecting a fault under different fault conditions.

[0058] The actions of main protection, near-backup protection, and far-backup protection are all relative to the fault event. This means that they are activated after a fault occurs, based on the characteristics and severity of the fault, and after a corresponding delay. The operation of a circuit breaker, however, corresponds to the action of the protection device. That is, when the protection device issues a command, the circuit breaker performs operations such as opening or closing within a certain delay time to achieve the purpose of protecting the circuit.

[0059] As attached Figure 3 As shown, the graph illustrates the temporal relationship between fault events, protection systems, and circuit breakers. The horizontal axis represents time t, depicting the time progression from the occurrence of the fault to the operation of each protection system and circuit breaker. Multiple time points are marked in the graph, such as... These represent event reference points for fault events, protection systems, and circuit breakers, respectively. The time intervals for the operation of fault events, protection systems, and circuit breakers are represented by rectangular bars with different fill levels.

[0060] In forward timing reasoning, it is verified whether the protection and circuit breaker meet the reference time interval by comparing the actual protection and circuit breaker times with the inferred reference time interval. The comparison results include three cases: no alarm information received, alarm information received and the time constraint is met, and alarm information received but the time constraint is not met.

[0061] As attached Figure 2 As shown, the specific process of bidirectional timing includes: The reverse temporal reasoning part, Initialize the variables, setting i = 0, j = 1, and n, where n is the total number of alarm messages. The priority level of the alarm message is represented by i; the smaller the value of i, the higher the priority. .

[0062] Select alarm information pairs, choose two alarm information with priorities i and i+j, and obtain their timestamps.

[0063] Calculate the time distance, specifically the actual time distance and the reference time distance between these two alarm messages.

[0064] To determine if the inner loop has been traversed, check if i < (n-1) is true.

[0065] If true, proceed to the next step of judgment.

[0066] If this is not the case, the value of i is reset to i=0, and the current priority, i.e., the timestamp of i=0, is directly selected as the time reference point.

[0067] Determine if the time distance meets the constraints, and check if the actual time distance is within the reference time distance range.

[0068] If true: Use the timestamp of the alarm message with priority i as the time reference point.

[0069] If not true: execute j=j+1 to increment the value of j, and return to the above steps to recalculate the time distance. At the same time, it will also check whether j<(n-1) is true. If not true, execute j=1 to reset the value of j, and set i=i+1.

[0070] Calculate the fault reference time interval. Based on the determined time reference point, calculate the reference time interval for the occurrence of the fault.

[0071] Forward temporal reasoning section, Check the alarm information reception status of the protection devices to determine whether alarm information from each protection device has been received.

[0072] If not received, set a lower confidence level for the corresponding protection device.

[0073] If received, proceed to the next step.

[0074] Calculate the reference time intervals for protection and circuit breakers, and calculate the reference time intervals for the operation of each protection device and circuit breaker.

[0075] Verify whether the timestamps meet the reference interval, and check whether the timestamps of each protection device and circuit breaker meet their corresponding reference time intervals.

[0076] If the conditions are met, a higher confidence level is set for the corresponding protection device or circuit breaker.

[0077] If the conditions are not met, a confidence level is assigned to the corresponding protection device or circuit breaker using Gaussian calculation (Gaussian decay function).

[0078] The method for determining the confidence level of structure assignment based on comparison is as follows: Protection devices that do not receive corresponding alarm information are set to a lower confidence level, i.e., 0.2. Protection devices that receive alarm information and meet time constraints are assigned a higher confidence level, specifically: 0.9 for main protection devices, 0.8 for near backup protection devices, 0.7 for far backup protection devices, and 0.95 for circuit breaker devices. For protection devices that receive alarms but do not meet the time constraints, instead of directly setting a low confidence level, a Gaussian decay function is used to assign a value based on the difference between the timestamp and its reference time interval. This addresses the possibility of incorrect timestamps in some alarm messages and enhances the robustness of time inference.

[0079] The Gaussian decay function is used for assignment, and the specific calculation formula is as follows: ; ; ; in, To protect the confidence level of the equipment, The confidence level for receiving the alarm information of the protection device and meeting the time constraint is as follows: the protection devices are, in order, the main protection device corresponds to guass (0.9), the near backup protection device corresponds to guass (0.8), the far backup protection device corresponds to guass (0.7), and the circuit breaker device corresponds to guass (0.95). Its timestamp The minimum absolute value at the boundary of the reference time interval T(a), and These are the lower and upper limits of the time interval, respectively; σ is the tolerance for time difference, and its size is chosen to be half the length of its reference time interval T(a).

[0080] According to this calculation formula, when When the confidence level decreases to 60.6% of its original value, the confidence level drops to 60.6% of its original value. When the confidence level is 2σ, it decreases to 13.5% of its original value.

[0081] The model of a layered weighted blurred color Petri net, i.e., HWFCPN, is defined as a thirteen-tuple: HWFCPN={P, T, F, I, O, θ, Σ, V, C, E, G}; Where P is a finite set of k libraries, P = { , ,..., }, where n is the total number of warehouses.

[0082] T is a finite set of transitions, T={ , ,..., }, where m is the total number of transitions.

[0083] F is a finite set of directed arcs, F⊆(P×R)∪(R×P).

[0084] I is the input arc matrix of the place-to-transition, I=( )n×m, when there exists a slave warehouse transition to b When the arc is directed, ∈[0,1] is the weight of the arc, otherwise =0, where i=1,2,...,n; j=1,2,...,m.

[0085] O is the output arc matrix of the transition to the place, O=( )m×n, when there exists a transition from to the warehouse When the arc is directed, =1, otherwise =0, where i=1,2,...,m; j=1,2,...,n.

[0086] θ is the confidence vector of the place. , Let i be the confidence level of the library. ∈[0,1].

[0087] Σ is a finite set of colors, Σ={ , ,..., }, Σ=∅, where i is the number of colors in the color set.

[0088] V is a finite set of variables, V={ : ,..., : Each variable is associated with a color set.

[0089] C is the coloring function, C:P→Σ, which maps each library to a color set.

[0090] E is an arc function, E: F→EXPR, which maps each directed arc to an arc expression.

[0091] G is a protection function, G:R→EXPR, which maps each b transition to a protection condition.

[0092] This solution uses CPN Tools to construct a bidirectional temporal inference model and a hierarchical probabilistic inference model. CPN Tools is a powerful graphical tool for color Petri nets, enabling intuitive and precise implementation of complex data processing and logical judgment processes within the model.

[0093] As attached Figure 4 As shown, this is the overall model of a layered Petri net for bidirectional time-series reasoning. The "Search timereference" and "Search time of cause" modules constitute the reverse time-series reasoning, which correspond to the two steps of time reference point reasoning and fault time interval reasoning, respectively. The forward time-series reasoning is composed of the "Search initial state" module, which includes the two steps of reference time interval reasoning for protection and circuit breakers and verifying whether protection and circuit breakers meet the reference time interval. These three modules are strictly performed in the logical order of the diagnostic process.

[0094] The bidirectional temporal inference model constructed using CPN Tools is detailed in the attached figure. Figure 5 As shown, the upper part of the image is the model, with three modules separated by dashed lines and labeled with their names on the left or right. The lower part has a dashed box with the label "..." in the upper right corner. "and" The section marked "" represents the code segment corresponding to the strain transition. The section marked "Declarations" in the upper right corner defines the relevant parameters, which only lists some of the constants "Delay". The rest can be calculated based on the operating delay of each protection and circuit breaker, as well as the time distance between each protection and circuit breaker. According to the appendix Figure 5 In Definition2, the model's color set, variables, color functions, and other parameters are shown below: Σ={REALT,INT,test_list,list_int,list_list}, where REALT represents a real number type with time, INT represents an integer type, test_list and list_int represent REALT and integer list types respectively, used to represent time and state sequences, and list_list represents test_list list type, used to represent a sequence of time intervals.

[0095] V={i,j:INT,test1,test2,test3,test4,test5:test_list,list_list1:list_list,int1,int2:list_int}, where each variable represents the flow of tokens of the corresponding color type on the arc.

[0096] For any library ∈P,C( The color is not fixed and is displayed in the lower right corner of each warehouse's color set.

[0097] For any directed arc, E(F) is not fixed and is displayed on EXPR on each arc.

[0098] For any change ∈T, G( The value is not fixed and is displayed next to each transition as "[EXPR]".

[0099] The functions Time_compare() and Time_verify() are used to determine... ∈T(a), verify =0, hasOneInFirstN() and firstNonZero() are used to determine if there is a 1 in the first N elements of the list and to find the first non-zero element in the list, respectively. dropSafe() is used to remove the first N elements of the list. guasst() is used to implement the Gaussian decay function. match_time() is used to match parameters. delay() and get_type are used to match the corresponding delay and confidence level, respectively.

[0100] Module "Search time reference": The starting location is Alert1, 2. This location receives an initial token containing a time list of alarm messages sorted by priority. The location Delay provides a token containing delay information between each protection and circuit breaker. and Each variable is provided with a token, which serves as the initial value for variables i and j, respectively. (Library / Store) Provide a token containing an empty list of states. Transitions Receive tokens from each repository, select the j-th element of the time list, and perform time constraint verification on the (i+j+1)-th element. If the verification is true, add a 1 to the status list; otherwise, add a 0. Repository and changes Provide the variables i and j for iteration, perform loop calculations, and obtain the final list of states, which is stored in the library. China and changes Extract the corresponding time point to obtain the reference time interval and output it to the Timereference library.

[0101] The module "Search time of cause": Alert3 provides a token containing a priority list of alarm timestamps, and the time reference contains the token for the time reference point. (Changes) The system uses a conditional judgment function to verify and calculate the reference time interval of the fault event based on the time distance, and outputs it to the warehouse as the Time of cause.

[0102] The module "Search initial state" provides a token containing a priority list of alarm messages by time. Provide a token as the initial value for variable i, and the Time of cause in the repository contains a reference time interval for the failure event. Transitions The time information and status parameters of the alarm information were extracted separately and then processed through the database. and For change Provided. Changes Based on the time information of each element, determine whether it meets the reference time interval, and assign an initial confidence level to it in conjunction with the state parameters. Output the initial state list of alarm information to the initial state of the repository. The repository's `!drop` and `!drop2` are used to clean up useless tokens.

[0103] As attached Figure 6 As shown, the hierarchical probabilistic inference model of the line is based on the time-constrained intuitionistic fuzzy Petri net for fault diagnosis of distributed networks. The model consists of Layer 1: the protection device layer, which contains multiple protection devices such as protection relays (Lm, Lp, Ls1, Ls2, etc.) and circuit breakers (CBm, CBp, CBs1, CBs2, etc.). These protection devices are responsible for monitoring the electrical parameters of the line and triggering alarms when an anomaly is detected.

[0104] Layer 2: Fault propagation path layer, consisting of multiple fault propagation paths (Road1, Road2, Road3, Road4, etc.). After a fault occurs, it will propagate along these paths. This layer is used to describe the propagation path of the fault in the line.

[0105] Layer 3: Protection Synthesis Probability Layer, containing protection synthesis probability modules (PRM, PRP, PRS, etc.). The function of this layer is to comprehensively process alarm information from the protection device layer and calculate the synthesis probability of protection actions.

[0106] Layer 4: This layer is composed of the probability layer of faulty components. It is directly related to specific faulty components. By analyzing and calculating the information from the previous layers, the probability of each faulty component failing is determined.

[0107] The layers are interconnected by directed arcs. Data and information start from the protection device layer, pass sequentially through the fault propagation path layer and the protection synthesis probability layer, and finally reach the fault element probability layer, realizing the mapping from alarm data to diagnostic results. In addition, the sending and receiving ends of the line are diagnosed separately, and then the diagnostic results are fused and calculated to improve the accuracy of the diagnosis.

[0108] To make the calculation process clear and concise, this embodiment uses matrix operations for probabilistic reasoning and defines the relevant operators and elements: Operator definition: A, B, and C are (m×p), (p×n), and (m×n) dimensional matrices, respectively. , .

[0109] pt1 and pt2 are in the form of tuples, where , , All values ​​are real numbers; meanwhile, a function M(pt1,pt2) is defined to calculate the confidence level, with the following specific form: ; To improve the robustness of the diagnosis, a Gaussian function is introduced and its exponential coefficient is set to 3, i.e. .

[0110] Hierarchical probabilistic reasoning mainly includes the following steps: Initialize the confidence matrix and vector, and establish the confidence matrices I and O for the input arc and output arc of the transition, as well as the initial confidence vector for the place. .

[0111] Calculate and update the confidence vector of the second-level places according to the formula. Calculate and update the confidence vector of the second-level places. .

[0112] Calculate and update the confidence vector of the third-level places using the formula 2. Calculate and update the confidence vector of the third-level places. .

[0113] Calculate and update the confidence vector of the fourth-level places according to the formula. Calculate and update the confidence vector of the fourth-level places. The Gaussian function is used here. Optimize the calculation results.

[0114] Calculate the final confidence level of the faulty component: This is achieved by combining the confidence levels of the fourth-level storage location in probabilistic inference at both the sending and receiving ends, and the fault occurrence time interval in temporal inference, denoted as... and The formula M(pt1,pt2) is used for calculation.

[0115] Through the above hierarchical probabilistic reasoning model and calculation process, line faults can be effectively diagnosed, and the confidence level of each faulty component can be given, providing a basis for accurate fault judgment and handling.

[0116] As attached Figure 7 As shown, a Petri net model for probabilistic inference is built using CPN Tools. The parameters are defined within the dashed boxes. According to Definition 2, the color set, variables, color functions, and other parameters of this model are as follows: Σ={REALT,test_list}, which is the same as the temporal reasoning part.

[0117] V={od1,od2,od3:REALT}, where each variable is used to represent the flow of tokens of the corresponding color type on the arc.

[0118] For any library ∈P, except for the initial state of the treasury, C( =REALT, used to represent the confidence level.

[0119] For any directed arc, E(F) is not fixed and is displayed by EXPR on each arc.

[0120] For any change ∈T, G( `)=true` means that there are no additional logical constraints for each transition, and the guard function is always true.

[0121] The function gua10() is used to synthesize the confidence scores of protection and circuit breakers according to weights, and the function guass() is used to implement the Gaussian function.

[0122] The image shows the warehouse. , , Probability corresponds to Layers 1-4 respectively. The initial state of the storage location serves as the initial state list of alarm information obtained from temporal reasoning, and undergoes transitions. The initial confidence levels of each protection device are allocated and stored in the warehouse. After undergoing changes The confidence levels of the integrated protection and circuit breakers, and the confidence levels of each fault propagation path, are stored in the database. Then through change The maximum confidence level of each fault propagation path is selected as the combined confidence level of the main protection, near backup protection, and far backup protection, and stored in the database. After changes Gaussian calculations are performed on the overall confidence level of each protection, and the maximum value is selected as the final confidence level of the faulty element and stored in the Probability database.

[0123] In S3, the actual faulty component is determined by combining the inference results, and abnormal alarm information is identified. After calculation by the hierarchical probabilistic inference model, the confidence level of each suspected faulty component is obtained.

[0124] A reasonable confidence threshold should be set based on the actual needs and reliability requirements of the system. This threshold can be determined by referring to historical data, engineering experience, and the system's requirements for fault diagnosis accuracy. In this embodiment, the confidence threshold is set to 0.65.

[0125] The confidence level of each suspected faulty component is compared with a set threshold. If the confidence level of a suspected faulty component is greater than the threshold, the component is identified as an actual faulty component. Alarm messages with confidence levels below the confidence threshold are analyzed in conjunction with evaluation indicators to determine the anomaly determination result.

[0126] Evaluation indicators are used to assess the protection equipment and abnormal alarm information involved in the microgrid fault diagnosis process to determine whether there are abnormalities such as maloperation, failure to operate, loss of information, and timing inconsistencies. Specifically: I. Evaluation Indicators for Faulty Components 1. Indicators for judging erroneous actions Prerequisites: The main protection status is 1, which means the main protection has been activated, and the main protection circuit breaker status is 1, which means the main protection circuit breaker has been activated.

[0127] The operation / status of the evaluated protection equipment: backup protection operation or backup protection circuit breaker operation.

[0128] Judgment result: If the above prerequisites and the operation / state of the evaluated protection equipment are met, it is judged as a backup protection malfunction.

[0129] This is because when the main protection and main protection circuit breaker operate normally to clear the fault, the backup protection and its circuit breaker should not operate. If they do, it is considered a false trip, which may expand the scope of the fault's impact and adversely affect the stable operation of the system. For example, when a fault occurs on a transmission line, the main protection quickly trips the corresponding circuit breaker, but the backup protection also falsely trips the circuit breakers of other normal lines. This situation meets the criteria for a false trip.

[0130] 2. Indicators for judging refusal to move Preconditions: ("Main protection status is 0, indicating that the main protection has not operated" or "Main protection circuit breaker status is 0, indicating that the main protection circuit breaker has not operated") and ("Backup protection status is 1, indicating that the backup protection has operated" and "Backup protection circuit breaker status is 1, indicating that the backup protection circuit breaker has operated").

[0131] The operation / status of the evaluated protection equipment: the main protection status is 0 or the main protection circuit breaker status is 0.

[0132] Judgment result: When this condition is met, the main protection is determined to be inactive.

[0133] This means that the main protection should have tripped to clear the fault when it occurred, but failed to do so for some reason, and the fault was cleared by the backup protection. This indicates that the main protection has a failure to operate, which may lead to the fault not being cleared in time and causing greater damage to the system. For example, if a fault occurs in a certain area, and the main protection fails to operate due to equipment failure, but the backup protection trips to clear the fault, then it can be determined that the main protection has failed to operate.

[0134] 3. Missing judgment indicators Preconditions: ("Main protection status is 0" or "Main protection circuit breaker status is 0") and ("Backup protection status is 0" or "Backup protection circuit breaker status is 0").

[0135] The operation / status of the evaluated protection equipment: the main protection status is 0 or the main protection circuit breaker status is 0.

[0136] Judgment result: If this condition is met, it means that the system failed to detect the fault and take corresponding protective measures, that is, the protection information was lost.

[0137] This can cause the fault to persist, threatening the safe and stable operation of the system. For example, if a device malfunctions, but neither the main protection nor the backup protection activates, nor does it issue any corresponding alarm information, it can be determined that the protection information is lost.

[0138] II. Evaluation Indicators for Non-Faulty Components Indicators for judging erroneous actions Preconditions: No specific preconditions, that is, no other complex states are considered, only non-faulty components are considered.

[0139] The operation / status of the evaluated protection device: protection operation or circuit breaker operation.

[0140] Judgment result: For non-faulty components, their corresponding protection devices and circuit breakers should not operate.

[0141] If a protection device or circuit breaker trips, it indicates a malfunction. This could be caused by misjudgment or interference from the protection device, leading to unnecessary power outages or equipment malfunctions. For example, if a normally operating line's protection device suddenly trips the circuit breaker, it can be determined as a malfunction of the protection device.

[0142] III. Evaluation Indicators for All Components Indicators for judging time series inconsistencies Prerequisite: Receiving alarm information from protection or circuit breaker.

[0143] The operation / status of the evaluated protection device: the protection status is 0 or the circuit breaker status is 0.

[0144] Judgment result: When an alarm message is received from a protection device or circuit breaker, but the protection status or circuit breaker status shows that it has not been activated (status is 0), it indicates that the alarm message and the actual equipment status are inconsistent in time.

[0145] This could be due to signal transmission delays, equipment malfunctions, interference, or other reasons, which can affect the accuracy and timeliness of fault diagnosis. For example, if the system receives an alarm message from a protective device, but the actual inspection shows that the device has not activated, this can be identified as an abnormal situation of timing inconsistency.

[0146] Example 2 As attached Figure 8 As shown, the IEEE 14-bus model is used as a reference object, and the time-constrained hierarchical fuzzy color Petri net microgrid fault diagnosis method is used as the experimental scheme, and the existing conventional processing method is used as the control scheme for comparison.

[0147] The contrasting approach uses a time-series hierarchical fuzzy Petri net, directly selecting the timestamp of the first alarm message received by the system as the time reference point for all subsequent alarm messages without verifying its accuracy. Furthermore, the allocation rules for the initial confidence level of the protection devices are too simplistic, directly assigning low confidence levels to protection devices that do not meet the time constraints.

[0148] In the IEEE 14-bus model, For the busbar, Represents transmission lines (i and j represent different busbar labels). Indicates that it is located at The circuit breaker on the side; This indicates the main protection for bus i. and (k=m, p, s) represent the transmission lines at... and Protection on both sides; where m, p, and s represent main protection, near backup protection, and far backup protection, respectively.

[0149] The transmission lines are equipped with main protection, near-end backup protection, and far-end backup protection. The near-end backup protection and main protection control the same circuit breakers. The busbars are equipped with main protection and backup protection. The main protection trips all near-end circuit breakers connected to the busbars, and the backup protection trips the far-end circuit breakers on the lines where circuit breakers that failed to operate. Because the microgrid has multiple distributed power sources, the line protection is divided into sending-end and receiving-end protection. The top left side of the topology is designated as the sending-end, and the other end as the receiving-end.

[0150] A series of fault scenarios were designed for the IEEE 14-bus model. Case 1 is a scenario with complete alarm information but failure to operate and timing errors. Case 2 is a scenario with complete alarm information but false operation, failure to operate, and timing errors. Cases 3 and 4 are scenarios with incomplete alarm information but false operation, failure to operate, and timing errors.

[0151] Therefore, the alarm messages for cases 1-4 are set as follows: case 1: ; Case 2: , .

[0152] Case 3: .

[0153] Case 4: , .

[0154] The suspected faulty components corresponding to each fault scenario are: Case 1: L13-14; Case 2: L13-14, L7-9; Case 3: L4-7, L3-4; Case 4: L4-5, L10-11, L9-10.

[0155] The confidence levels calculated for each failure scenario using the comparison scheme are as follows: Case 1: 0.932; Case 2: 0.927, 0.6; Case 3: 0.923, 0.6; Case 4: 0.927, 0.884, 0.591.

[0156] The confidence levels calculated using this scheme for each fault scenario are as follows: Case 1: 0.983; Case 2: 0.971, 0.164; Case 3: 0.971, 0.164; Case 4: 0.971, 0.884, 0.145.

[0157] The actual faulty components corresponding to each fault scenario are as follows: Case 1: L13-14; Case 2: L13-14; Case 3: L4-7; Case 4: L4-5, L10-11.

[0158] The action evaluations for each fault scenario are as follows: Case 1: , Case 2: , , , , Case 3: , , , , Case 4: , , , , , , .

[0159] Among them, "RO" indicates that the protection device fails to operate; "MO" indicates that the protection device operates erroneously; "MA" indicates that the protection device fails to alarm; and "FT" indicates that the alarm information timestamp is incorrect.

[0160] The diagnostic results demonstrate that the method proposed in this invention can yield correct diagnostic results under various complex conditions. Compared to the control scheme, it has higher confidence in real faulty components and lower confidence in spurious faulty components, resulting in more accurate diagnostic results.

[0161] Taking Case 2 as an example, this paper describes the process of fault diagnosis using this method.

[0162] Based on the received alarm information, wiring analysis revealed that the suspected faulty components were L13-14 and L7-9, represented by s1 and s2 respectively.

[0163] In s1, the associated protections are L(13)-14m, L(13)-14P, L(6)-13s, L(12)-13s, L13-(14)m, L13-(14)p and L(9)-14s.

[0164] The corresponding symbols are represented as: .

[0165] In s1, the circuit breakers associated with it are CB13-14, CB6-13, CB12-13, CB14-13, and CB9-14.

[0166] The corresponding symbols are represented as: .

[0167] In s2, the associated protections are L(7)-9m, L(7)-9p, L(4)-7s, L7-(8)s, L7-(9)m, L7-(9)p, L(4)-9s, L9-(10)s, and L9-(14)s.

[0168] The corresponding symbols are represented as: .

[0169] In s2, the circuit breakers associated with it are CB7-9, CB4-7, CB8-7, CB9-7, CB4-9, CB10-9, and CB14-9.

[0170] The corresponding symbols are represented as: .

[0171] Therefore, a set of sending and receiving protection devices is established for each suspected faulty component. Protection devices that receive corresponding alarm information are assigned a timestamp; those that do not receive an alarm are assigned a timestamp of 0, resulting in a set of protection devices with timestamps. The elements in this set of timestamped protection devices are then arranged in priority order and used as initial tokens input into the temporal inference Petri net model, where both the sending and receiving ends of the same suspected faulty component are inferred simultaneously.

[0172] The set of timestamped protection devices for s1 is as follows: Sending end (s). , .

[0173] Receiving end (r) , .

[0174] The set of timestamped protection devices for S2 is as follows: Sending end (s). , .

[0175] Receiving end (r) , .

[0176] The temporal reasoning result of s1 is: Time reference point (ms), sender 2, receiver 985; Fault reference time interval (ms), sending end (-38, -8), receiving end (-85, 35); The initial confidence level of the protection device is [0.2,0.2,0.2,0.2,0.7,0.95,0.7,0.95] for the sending end and [0.9,0.95,0.2,0.0006,0.2,0.2] for the receiving end.

[0177] The temporal reasoning result of s2 is: Time reference point (ms), sender 210, receiver (empty); Fault reference time interval (ms), sending end (-130, -50), receiving end (empty); The initial confidence level of the protection device is [0.2,0.2,0.8,0.2,0.2,0.2,0.2,0.2,0.2] for the sending end and [0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2,0.2].

[0178] An initial confidence vector for the protection device is established based on the results of temporal inference. The token is then used as the initial token and input into the hierarchical probabilistic inference model to obtain the failure confidence of the suspected faulty component.

[0179] The diagnostic results for S1 were: a confidence level of 0.982 for the sending end and 0.902 for the receiving end.

[0180] The S2 diagnostic results were: sender confidence level 0.507 and receiver confidence level 0.147.

[0181] Combining the diagnostic results from the sending and receiving ends of the components, the final confidence levels of s1 and s2 are: M((0.982,(-38,-8)),(0.902,(-85,35)))=0.971 and M((0.507,(-130,-50)),(0.147,∅))=0.164, respectively. Since the confidence level of s1 is greater than 0.65 and the confidence level of s2 is less than 0.65, s1 is the actual faulty component.

[0182] The above descriptions are merely embodiments of the present invention, and common knowledge such as specific technical solutions and / or characteristics are not described in detail here. It should be noted that those skilled in the art can make various modifications and improvements without departing from the technical solutions of the present invention, and these should also be considered within the scope of protection of the present invention. These modifications and improvements will not affect the effectiveness of the implementation of the present invention or the practicality of the patent. The scope of protection claimed in this application should be determined by the content of its claims, and the specific embodiments described in the specification can be used to interpret the content of the claims.

Claims

1. A fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints, characterized in that, include: S1. Obtain alarm information from protection devices and circuit breakers at all levels, and determine suspected faulty components based on alarm information, microgrid topology, and protection configuration information using the wiring analysis method; S2. Construct temporal reasoning and probabilistic reasoning models for each suspected faulty component, and use bidirectional temporal reasoning to verify the alarm information timestamp and assign an initial confidence level. S3. Based on hierarchical weighted fuzzy Petri net, perform probabilistic reasoning, combine the reasoning results to determine the actual faulty components and find abnormal alarm information; In S2, the time reference point is inferred based on the priority sequence of each suspected faulty component and the time constraint conditions, and the confidence level of alarm information that does not meet the time constraint is attenuated by a Gaussian function according to the time distance.

2. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 1, characterized in that: S2 specifically involves receiving alarm information, establishing a priority sequence based on the action times of the protection device and the circuit breaker, and using time constraints and the priority sequence to filter time reference points from the alarm information time list. Based on a determined time reference point and time constraints, the fault time interval in which the fault occurred is inferred. Furthermore, based on time constraints, the action delay information of protection and circuit breakers at all levels, the reference time interval of protection and circuit breakers is further inferred. Compare the actual protection time point and circuit breaker time point with the reference time interval derived from reasoning to make a judgment; If the actual time point is within the reference time interval, then set a high confidence level for the corresponding protection device; If the actual time point is not within the reference time interval, the confidence level is assigned using a Gaussian decay function based on the difference between its timestamp and the reference time interval.

3. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 2, characterized in that: In step S2, for protection devices that receive alarm information but whose actual time point is not within the reference time interval, the confidence level calculation formula is as follows: ; ; ; in, To protect the confidence level of the equipment; The confidence level when the alarm information from the protection device is received and the time constraint is met; Its timestamp The minimum absolute value at the boundary of the reference time interval T(a), and These represent the lower and upper limits of the time interval, respectively; σ is the tolerance for time difference, and σ is half the length of the reference time interval T(a).

4. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 3, characterized in that: In S2, during the priority sequence sorting, the earlier the action time, the higher the priority of the corresponding protection device.

5. The method for fault diagnosis of a layered fuzzy color Petri net microgrid considering time constraints according to claim 4, characterized in that: A bidirectional temporal inference model and a hierarchical probabilistic inference model were constructed using CPN Tools; The modular construction of the temporal inference model includes a time reference point inference module, a fault time interval inference module, and an initial assignment module; The time reference point reasoning module is responsible for time reference point reasoning. It starts by receiving a list of alarm information time information sorted by priority from the initial library, combines the library of delay information of each protection and circuit breaker, and the library that provides iterative variables, performs time constraint verification and iterative calculation through transitions, and finally outputs the time reference point. The fault time interval reasoning module is responsible for fault time interval reasoning. Based on the time reference point library and the alarm information time list library, it calculates the reference time interval of the fault event through transitions and outputs it. The initial assignment module is responsible for the inference and verification of the reference time interval of protection and circuit breakers. By extracting the alarm information time and status parameters, combining them with the fault event reference time interval database, and after transition judgment and assigning initial confidence, it outputs the initial state list of alarm information. The transitions within the module include conditional judgments, time calculations, and confidence assignments. The parameter definition section includes time delays, variable declarations, and function declarations.

6. The method for fault diagnosis of a layered fuzzy color Petri net microgrid considering time constraints according to claim 5, characterized in that, Hierarchical probabilistic inference models include: The protection device layer includes multiple protection device locations, receives an initial state list of alarm information output by time-series inference, and assigns initial confidence levels through transitions; The fault propagation path layer includes multiple fault propagation path libraries. The confidence level of each fault propagation path is obtained by transitioning the confidence level of the protection and circuit breaker. The protection composite probability layer, including the protection composite probability module, selects the maximum confidence of each fault propagation path through transitions, which serves as the comprehensive confidence of the main protection, near backup protection, and far backup protection. The fault element probability layer performs Gaussian calculations on the overall protection confidence level through transitions, selects the maximum value as the final confidence level of the fault element, and outputs it. The layers are connected by directed arcs. Data flows sequentially from the protection device layer to the fault component probability layer. The parameter definition section includes color sets, variables, and Gaussian function declarations. The transitions within the module include confidence synthesis, Gaussian calculation, and maximum value selection.

7. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 6, characterized in that: In step S3, the confidence level of each suspected faulty component is compared with a set threshold. If the confidence level of a suspected faulty component is greater than the threshold, the component is identified as an actual faulty component. Alarm information with a confidence level lower than the confidence level threshold is combined with evaluation indicators to make judgments and analyze and find the abnormal judgment results.

8. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 7, characterized in that: Evaluation indicators include indicators for judging erroneous operation, indicators for judging refusal to operate, indicators for judging loss, and indicators for judging inconsistency in timing. The criteria for judging maloperation include fault models and non-fault models. The prerequisite for faulty components is the status and operation of the main protection and the main protection circuit breaker. The operation / status of the protection equipment being evaluated for the faulty component is the operation of the backup protection or the operation of the backup protection circuit breaker. There are no prerequisites for non-faulty models. The operation / status of the protection equipment being evaluated for non-faulty models is the operation of the protection or the operation of the circuit breaker. The failure to operate judgment index is judged on the faulty component. The prerequisite is that the main protection / main protection circuit breaker does not operate and the backup protection operates, or the backup protection circuit breaker operates. The operation / state of the protected equipment being evaluated is that the main protection / main protection circuit breaker does not operate. The missing judgment index is judged as a faulty component. The prerequisite is that the main protection / main protection circuit breaker has not operated and the backup protection / backup protection circuit breaker has not operated. The operation / status of the protected equipment being evaluated is that the main protection / main protection circuit breaker has not operated. The timing inconsistency judgment index judges all components. The prerequisite is that an alarm message from the protection / circuit breaker is received, and the action / status of the evaluated protection device is that the protection or circuit breaker has not acted.

9. The method for fault diagnosis of a layered fuzzy color Petri net microgrid considering time constraints according to claim 8, characterized in that: In step S2, the low confidence level for protection devices that do not receive corresponding alarm information is set to 0.2; A high confidence level is set for protection devices that receive alarm information and meet the time constraints. Specifically, the confidence level is 0.9 for the main protection device, 0.8 for the near backup protection device, 0.7 for the far backup protection device, and 0.95 for the circuit breaker device.

10. The fault diagnosis method for a layered fuzzy color Petri net microgrid considering time constraints according to claim 9, characterized in that: The priority sequence of S2, from high to low, is as follows: main protection, main protection circuit breaker, near backup protection, near backup protection circuit breaker, far backup protection, and far backup protection circuit breaker.