A Distributed Real-Time Interactive Simulation Method and System

By using a distributed real-time interactive simulation method, multiple sub-simulation systems and a distributed data pool are created, which solves the problem of unified management of simulation systems in complex task scenarios, realizes efficient virtual-real fusion and simulation result interaction, and improves the accuracy and scalability of the simulation system.

CN116227115BActive Publication Date: 2026-11-17NO 719 RES INST CHINA SHIPBUILDING IND
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202211493705.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-25
Publication Date
2026-11-17
Estimated Expiration
2042-11-25

AI Technical Summary

Technical Problem

Existing technologies struggle to achieve virtual-real fusion and efficient porting of simulation experiments and training in complex task scenarios, especially in large-scale, high-intensity, heterogeneous multi-node simulation systems, where there is a lack of unified simulation model lifecycle management and data sharing mechanisms.

Method used

A distributed real-time interactive simulation method is adopted. By creating multiple sub-simulation systems, establishing a distributed data pool and a joint simulation configuration table, setting time parameters, controlling the behavior of the sub-simulation systems, and using a two-dimensional table structure to store and index data, the simulation results can be interacted and managed.

Benefits of technology

It enables unified management of large-scale, high-intensity, heterogeneous multi-node simulation systems, improves simulation accuracy and scalability, simplifies the design and maintenance of simulation systems, and supports "building block" construction and virtual-real combined simulation systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116227115B_ABST
    Figure CN116227115B_ABST
Patent Text Reader

Abstract

This invention discloses a distributed real-time interactive simulation method and system, relating to the field of distributed simulation technology. The method includes: creating a distributed simulation system composed of multiple sub-simulation systems and acquiring simulation data packets for each sub-simulation system; creating a distributed data pool, a joint simulation configuration table, and setting time parameters; after simulation begins, acquiring the required data for each sub-simulation system from the distributed data pool; controlling each sub-simulation system according to the simulation data packets and the required data, combined with the time parameters and the joint simulation configuration table, so that each sub-simulation system outputs simulation results; and placing the simulation results into the distributed data pool as the basis for data interaction among the multiple sub-simulation systems. This invention provides the capability to support large-scale, high-intensity, heterogeneous multi-node, and full-process simulation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of distributed simulation modeling technology, and more specifically, relates to a distributed real-time interactive simulation architecture method and system. Background Technology

[0002] Distributed interactive simulation is an advanced simulation technology that has been developed in recent years. It is a simulation based on computer networks. It is mainly used to integrate geographically dispersed, multi-physical input system coupled training simulators, training environments, and trainees into a logical whole. This enables the information and data of various dimensions in complex training scenarios to be expressed more scientifically, rigorously, uniformly, and clearly, thereby realizing simulation experiments and exercises involving multiple systems, devices, environments, and personnel.

[0003] Real-time simulation refers to a type of simulation where the time scale of the simulation model is equal to the time scale of the original system model. Real-time simulation is mainly used in simulation systems with physical objects or people, because physical objects and people change and move according to real time. Real-time simulation systems can receive real-time dynamic inputs and generate real-time dynamic outputs, and the inputs and outputs usually have a fixed sampling time interval.

[0004] Distributed real-time simulation combines the characteristics of distributed and real-time systems, significantly simplifying the complexity of large-scale system modeling and the design of simulation systems. Each subsystem only needs to be modeled and simulated based on its own physical characteristics and according to the clock frequency given by the large system, without needing to concern itself with the global coupling and correlation of the large system. Through a computer network, under the control of a unified time tick, the simulation platform itself manages, interacts, and controls the various subsystems, thereby achieving the simulation of the large system.

[0005] Furthermore, the organization and management of distributed real-time simulation models are closest to those of real physical systems, resulting in simulation accuracy that closely approximates physical reality, offering high precision and a wide simulation range. Another advantage of distributed systems is their strong maintainability and scalability. Faulty or inaccurate simulation nodes can be quickly located; adding new simulation nodes or replacing them with physical nodes is also easier, enabling the rapid construction of "building block" simulation systems or hybrid hardware-in-the-loop (HIL) simulation systems. Summary of the Invention

