Cascade simulation method and system for multiple real-time simulation machines
Through the segmentation, decoupling and signal synchronization mechanism of the electrical steady-state model, the cascade simulation of multiple real-time simulators is realized, which solves the problem of insufficient computing power of a single real-time simulator and the convergence of asynchronous simulation, and realizes microsecond operation of large-scale power supply systems. Level simulation and flexible expansion of the simulation platform.
Patent Information
- Application Number
- CN202410689370.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-30
- Publication Date
- 2024-09-06
AI Technical Summary
The existing single real-time simulation machine has insufficient computing power when simulating large-scale power supply systems and cannot meet microsecond-level simulation requirements. The lack of effective asynchronous joint simulation methods makes it difficult to expand the simulation test platform.
By segmenting and decoupling the electrical steady-state model, a communication connection is established between the real-time simulator host and slave machines. A signal synchronization mechanism is used to ensure that the model enters the cascade operating state after stabilization. Reflective memory cards and optical fiber lines are used to achieve high-speed data exchange. , ensuring that the model converges during initial runs and avoids the impact of legacy historical data.
Real-time simulation of the electrical steady-state model of large-scale power supply systems in microsecond-level simulation steps is realized, which facilitates expansion of the simulation platform, avoids convergence problems when the model is started and simulation distortion caused by external electromagnetic interference, and improves simulation accuracy and stability. sex.
Smart Images