[0006] To address the need for efficient and seamless integration of virtual and real-world simulation experiments and training in complex task scenarios, this invention provides a distributed real-time interactive simulation method and system. Based on general-purpose computer networks, this method and system integrates time-slice-oriented real-time modeling algorithms, overcoming the challenges of integrated development, operation, management, and control technologies for simulation experiment systems. It achieves a refined, open, human-in-the-loop digital simulation system, capable of supporting large-scale, high-intensity, heterogeneous multi-node, and full-process simulations.

[0007] This invention provides a distributed real-time interactive simulation method, comprising:

[0008] Create a distributed simulation system consisting of multiple sub-simulation systems, and obtain the simulation data package of each sub-simulation system;

[0009] Create a distributed data pool, configure a co-simulation table, and set time parameters;

[0010] Once the simulation begins, the required data for each sub-simulation system is obtained from the distributed data pool. Based on the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, each sub-simulation system is controlled to output simulation results.

[0011] The simulation results are placed into the distributed data pool, serving as the basis for data interaction among the multiple sub-simulation systems.

[0012] Furthermore, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0013] Furthermore, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file.

[0014] The simulation model file defines the behavior of the sub-simulation system;

[0015] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0016] Furthermore, setting the time parameters includes setting one or more of the following: clock period, number of beats, and / or clock state.

[0017] Furthermore, setting the clock period includes: setting the duration of a single simulation;

[0018] Setting the number of ticks includes: the number of ticks starts counting from 1, the value of the number of ticks is incremented by 1 every clock cycle, and each of the sub-simulation systems is notified through the distributed data pool;

[0019] Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each of the sub-simulation systems through the distributed data pool, and each of the sub-simulation systems switches between various operating conditions according to the clock state.

[0020] Furthermore, the co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each of the sub-simulation systems.

[0021] Furthermore, it also includes:

[0022] Set the simulation state of the distributed simulation system, and based on the simulation state, call the update interface of the sub-simulation system according to the time parameters to control the sub-simulation system to perform simulation.

[0023] This invention also proposes a distributed real-time interactive simulation system, comprising:

[0024] The simulation data packet acquisition module is used to create multiple sub-simulation systems and acquire the simulation data packet for each of the sub-simulation systems.

[0025] Create a data pool and parameter module, which is used to create a distributed data pool, a co-simulation configuration table, and set time parameters;

[0026] The simulation module is used to obtain the required data for each sub-simulation system from the distributed data pool after the simulation starts, and control each sub-simulation system according to the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, so that each sub-simulation system outputs simulation results.

[0027] The interaction module is used to put the simulation results into the distributed data pool, which serves as the basis for data interaction among the multiple sub-simulation systems.

[0028] Furthermore, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0029] Furthermore, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file.

[0030] The simulation model file defines the behavior of the sub-simulation system;

[0031] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0032] In summary, the technical solutions conceived by this invention have the following beneficial effects compared with the prior art:

[0033] (1) The interface of the distributed real-time simulation model is unified, and a consistent simulation model lifecycle model is realized, including the entire process of model creation, initialization, update and destruction.

[0034] (2) It inherently possesses distributed capabilities under a general network. Through a networked data pool, it achieves data sharing, regional autonomy, and system-wide interconnection among simulation models. This facilitates the "building block" integration of complex simulation systems. Attached Figure Description

[0035] Figure 1 This is a flowchart of the method of Embodiment 1 of the present invention;

[0036] Figure 2 This is a structural diagram of the system of Embodiment 2 of the present invention;

[0037] Figure 3 This is a flowchart of the method in Embodiment 3 of the present invention. Detailed Implementation

[0038] To better understand the above technical solutions, the following will provide a detailed explanation of the technical solutions in conjunction with the accompanying drawings and specific implementation methods.

[0039] The method provided by this invention can be implemented in a terminal environment that may include one or more of the following components: a processor, a storage medium, and a display screen. The storage medium stores at least one instruction, which is loaded and executed by the processor to implement the method described in the following embodiments.

[0040] A processor may include one or more processing cores. The processor uses various interfaces and lines to connect various parts of the terminal, and performs various functions and processes data by running or executing instructions, programs, code sets or instruction sets stored in the storage medium, and by calling data stored in the storage medium.

[0041] Storage media can include random access memory (RAM) or read-only memory (ROM). Storage media can be used to store instructions, programs, code, code sets, or instructions.

[0042] The display screen is used to show the user interface of each application.

[0043] In addition, those skilled in the art will understand that the structure of the terminal described above does not constitute a limitation on the terminal. The terminal may include more or fewer components, or combine certain components, or have different component arrangements. For example, the terminal may also include radio frequency circuits, input units, sensors, audio circuits, power supplies, and other components, which will not be described in detail here.

[0044] Example 1

[0045] like Figure 1 The present invention provides a distributed real-time interactive simulation method, comprising:

[0046] Step 101: Create a distributed simulation system consisting of multiple sub-simulation systems, and obtain the simulation data package of each sub-simulation system;

[0047] Specifically, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file; wherein, the simulation model file defines the behavior of the sub-simulation system.

[0048] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0049] Step 102: Create a distributed data pool, configure a co-simulation table, and set time parameters;

[0050] Specifically, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0051] Specifically, the co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each sub-simulation system.

[0052] Specifically, setting the time parameters includes setting one or more of the following: clock period, number of beats, and / or clock state.

[0053] Specifically, setting the clock period includes: setting the duration of a single simulation;

[0054] Setting the number of ticks includes: the number of ticks starts counting from 1, the value of the number of ticks is incremented by 1 every clock cycle, and each of the sub-simulation systems is notified through the distributed data pool;

[0055] Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each of the sub-simulation systems through the distributed data pool, and each of the sub-simulation systems switches between various operating conditions according to the clock state.

[0056] Step 103: After the simulation starts, obtain the required data for each sub-simulation system from the distributed data pool. Based on the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, control each sub-simulation system so that each sub-simulation system outputs simulation results.

[0057] Step 104: Place the simulation results into the distributed data pool as the basis for data interaction among the multiple sub-simulation systems.

[0058] Furthermore, it also includes: setting the simulation state of the distributed simulation system, and according to the simulation state, calling the update interface of the sub-simulation system according to the time parameters to control the sub-simulation system to perform simulation.

[0059] Example 2

[0060] like Figure 2 As shown, this embodiment of the invention also provides a distributed real-time interactive simulation system, including:

[0061] The simulation data packet acquisition module is used to create a distributed simulation system consisting of multiple sub-simulation systems and acquire the simulation data packet of each of the sub-simulation systems.

[0062] Specifically, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file; wherein, the simulation model file defines the behavior of the sub-simulation system.

[0063] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0064] Create a data pool and parameter module, which is used to create a distributed data pool, a co-simulation configuration table, and set time parameters;

[0065] Specifically, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0066] Specifically, the co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each sub-simulation system.

[0067] Specifically, setting the time parameters includes setting one or more of the following: clock period, number of beats, and / or clock state.

[0068] Specifically, setting the clock period includes: setting the duration of a single simulation;

[0069] Setting the number of ticks includes: the number of ticks starts counting from 1, the value of the number of ticks is incremented by 1 every clock cycle, and each of the sub-simulation systems is notified through the distributed data pool;

[0070] Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each of the sub-simulation systems through the distributed data pool, and each of the sub-simulation systems switches between various operating conditions according to the clock state.

[0071] The simulation module is used to obtain the required data for each sub-simulation system from the distributed data pool after the simulation starts, and control each sub-simulation system according to the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, so that each sub-simulation system outputs simulation results.