Figure CN118607208A
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of rail vehicles, and in particular relates to a multi-real-time simulator cascade simulation method and system. Background Art
[0002] The common lines of the existing AC and DC power supply systems of urban rail transit usually have more than 10 stations, and the network topology is complex. When conducting semi-physical simulation experiments on large-scale power supply systems with more than 10 traction stations, the real-time simulation of large-scale power supply systems can only run at the millisecond level due to the limited CPU computing resources of a single real-time simulator. However, engineering applications require that the real-time simulation of the power supply system run at least at the microsecond level, so the computing power of a single real-time simulator is not enough to meet the requirements of real-time operation of large-scale, long-distance power supply system simulation models at the microsecond level.
[0003] Although the use of multiple real-time target machines for combined computing can theoretically improve computing power and reduce the real-time simulation step to the microsecond level, due to the lack of effective and feasible asynchronous joint simulation implementation methods, the model will diverge due to computing anomalies after startup, making it difficult to expand the scale of the simulation test platform. Summary of the invention
[0004] The purpose of the present invention is to solve one of the above technical problems and to provide a multi-real-time simulation machine cascade simulation method and system.
[0005] To achieve the above object, the technical solution adopted by the present invention is:
[0006] A multi-real-time simulation machine cascade simulation method comprises the following steps:
[0007] S1: Segment and decouple the electrical steady-state model to obtain a host model and at least one slave model;
[0008] S2: deploying the host model to the real-time simulation machine host, and correspondingly deploying at least one slave model to at least one real-time simulation machine slave;
[0009] S3: Establishing a communication connection between the real-time simulation machine host and the real-time simulation machine slave;
[0010] S4: Start the host model and the slave model, and perform signal synchronization on the host model and the slave model;
[0011] The method for performing signal synchronization comprises the following steps:
[0012] S41: Setting the stability judgment standard of the host model and the slave model;
[0013] S42: When the model is started, the host model and the slave model transmit 0 values to each other and judge stability based on their respective stability judgment standards. After each of them is judged to be stable, the host model judges stability as a whole based on the stability status of each model;
[0014] S43: After the host model determines that all models are stable, it starts the interactive mode and simultaneously sends an interactive start signal to at least one slave model; the slave model starts the interactive mode after receiving the interactive start signal;
[0015] S5: After the host model and the slave model perform signal synchronization, each real-time simulation machine enters a cascade operation state, performs simulation calculations separately, and transmits related model calculation values to each other.
[0016] In some embodiments of the present invention, step S41 specifically includes the following steps:
[0017] Determine at least one predetermined parameter as a criterion for determining whether the model is stable; respectively set a steady-state determination interval and a predetermined time threshold of the predetermined parameter in the host model and the slave model;
[0018] Alternatively, the steady-state determination value and the predetermined time threshold of the predetermined parameter in the master model and the slave model are respectively set.
[0019] In some embodiments of the present invention, the predetermined parameter is a grid voltage.
[0020] In some embodiments of the present invention, the method for determining stability of the host model and the slave model based on their respective stability determination criteria in step S42 includes:
[0021] After the host model or the slave model is started, when the predetermined parameters of the model are within the steady-state determination interval and the duration reaches the predetermined time threshold,
[0022] Alternatively, when a predetermined parameter of the model is below a steady-state determination value and the duration reaches a predetermined time threshold, the model is determined to be running stably;
[0023] Otherwise, it is determined that the model is not stable or the model is unstable.
[0024] In some embodiments of the present invention, the electrical steady-state model includes a traction substation model; the method for segmenting and decoupling the electrical steady-state model in step S1 includes the following steps:
[0025] Electrical decoupling is achieved between the AC side and the DC side of the traction substation model through an electrical decoupling module composed of a controlled voltage source and / or current source, and the electrical connecting lines are replaced by mutually transmitting voltage and current values.
[0026] In some embodiments of the present invention, step S3 specifically includes the following steps:
[0027] A reflective memory card is configured in the real-time simulator host and the real-time simulator slave, and the real-time simulator host and the real-time simulator slave are connected by an optical fiber line.
[0028] In some embodiments of the present invention, step S5 further includes the following steps:
[0029] The start flag is set in the host model and the slave model. When each real-time simulation machine enters the cascade operation state, the start flag is set to 1 to record the start time of the simulation calculation.
[0030] In some embodiments of the present invention, step S1 further includes the following steps:
[0031] An electrical steady-state model is built in MATLAB / Simullink software. The electrical steady-state model is used to perform pure digital simulation of the rail transit AC / DC power supply system.
[0032] Some embodiments of the present invention further provide a multi-real-time simulation machine cascade simulation system, comprising: a real-time simulation machine host and at least one real-time simulation machine slave;
[0033] The real-time simulation machine host includes a host model and a synchronization signal trigger, the host model is used to perform real-time simulation calculations, and the synchronization signal trigger is used to achieve signal synchronization between the real-time simulation machine host and the real-time simulation machine slave;
[0034] The real-time simulation machine slave and the real-time simulation machine host are cascaded and run, and at least include a slave model. The slave model and the host model are obtained by splitting and decoupling the same electrical steady-state model, and are used for real-time simulation calculations and for transmitting model calculation values to and from the host model.
[0035] In some embodiments of the present invention, both the real-time simulator host and the real-time simulator slave include a reflective memory card, and the reflective memory cards in each real-time simulator are interconnected via an optical fiber line for data transmission and reception.
[0036] The beneficial effects of the present invention are:
[0037] 1. The simulation method provided by the present invention can perform real-time simulation on the electrical steady-state model of a large-scale power supply system including multiple traction substations, so that the real-time simulation of the large-scale power supply system can be run at a microsecond simulation step, and it is convenient for simulation platform developers to flexibly expand the simulation platform according to the actual number of stations, and more conveniently and quickly access new equipment;
[0038] 2. The simulation method provided by the present invention solves the problem of the direct interaction of the model at the initial simulation startup and the inability of the entire model to converge by setting a signal synchronization mechanism. At the same time, it avoids the impact of the historical data left in the reflection memory card on the initial operation of the model when the model is restarted after being stopped, and ensures that the model can be started and run normally after cascading;
[0039] 3. The present invention uses a reflective memory card to realize the interconnection of simulation machines and transmits signals through optical fiber. Compared with the interaction method through communication protocol or physical IO in the prior art, the interaction speed is improved, and the interaction speed is not affected by the amount of data. The transmitted values are accurate, the real-time simulation accuracy is improved, and the simulation distortion or instability caused by external electromagnetic interference is avoided. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the specific embodiments of the present invention will be described in detail below in conjunction with the accompanying drawings. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0041] Figure 1 It is a flow chart of the cascade simulation method of multiple real-time simulators;
[0042] Figure 2 The cascade simulation startup flow chart provided by the present invention;
[0043] Figure 3 It is a structural diagram of a multi-real-time simulation machine cascade simulation system. DETAILED DESCRIPTION
[0044] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application is described and illustrated below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. Based on the embodiments provided in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.
[0045] It should be noted that the terms used herein are only for describing specific embodiments and are not intended to limit the exemplary embodiments according to the present application. As used herein, unless the context clearly indicates otherwise, the singular form is also intended to include the plural form. In addition, it should be understood that the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0046] In the absence of conflict, the embodiments of the present invention and the features of the embodiments may be combined with each other.
[0047] The technical solution of the present invention is described in detail below in conjunction with specific embodiments and the accompanying drawings.
[0048] As attached Figure 1-2 As shown, in an illustrative embodiment of a multi-real-time simulator cascade simulation method of the present invention, the simulation method is used to model and simulate the AC and DC power supply system of urban rail transit, and is used to consider the steady-state and dynamic responses of the power system under different conditions. The simulation method includes the following steps.
[0049] S1: In order to distribute the electrical steady-state model to at least two real-time simulation machines for operation, the electrical steady-state model is segmented and cored, and the electrical steady-state model is decomposed into several sub-models, wherein each sub-model is responsible for simulating a part of the entire power supply system, and the sub-model includes a host model and at least one slave model.
[0050] In some embodiments of the present invention, step S1 further includes the following steps.
[0051] An electrical steady-state model is built through the standard model library in the MATLAB / SimPowerSystems extension toolbox. The electrical steady-state model is used for pure digital simulation of the rail transit AC / DC power supply system, including a 110KV AC power supply model, a main transformer model, a traction substation model, a power supply section model, and a vehicle load model. The traction substation model includes a traction transformer model, a rectifier unit model, a PWM bidirectional converter model, etc.
[0052] In some embodiments of the present invention, the method for segmenting and decoupling the electrical steady-state model in step S1 includes the following steps.
[0053] Electrical decoupling is achieved between the AC side and the DC side of the traction substation model through an electrical decoupling module composed of a controlled voltage source and / or current source. The electrical connecting lines are replaced by mutually transmitting voltage and current values, so that data interaction can be achieved between stations by transmitting signals to each other.
[0054] S2: deploy the host model to the real-time simulation machine host Master, and deploy at least one slave model S l aver to at least one real-time simulation machine slave.
[0055] S3: Establish a communication connection between the real-time simulation machine host Master and the real-time simulation machine slave S l aver.
[0056] In some embodiments of the present invention, step S3 specifically includes the following steps:
[0057] A reflective memory card is configured in the real-time simulator host and the real-time simulator slave, and the real-time simulator host and the real-time simulator slave are connected by an optical fiber line. By using the reflective memory card and the optical fiber line together, a high-speed and reliable communication connection is established, which provides a guarantee for data exchange between models.
[0058] S4: At the beginning of the simulation test, the real-time simulation machine host and the real-time simulation machine slave must be powered on first. After powering on, the host model and the slave model are started, and the signals of the host model and the slave model are synchronized.
[0059] It should be noted that when the host model and the slave model are initialized and started, the model has a convergence process. If data interaction is performed directly, since asynchronous simulation is performed between multiple real-time simulation machines, it is easy to cause model operation abnormality or runaway. It is necessary to automatically determine that the model is stable before starting data interaction; in addition, the reflective memory card has the characteristic of data retention, that is, when the model stops running, the data in the reflective memory card remains as the operation value when the model is terminated, and only by powering off the board can the data be cleared to 0. After completing a simulation test and stopping the model, when the model is restarted next time, the initial value of the corresponding position of the model is the legacy value when the model was terminated last time. At this time, due to the abnormal initial value (the initial value of the AC side operation must be a three-phase AC value or a 0 value, otherwise the model operation is wrong), the slave model runs away, and the error data is transmitted to the host, which also causes the host model operation abnormality. Therefore, the present invention adds a signal synchronization module in the model, performs signal synchronization when the model is started, clears the data in the reflective memory to 0, so that the interaction data is 0, to ensure that each real-time simulation machine does not affect each other during the convergence process of the initial operation.
[0060] The specific process of the signal synchronization interaction mechanism is as follows: Figure 2 As shown, the following steps are included.
[0061] S41: Setting the stability criteria of the master model and the slave model.
[0062] In some embodiments of the present invention, step S41 specifically includes the following steps:
[0063] In the early stage of model building, at least one steady-state value is determined as a predetermined parameter based on model building experience, and the predetermined parameter is used as a criterion for judging whether the model is stable;
[0064] Since the grid voltage is a key parameter in the power system and its stability is directly related to the safe operation of the power system, in this embodiment, the grid voltage of the power supply system is determined as a predetermined parameter.
[0065] The steady-state determination interval and the predetermined time threshold of the predetermined parameters in the host model and the slave model are respectively set.
[0066] Alternatively, the steady-state determination value and the predetermined time threshold of the predetermined parameter in the master model and the slave model are set respectively.
[0067] According to experience, the network voltage of the host model is between 1500V and 1800V, and the network voltage of the slave model is near 0. Therefore, the model stability judgment value is set differently in the host model and the slave model according to the actual situation. In this embodiment, the steady-state judgment value of the host model is set to 2000V, and the predetermined time threshold is 10s; the steady-state judgment value of the slave model is set to 100V, and the predetermined time threshold is 10s.
[0068] S42: When the model starts, the host model and the slave model transmit 0 values to each other, and both receive and send data are initialized to 0, prohibiting data interaction. At this time, the host model is equivalent to a short-distance power supply network, and the slave model is equivalent to a circuit topology that is not connected to a 35KV AC network. In addition, the host model and the slave model are judged to be stable based on their respective stability judgment standards. After the model is stable, the stability flag bits in the host model and the slave model are set to 1, and the slave model sends the stability flag bit to the host through the reflective memory. The host model performs overall stability judgment based on the stability status of each slave model and itself.
[0069] Specifically, in step S42, the method for determining stability by the host model and the slave model based on their respective stability determination criteria includes the following steps.
[0070] After the host model or the slave model is started, when the predetermined parameters of the model are within the steady-state determination interval and the duration reaches the predetermined time threshold,
[0071] Alternatively, when a predetermined parameter of the model is below a steady-state determination value and the duration reaches a predetermined time threshold, it is determined that the model is running stably.
[0072] That is, if the grid voltage of the host model is stable at no more than 2000V and lasts for more than 10s, the host model is deemed to be operating stably; if the grid voltage of the slave model is stable at no more than 100V and lasts for more than 10s, the slave model is deemed to be operating stably.
[0073] Otherwise, it is determined that the model is not stable or the model is unstable.
[0074] S43: After the host model determines that all models are stable, that is, after the host model determines that the steady-state flags of all host and slave models are 1, the host model starts the interactive mode, activates the interactive started state signal, and transmits the interactive started state to the slave model through the reflective memory card. After the slave model receives the host interactive started state, it starts the interactive mode synchronously. At this point, both the host and slave models are switched to the interactive mode, and can start to transmit the relevant model calculation values through the reflective memory card.
[0075] S5: After the host model and the slave model synchronize their signals, each real-time simulation machine enters the cascade operation state and performs simulation calculations separately. The host model transmits the voltage and current signals to the slave model and receives the voltage and current data sent by the slave model. The slave model transmits the voltage and current signals to the host model and receives the voltage and current data sent by the host model. The joint operation of each part is realized by calculating the intermediate values between each model.
[0076] In some embodiments of the present invention, step S5 further includes the following steps.
[0077] The start flag is set in the host model and the slave model. When each real-time simulation machine enters the cascade operation state, the start flag is set to 1 to display and record the start time of the simulation calculation, which is helpful for monitoring and management of the simulation process.
[0078] After the simulation calculation is completed, the model needs to be stopped. When the model needs to be restarted, each model can be started directly without powering off the real-time simulation machine to clear the remaining values in the reflective memory card.
[0079] Through the multi-real-time simulation machine cascade simulation method provided by the present invention, the entire power supply system circuit is modularly divided and decoupled, so that the power supply system can be divided into multiple parts, and the joint operation of the parts is realized by mutual transmission of intermediate values between the parts. It is the basis for realizing cascade data interaction between multiple real-time simulation machines. At this time, it is only necessary to distribute the modularly divided models to multiple real-time simulation machines, transmit the decoupling module interaction signals between the simulation machines through the reflection memory card, and design the corresponding initial value and signal synchronization mechanism to synchronize the initial value of the signal, so as to realize the cascade operation of the real-time simulation machines, and finally realize the cascade simulation of multiple simulation machines of large-scale power supply systems.
[0080] Furthermore, according to the number of substations in the power supply system, it is only necessary to clarify the correspondence between the maximum computing power of a single simulation machine and the number of substations on the basis of the existing power supply system, add more cascade simulation machine devices, and each device is equipped with a reflective memory card. The synchronization signal is sent by the host to multiple slaves at the same time, so that the circuit topology in multiple devices can be synchronized to the network, and a larger-scale power supply system simulation can be achieved.
[0081] Some embodiments of the present invention further provide a multi-real-time simulation machine cascade simulation system, the simulation system structure is as shown in the attached Figure 3 As shown, it includes a real-time simulator host and at least one real-time simulator slave.
[0082] The real-time simulation machine host includes a host model and a synchronization signal trigger. The host model is used to perform real-time simulation calculations, and the synchronization signal trigger is used to achieve signal synchronization between the host and the slave when the host model is started.
[0083] The real-time simulation machine slave and the real-time simulation machine host are cascaded and run, including a slave model. The slave model and the host model are obtained by segmenting and decoupling the same electrical steady-state model, and are used for real-time simulation calculations and mutually transmitting model calculation values with the host model.
[0084] In some embodiments of the present invention, both the real-time simulator host and the real-time simulator slave include a reflective memory card, and the reflective memory cards in each real-time simulator are interconnected via an optical fiber line for data transmission and reception.
[0085] Finally, it should be noted that: the various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0086] The above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, ordinary technicians in the field should understand that the specific implementation methods of the present invention can still be modified or some technical features can be replaced by equivalents without departing from the spirit of the technical solution of the present invention, which should be included in the scope of the technical solution for protection of the present invention.
Claims
1. A multi-real-time simulation machine cascade simulation method, characterized in that: The following steps are involved: S1: Segment and decouple the electrical steady-state model to obtain a host model and at least one slave model; S2: deploying the host model to the real-time simulation machine host, and correspondingly deploying the at least one slave model to at least one real-time simulation machine slave; S3: Establishing a communication connection between the real-time simulation machine host and the real-time simulation machine slave; S4: Start the host model and the slave model, and perform signal synchronization on the host model and the slave model; The method for performing signal synchronization comprises the following steps: S41: Setting the stability judgment standard of the host model and the slave model; S42: When the model is started, the host model and the slave model transmit 0 values to each other and judge stability based on their respective stability judgment standards. After each of them is judged to be stable, the host model judges stability as a whole based on the stability status of each model; S43: After the host model determines that all models are stable, it starts the interactive mode and simultaneously sends an interactive start signal to at least one slave model; after receiving the interactive start signal, the slave model synchronously starts the interactive mode; S5: After the host model and the slave model perform signal synchronization, each real-time simulation machine enters a cascade operation state, performs simulation calculations separately, and transmits related model calculation values to each other.
2. The multi-real-time simulation machine cascade simulation method according to claim 1, characterized in that: Step S41 specifically includes the following steps: Determining at least one predetermined parameter as a criterion for determining whether the model is stable; respectively setting the steady-state determination interval and the predetermined time threshold of the predetermined parameter in the host model and the slave model, Alternatively, the steady-state determination value and the predetermined time threshold of the predetermined parameter in the master model and the slave model are set respectively.
3. The multi-real-time simulation machine cascade simulation method according to claim 2, characterized in that: The predetermined parameter is the grid voltage.
4. The multi-real-time simulation machine cascade simulation method according to claim 2 or 3, characterized in that: In S42, the master model and the slave model perform stability determination based on their respective stability determination criteria, including: After the host model or the slave model is started, when the predetermined parameters of the model are within the steady-state determination interval and the duration reaches the predetermined time threshold, Alternatively, when a predetermined parameter of the model is below a steady-state determination value and the duration reaches a predetermined time threshold, the model is determined to be running stably; Otherwise, it is determined that the model is not stable or the model is unstable.
5. The multi-real-time simulation machine cascade simulation method according to claim 1, characterized in that: The electrical steady-state model includes a traction substation model; the method for segmenting and decoupling the electrical steady-state model in step S1 includes the following steps: Electrical decoupling is achieved between the AC side and the DC side of the traction substation model through an electrical decoupling module composed of a controlled voltage source and / or current source, and electrical connecting lines are replaced by mutually transmitting voltage and current values.
6. The multi-real-time simulation machine cascade simulation method according to claim 1, characterized in that: Step S3 specifically includes the following steps: A reflective memory card is configured in the real-time simulator host and the real-time simulator slave, and the real-time simulator host and the real-time simulator slave are connected by an optical fiber line.
7. The multi-real-time simulation machine cascade simulation method according to claim 1, characterized in that: Step S5 further comprises the following steps: A start flag is set in the host model and the slave model. When each real-time simulation machine enters the cascade operation state, the start flag is set to 1 to record the start time of the simulation calculation.
8. The multi-real-time simulation machine cascade simulation method according to claim 1, characterized in that: Step S1 further comprises the following steps: An electrical steady-state model is built in MATLAB / Simulink software, and the electrical steady-state model is used to perform pure digital simulation of the rail transit AC and DC power supply system.
9. A multi-real-time simulator cascade simulation system, used to implement the multi-real-time simulator cascade simulation method according to any one of claims 1 to 8, characterized in that: include: A real-time simulator host and at least one real-time simulator slave; The real-time simulation machine host includes a host model and a synchronization signal trigger, wherein the host model is used to perform real-time simulation calculations, and the synchronization signal trigger is used to achieve signal synchronization between the real-time simulation machine host and the real-time simulation machine slave; The real-time simulation machine slave and the real-time simulation machine host are cascaded and run, and at least include a slave model. The slave model and the host model are obtained by splitting and decoupling the same electrical steady-state model, and are used to perform real-time simulation calculations and transmit model calculation values to and from the host model.
10. The multi-real-time simulation machine cascade simulation method according to claim 9, characterized in that: The real-time simulation machine host and the real-time simulation machine slave both include a reflective memory card, and the reflective memory cards in each real-time simulation machine are interconnected through an optical fiber line for data transmission and reception.