[0072] The interaction module is used to put the simulation results into the distributed data pool, which serves as the basis for data interaction among the multiple sub-simulation systems.

[0073] Furthermore, it also includes: setting the simulation state of the distributed simulation system, and according to the simulation state, calling the update interface of the sub-simulation system according to the time parameters to control the sub-simulation system to perform simulation.

[0074] Example 3

[0075] like Figure 3 As shown in the figure, this embodiment of the invention also provides a distributed real-time interactive simulation architecture method, including the following steps:

[0076] 1. Create a distributed data pool

[0077] All software and hardware involved in the real-time simulation of the system are considered as a model, and the input-output and interaction relationships between models are implemented through a distributed data pool. Therefore, a distributed data pool needs to be built before the simulation starts.

[0078] The distributed data pool is networked, has a full network interface, and can operate independently. All data access is achieved through the network interface.

[0079] The distributed data pool uses a two-dimensional table structure to store and index data shared by various simulation models. The stored data includes two types: globally managed data and model data. These two categories are explained in Table 1 below:

[0080] Table 1. Explanation of Data Classification for Storage

[0081]

[0082]

[0083] The distributed data pool supports two core operations: read (get) and write (set). The value types of the read and write parameters include four types: int, float, json, and string, as detailed in Table 2.

[0084] Table 2: Data type description of parameter values

[0085] Serial Number Type definition Type Description Type Operations Application scenarios 1 int Plastic Surgery get / set System status, counters 2 float floating point get / set Model parameters, inputs / outputs 3 json semi-structured data get / set Configuration data, pkg data 4 string unstructured data get / set User-defined data, real-time broadcast data

[0086] 2. Construct subsystem simulation data package

[0087] A system simulation consists of several subsystems, each composed of a simulation model file and a data package file. The simulation model file defines the behavior of the subsystem, while the data package file defines the data upon which the subsystem's behavior depends. Both are indispensable for the model.

[0088] 2.1 Simulation Model Files

[0089] The simulation model file consists of three interfaces: start, update, and destroy. Detailed descriptions of each interface are as follows:

[0090] Initialize interface

[0091] Function: Loads configuration files for the simulation model, initializes relevant internal variables, and assembles relevant simulation parameters.

[0092] parameter:

[0093] (1) project: Project name, used to locate the data package file within the project and perform logging operations, etc.

[0094] (2) ms: Simulation time cycle length

[0095] (3) mdp: The data package file corresponding to the model

[0096] Return value:

[0097] (1) Boolean: True / False, returning True indicates successful model initialization, returning False

[0098] This indicates that initialization failed. When initialization fails, the model will automatically exit the simulation.

[0099] Update Interface

[0100] Function: Perform a simulation calculation at a given time interval.

[0101] parameter:

[0102] (1)t: Current clock beat

[0103] Return value:

[0104] (1) Boolean: True / False. Returning True has no meaning, while returning False indicates that the update failed. The system believes that the model has encountered an unrecoverable error and will exit the simulation.

[0105] Destroy interface

[0106] Function: Destroy the model and perform simulation closing actions.

[0107] No parameters, no return value.

[0108] 2.2 Simulation Data Package

[0109] Simulation data packages describe the parameters and data upon which the simulation model depends. These data are related to the physical properties of the simulated object and are independent of the algorithms and formulas used in the simulation model. This approach allows for the simulation of different experimental characteristics of the same type of object, thereby improving the versatility of the simulation model.

[0110] The simulation data package is defined in JSON format and consists of six parts, as shown in Table 3.

[0111] Table 3. Description of Simulation Data Package Composition

[0112]

[0113]

[0114] An example of a simulated data packet is as follows:

[0115]

[0116] The data field of the simulation data package supports various data types, including integers, floating-point numbers, one-dimensional arrays, and multi-dimensional arrays.

[0117] 3. Create a simulation time manager

[0118] The simulation time manager is the core module of the system, used to control and distribute the time ticks of the entire system in order to control the process of the entire system simulation.

[0119] 3.1 Components of a Time Manager

[0120] The time manager consists of three parts: clock cycle, number of beats, and clock status.

[0121] (1) Clock cycle: Defines the duration of a single simulation, with a minimum of 1ms and no maximum time limit.

[0122] (2) Number of ticks: Controlled by the system, starting from 1, the number of ticks increments by 1 every clock cycle, and is notified to all simulation models of the system through the g_tick shared variable of the distributed data pool.

[0123] (3) Clock Status: Defines the overall state of the system, including four states: initial state, running state, paused state, and stopped state. At the same time, the clock status is also notified to all simulation models of the system through the g_status shared variable of the distributed data pool, so that each model can switch between various operating conditions according to the system simulation status.

[0124] 3.2 Time Manager Control

[0125] The time manager includes five control commands: Start, Pause, Resume, Stop, and Tick Adjustment. Different commands have command words or adjust their internal control logic based on user input. All command words are in the following format:

[0126] Table 4. List of Time Manager Control Commands

[0127]

[0128] 4. Create a co-simulation configuration table

[0129] A large system simulation is obtained by co-simulating multiple subsystems. Therefore, the co-simulation configuration table is used to configure the number, type, and corresponding configuration files of the subsystem simulation models participating in the current simulation.

[0130] The co-simulation configuration table consists of five parts, including identifier, frequency, network address and port of the distributed data pool, and list of simulation sub-models.

[0131] (1) Identifier: Used to identify the current co-simulation system.

[0132] (2) Frequency: The clock beat of the co-simulation system, which is the minimum clock beat for each subsystem simulation.

[0133] (3) Network address and port of the distributed data pool: used to connect to the data pool.

[0134] (4) List of simulation sub-models: A list of subsystem models participating in the co-simulation. Each sub-model consists of a series of descriptive attributes, as shown in Table 5.

[0135] Table 5. Description of Simulation Sub-model Attributes

[0136] Serial Number attribute fields Attribute Name Attribute Description 1 id logo This identifier is unique among the models participating in the co-simulation. 2 path path Subsystem simulation model file path 3 host IP address IPv4 address for connecting to the data pool 4 port port number Port number for connecting to the data pool 5 params parameter Identifier of the simulation data package on which the subsystem simulation model depends

[0137] The following is an example of a co-simulation configuration table:

[0138]

[0139]

[0140] 5. Simulation process control

[0141] The simulation process control module is the central control module of the entire distributed real-time interactive simulation platform, and also the top-level manager module of the system. In a networked, distributed co-simulation system, there exists one and only one simulation process control module.

[0142] The simulation process control flow is as follows:

[0143] 5.1 Creation

[0144] The process control module creates itself based on the co-simulation configuration table, including a model list, model counter, common channels, and external control interfaces. The external control interface uses the UDP protocol, allowing administrators to directly initiate control actions to the co-simulation system via UDP. The main control commands and execution actions are shown in Table 6.

[0145] Table 6 List of External UDP Control Actions

[0146] Serial Number Control Action Control Action 1 addm Add subsystem simulation model 2 delm Deleting the subsystem simulation model 3 start Start the co-simulation system 4 freeze Freeze the co-simulation system 5 recover Restore the frozen co-simulation system 6 stop The co-simulation system has stopped running. 7 broadcast Broadcast data to each subsystem of the co-simulation system

[0147] 5.2 Initialize the subsystem simulation model

[0148] According to the co-simulation configuration table, the process control module first creates the log directory and files for the subsystems to facilitate the generation of log information in subsequent processes, thereby aiding in debugging and fault diagnosis. Then, based on the subsystem's simulation model file path, it loads the subsystem simulation model. Two types of subsystem simulation models can be loaded depending on the path prefix; the differences between the two types are shown in Table 7.

[0149] Table 7. Differences between subsystem simulation models

[0150]

[0151] When initializing the subsystem simulation model, the project name, clock tick, and data packet path are injected into the model through the initialization interface of the subsystem simulation model (see 2.1) so that the model can complete the initialization work autonomously.

[0152] 5.3 Operation Control

[0153] After the subsystem simulation model is initialized, each subsystem simulation model enters the running state as an independent computer process.

[0154] The process control module calls the update interface of each subsystem simulation model according to the system state (initial state, running state, frozen state, stopped state) on a clock cycle (see step 2.1) to execute the single-step operation of the model. The process control module records the total time t1 of the subsystem simulation model update operation and calculates the sleep time t2 = t – t1, where t is the total length of the system clock cycle. If t2 < 0, the system throws a timeout error, reminding the user that the simulation system has timed out and intervention or handling is required.

[0155] 5.4 Exiting the Sub-Simulation Model

[0156] There are two ways for a sub-simulation model to exit: one is through external control, which sends a delm command via the process control module's UDP interface to forcibly kill the specified subsystem simulation model process, thus achieving exit. The other way is that when the sub-simulation model executes the update interface, it returns False, and the process control module considers the subsystem to have a major fault and exits it.

[0157] 6. Model Input

[0158] For each subsystem simulation model, executing the update interface mainly involves three actions: acquiring input, simulation calculation, and generating output.

[0159] 6.1UDS

[0160] Each subsystem has its own independent, complete, and localized input / output system, namely UDS (User Defined System). Under normal circumstances, each subsystem only needs to focus on the UDS. How the data in the UDS interacts with the distributed data pool is controlled by the system, and the user only needs to configure it.

[0161] UDS defines a local dictionary structure and a set of index structures. The dictionary describes all proprietary constants and variables used in the subsystem simulation. The index structures differ depending on the domain, with core ones including: an index for the distributed data pool and an index for the simulation data package.

[0162] The model's inputs include two types: distributed data pool inputs and simulation data package inputs.

[0163] 6.2 Distributed Data Pool Input

[0164] The input to the distributed data pool typically consists of the outputs of other subsystem simulation models that have updated themselves, which are then used as input to this system. This includes instruction data, hardware drive signals, and so on. These inputs are defined through the "in" field of the simulation data packet, and the system automatically retrieves data from the distributed data pool based on this field and writes it to the UDS.

[0165] 6.3 Simulation Data Packet Input

[0166] The simulation data package is mainly used to input constants and coefficients related to the subsystem simulation model, including subsystem design data, simulation data, and experimental data. This data can be directly referenced in the model's update function using the form UDS['variable name'].

[0167] 7. Model Solving

[0168] The subsystem simulation model is driven by the process control module calling the update interface to perform model solving. In addition to obtaining the input from the UDS, the process control module also transmits the current clock tick t to the model so that the simulation model itself can adjust different simulation logic according to different clock ticks.

[0169] There are two ways to develop the model's solution logic. One is in the form of source code, where the simulation logic is written directly using Python-like code, and the platform itself provides a large number of APIs for it to call. The other is through wireframe diagrams, which consist of several algorithm gates. Users only need to connect the inputs and outputs of each algorithm gate with connecting lines to realize the complete real-time simulation logic.

[0170] 8. Model Output

[0171] After the subsystem simulation model completes the calculation, the results to be output to other subsystem simulation models are written to UDS. UDS sends the variables to be output in UDS to the distributed data pool through the distributed data pool index and notifies the entire system to realize the output of the entire system.

[0172] Example 4

[0173] This invention also proposes a storage medium that stores multiple instructions, which are used to implement the distributed real-time interactive simulation method described above.

[0174] Optionally, in this embodiment, the storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any mobile terminal in a group of mobile terminals.

[0175] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps: Step 101, creating a distributed simulation system composed of multiple sub-simulation systems, and obtaining simulation data packets for each of the sub-simulation systems;

[0176] Specifically, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file; wherein, the simulation model file defines the behavior of the sub-simulation system.

[0177] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0178] Step 102: Create a distributed data pool, configure a co-simulation table, and set time parameters;

[0179] Specifically, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0180] Specifically, the co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each sub-simulation system.

[0181] Specifically, setting the time parameters includes setting one or more of the following: clock period, number of beats, and / or clock state.

[0182] Specifically, setting the clock period includes: setting the duration of a single simulation;

[0183] Setting the number of ticks includes: the number of ticks starts counting from 1, the value of the number of ticks is incremented by 1 every clock cycle, and each of the sub-simulation systems is notified through the distributed data pool;

[0184] Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each of the sub-simulation systems through the distributed data pool, and each of the sub-simulation systems switches between various operating conditions according to the clock state.

[0185] Step 103: After the simulation starts, obtain the required data for each sub-simulation system from the distributed data pool. Based on the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, control each sub-simulation system so that each sub-simulation system outputs simulation results.

[0186] Step 104: Place the simulation results into the distributed data pool as the basis for data interaction among the multiple sub-simulation systems.

[0187] Furthermore, it also includes: setting the simulation state of the distributed simulation system, and according to the simulation state, calling the update interface of the sub-simulation system according to the time parameters to control the sub-simulation system to perform simulation.

[0188] Example 4

[0189] This invention also proposes an electronic device, including a processor and a storage medium connected to the processor. The storage medium stores multiple instructions, which can be loaded and executed by the processor to enable the processor to execute the distributed real-time interactive simulation method described above.

[0190] Specifically, the electronic device in this embodiment can be a computer terminal, which may include one or more (only one is shown in the figure) processors and storage media.

[0191] The storage medium can be used to store software programs and modules, such as the distributed real-time interactive simulation method in this embodiment of the invention, and the corresponding program instructions / modules. The processor executes various functional applications and data processing by running the software programs and modules stored in the storage medium, thereby realizing the aforementioned information push method. The storage medium may include high-speed random access storage media, and may also include non-volatile storage media, such as one or more magnetic storage systems, flash memory, or other non-volatile solid-state storage media. In some instances, the storage medium may further include storage media remotely configured relative to the processor, and these remote storage media can be connected to the terminal via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0192] The processor can call the information and application stored in the storage medium through the transmission system to perform the following steps: Step 101, create a distributed simulation system composed of multiple sub-simulation systems, and obtain the simulation data packet of each of the sub-simulation systems;

[0193] Specifically, each of the sub-simulation systems consists of two parts: a simulation model file and a data package file; wherein, the simulation model file defines the behavior of the sub-simulation system.

[0194] The data package file defines the data upon which the behavior of the sub-simulation system depends.

[0195] Step 102: Create a distributed data pool, configure a co-simulation table, and set time parameters;

[0196] Specifically, the distributed data pool uses a two-dimensional table structure to store and index the data shared by each of the sub-simulation systems.

[0197] Specifically, the co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each sub-simulation system.

[0198] Specifically, setting the time parameters includes setting one or more of the following: clock period, number of beats, and / or clock state.

[0199] Specifically, setting the clock period includes: setting the duration of a single simulation;

[0200] Setting the number of ticks includes: the number of ticks starts counting from 1, the value of the number of ticks is incremented by 1 every clock cycle, and each of the sub-simulation systems is notified through the distributed data pool;

[0201] Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each of the sub-simulation systems through the distributed data pool, and each of the sub-simulation systems switches between various operating conditions according to the clock state.

[0202] Step 103: After the simulation starts, obtain the required data for each sub-simulation system from the distributed data pool. Based on the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, control each sub-simulation system so that each sub-simulation system outputs simulation results.

[0203] Step 104: Place the simulation results into the distributed data pool as the basis for data interaction among the multiple sub-simulation systems.

[0204] Furthermore, it also includes: setting the simulation state of the distributed simulation system, and according to the simulation state, calling the update interface of the sub-simulation system according to the time parameters to control the sub-simulation system to perform simulation.

[0205] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0206] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0207] In the several embodiments provided by this invention, it should be understood that the disclosed technical content can be implemented in other ways. The system embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, or indirect coupling or communication connection between units or modules, and may be electrical or other forms.

[0208] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0209] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0210] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes: USB flash drives, read-only storage media (ROM), random access storage media (RAM), portable hard drives, magnetic disks, optical disks, and other media capable of storing program code.

[0211] Obviously, the above embodiments are merely illustrative examples for clear explanation and are not intended to limit the implementation. Those skilled in the art will recognize that other variations or modifications can be made based on the above description. It is neither necessary nor possible to exhaustively list all possible implementations here. However, obvious variations or modifications derived therefrom are still within the scope of protection of this invention.

Claims

1. A distributed real-time interactive simulation method, characterized in that, include: A distributed simulation system consisting of multiple sub-simulation systems is created, and simulation data packages for each sub-simulation system are obtained. Each sub-simulation system consists of two parts: a simulation model file and a data package file. The simulation model file defines the behavior of the sub-simulation system, and the data package file defines the data on which the behavior of the sub-simulation system depends. A distributed data pool is created, a co-simulation configuration table is established, and time parameters are set. The distributed data pool uses a two-dimensional table structure to store and index data shared by each of the sub-simulation systems. The co-simulation configuration table includes an identifier, frequency, network address of the distributed data pool, port, and a list of sub-models for each sub-simulation system. Setting the time parameters includes setting the clock cycle, tick count, and clock state. Setting the clock cycle includes setting the duration of a single simulation. Setting the tick count involves incrementing the count by 1 every clock cycle and notifying each sub-simulation system via the distributed data pool. Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each sub-simulation system via the distributed data pool, and each sub-simulation system switches between different operating conditions based on the clock state. Set the simulation state of the distributed simulation system, and according to the simulation state, call the update interface of the sub-simulation system according to the time parameter to control the sub-simulation system to perform simulation. Once the simulation begins, the required data for each sub-simulation system is obtained from the distributed data pool. Based on the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, each sub-simulation system is controlled to output simulation results. The simulation results are placed into the distributed data pool, serving as the basis for data interaction among the multiple sub-simulation systems.

2. A distributed real-time interactive simulation system, characterized in that, include: The simulation data package acquisition module is used to create multiple sub-simulation systems and acquire simulation data packages for each sub-simulation system. Each sub-simulation system consists of two parts: a simulation model file and a data package file. The simulation model file defines the behavior of the sub-simulation system, and the data package file defines the data on which the behavior of the sub-simulation system depends. A data pool and parameter module is created to establish a distributed data pool, a co-simulation configuration table, and set time parameters. The distributed data pool uses a two-dimensional table structure to store and index data shared by the sub-simulation systems. The co-simulation configuration table includes an identifier, frequency, network address and port of the distributed data pool, and a list of sub-models for each sub-simulation system. Setting the time parameters includes setting the clock cycle, tick count, and clock state. Setting the clock cycle includes setting the duration of a single simulation. Setting the tick count involves incrementing the count by 1 every clock cycle and notifying each sub-simulation system via the distributed data pool. Setting the clock state includes setting four clock states: initial state, running state, paused state, and stopped state. The clock state is notified to each sub-simulation system via the distributed data pool, and each sub-simulation system switches between different operating conditions based on the clock state. Set the simulation state of the distributed simulation system, and according to the simulation state, call the update interface of the sub-simulation system according to the time parameter to control the sub-simulation system to perform simulation. The simulation module is used to obtain the required data for each sub-simulation system from the distributed data pool after the simulation starts, and control each sub-simulation system according to the simulation data package and the required data, combined with the time parameters and the joint simulation configuration table, so that each sub-simulation system outputs simulation results. The interaction module is used to put the simulation results into the distributed data pool, which serves as the basis for data interaction among the multiple sub-simulation systems.

Citation Information

Patent Citations

  • Method for designing componentized and parameterized simulation model

    CN103810018A