Scheduling method for cross-platform simulation engine for universal launch vehicles

Through the scheduling method of cross-platform simulation engines, the rocket modules are dynamically generated and unifiedly called, which solves the problem of difficulty in achieving generalized and modular design in the existing technology, and realizes high confidence, high reliability and low cost flight action mechanics simulation to meet the needs of modern commercial aerospace.

CN118228386BActive Publication Date: 2025-05-09LONGXING ROCKET TECHNOLOGY (SHANGHAI) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410358276.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-27
Publication Date
2025-05-09
Estimated Expiration
2044-03-27

AI Technical Summary

Technical Problem

Existing flight action mechanics simulation software is difficult to achieve general and modular design, and cannot meet the needs of modern commercial aerospace for high confidence, high reliability and low cost design.

Method used

The scheduling method of cross-platform simulation engine is adopted, and different types of modules are registered through the module factory, the rocket's dynamic description files are read, the relevant information of the target engine is identified, the functional modules are generated dynamically, and the messages are registered on the message bus to realize the unified call and integral scheduling of the functional modules.

Benefits of technology

It realizes a cross-platform and general flight action mechanics simulation engine, from solution to physical simulation, low-cost generalization, meets the ballistic calculation and simulated flight requirements of multiple models and multi-tasks, reducing maintenance costs and improving calculation accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118228386B_ABST
    Figure CN118228386B_ABST
Patent Text Reader

Abstract

The present invention provides a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle, comprising: registering all modules based on the same interface in a module factory; reading a dynamic description file of a rocket; searching for a target engine to be generated in the module factory, and after generating the target engine, importing all functional module description information and a data structure assigned to the target engine into an engine instance; generating a corresponding functional module in the functional module description information, and registering a message on a message bus; starting a bus and serial port driver related to the target engine, and starting a background thread related to the target engine; completing an update of the target engine within one calculation step; and completing integral calculation within one calculation step. Thus, the method can be applicable to scheduling and simulation of multiple models and platforms, and can take into account a cross-platform engine for trajectory calculation, guidance analysis, and semi-physical simulation, and realize ultra-real-time and real-time closed-loop simulation from digital domain to product level.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of computer simulation, and in particular to a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle. Background Art

[0002] Existing flight dynamics simulation software is generally developed using C / C++, Matlab or Unity C# languages. Among them, C / C++ language is well integrated with embedded development and can be applied to existing integrated electronic computers, but it is not easy to achieve universal and modular design based on the language's own characteristics. Matlab language focuses more on process-oriented programming ideas, which is suitable for scheme stage demonstration, and is not easy to achieve strong real-time semi-physical simulation and universal design. Unity is suitable for scene demonstration and cannot be used for strong real-time simulation testing. With the development of modern commercial aerospace, the space transportation system is changing from "how to solve the problem of entering space" to "how to solve the problem of low-cost entry into space". High confidence, high reliability and low-cost design are the top priorities. Universal and modular software design of the entire process from scheme to rocket products is the fundamental solution to this problem. Summary of the invention

[0003] In view of the defects in the prior art, the object of the present invention is to provide a scheduling method for a cross-platform simulation engine for general-purpose launch vehicles.

[0004] In a first aspect, an embodiment of the present application provides a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle, comprising:

[0005] Step 1: Register all modules based on the same interface in the module factory, including: different types of engines, functional components, and readers;

[0006] Step 2: Read the dynamics description file of the rocket, and identify the relevant information of the target engine to be generated according to the dynamics description file;

[0007] Step 3: searching for the target engine to be generated in the module factory, and after generating the target engine, importing all functional module description information and the data structure allocated to the target engine into the engine instance of the target engine;

[0008] Step 4: Generate the corresponding functional module in the functional module description information and register the message on the message bus;

[0009] Step 5: Start the bus and serial port driver related to the target engine, and start the background thread related to the target engine;

[0010] Step 6: In one calculation step, all functional modules maintained by the target engine are uniformly called through the Update function to complete the update of the target engine;

[0011] Step 7: In one calculation step, the integral parameter set {x} and the differential component set {dx} are refreshed through the unified integrator.

[0012] Optionally, the relevant information of the target engine to be generated in step 2 includes:

[0013] Engine type, subordinate function module types, initial parameters of each function module, input / output relationship with other modules, input / output parameter type, dimension and value.

[0014] Optionally, step 4 includes:

[0015] Step 4.1: Searching and dynamically generating the function module corresponding to the function module description information in the module factory;

[0016] Step 4.2: Determine the initial parameters of each functional module, the input / output relationship with other modules, and the input / output parameters;

[0017] Step 4.3: Register the message on the message bus to complete the mapping between the message and the behavior.

[0018] Optionally, when the functional module in step 6 uses a finite state machine to implement state migration as the state changes, or sends a message to other modules through a soft bus, all functional modules maintained by the target engine are uniformly called through the Update function, so that other modules connected to the functional module respond to the received message and execute the corresponding function.

[0019] Optionally, it also includes:

[0020] When there is an error in the input / output relationship between the functional modules in step 2, a corresponding first-type error code is returned, where the first-type error code is used to indicate that there is an error in the connection relationship between the functional modules.

[0021] Optionally, it also includes:

[0022] When the description of the engine type in the dynamics description file cannot be correctly identified in the module factory, a corresponding second-type error code is returned, and the second-type error code is used to indicate that the construction of the simulation scheduling engine has failed.

[0023] Optionally, it also includes:

[0024] When the functional module to which the target engine belongs cannot be identified and the functional module cannot be generated, a corresponding third-type error code is returned, and the third-type error code is used to indicate failure in constructing the simulation scheduling engine.

[0025] Optionally, if the object maintained by the target engine to be generated is an engine queue having a unified interface, the method includes:

[0026] Register all modules based on the same interface in the module factory, including: different types of engines, functional components, and readers;

[0027] The target engine is defined as the root engine, a dynamics description file of the rocket is read, and relevant information of the root engine to be generated is identified according to the dynamics description file;

[0028] Searching for a root engine to be generated in the module factory, and after generating the root engine, importing all subordinate sub-engine description information and the data structure allocated to the root engine into the engine instance of the root engine;

[0029] Search and dynamically generate sub-engines in the description information in the module factory, determine the number and engine type of sub-engines to which the root engine belongs, determine the initial parameters of each sub-engine, the input / output relationship with other sub-engines, and the input / output parameters, and register messages on the message bus to complete the mapping between messages and behaviors;

[0030] Traverse all sub-engines under the root engine, start the bus and serial port drivers related to the root engine, and start the background thread related to the root engine;

[0031] In one calculation step, all sub-engines maintained by the root engine are called in sequence through the Update function to complete the update of the root engine, wherein each sub-engine relies on the message bus of the root engine to complete the message transmission and function call between sub-engines;

[0032] In one calculation step, all sub-engines are called in sequence through a unified integrator to refresh the integral parameter set {x} and the differential component set {dx}.

[0033] Optionally, when the root engine includes two sub-engines, the two sub-engines are divided into a communication engine and a computing engine according to their functions, wherein:

[0034] Before the calculation engine starts calculation, the communication engine is updated to complete the reading of navigation information on the bus and the serial port;

[0035] After reading the message content, sending the message to the computing engine;

[0036] The calculation engine starts calculation after receiving the message, and after completing the integral update, feeds back calculation completion information to the communication engine, so that the communication engine organizes messages to the bus, serial port, and Ethernet module.

[0037] In a second aspect, an embodiment of the present application provides a scheduling system for a cross-platform simulation engine for a general-purpose launch vehicle, which is used to implement the steps of the scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle described in any one of the first aspects, and the system includes:

[0038] The module factory is used to maintain all module types registered with reference to the unified interface, dynamically generate different module instances according to external requirements, and cancel registered module types; maintain all engine types registered with reference to the unified interface, dynamically generate different engine instances according to external requirements, and cancel registered engine types; maintain all configuration file reader types registered with reference to the unified interface, dynamically generate different readers according to external requirements, and cancel registered reader types;

[0039] The functional module contains classes with various unified interface functions, which are used to characterize a certain component on the rocket with a mathematical model internally, and has three types of data: initial parameters, input, and output. In each calculation step, it refreshes input data, performs numerical calculations and integration, and outputs module data in sequence, thus completing the implementation of functions and data interaction with other functional modules.

[0040] The engine is used to receive the launch vehicle dynamics model description from the outside, dynamically generate corresponding modules in the module factory according to the launch vehicle dynamics model description, maintain and initialize all module instances; in each calculation step, all modules under it are updated uniformly through the Update function; in each calculation step, the integration of all subordinate modules is uniformly completed through the Derive function;

[0041] Finite state machine, used to control the functional module to complete the corresponding state switching behavior according to the external identifier, so as to maintain its own state and clarify the module behavior;

[0042] The message soft bus is used to define the message subject and message type, maintain the instructions corresponding to each module function, and complete the message registration; accept instructions issued by any module; index and schedule corresponding behaviors in the registered messages;

[0043] The file reader is used to read the rocket dynamics model described in the configuration file, allocate memory space for the rocket dynamics model, and determine the type of engine called; convert the text description into a data structure that can be read by the engine.

[0044] In a third aspect, an embodiment of the present application provides an electronic device, including: a processor and a memory, wherein the memory stores executable program instructions, and when the processor calls the program instructions in the memory, the processor is used to:

[0045] Execute the steps of the scheduling method for a cross-platform simulation engine for general-purpose launch vehicles as described in any one of the first aspects.

[0046] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium for storing a program, which, when executed, implements the steps of a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle as described in any one of the first aspects.

[0047] Compared with the prior art, the present invention has the following beneficial effects:

[0048] 1) The scheduling method of the cross-platform simulation engine for general-purpose launch vehicles provided in this application can realize a cross-platform, general-purpose flight dynamics simulation engine, achieving the purpose of full-process simulation from scheme to physical object and low-cost generalization.

[0049] 2) The simulation engine in this application is based on C++ language and adopts reflection, message bus, factory mode and other technologies to build a universal flight simulation engine suitable for most types of rockets. It can realize unified memory allocation, adopt modular design, use functional components as objects, dynamically generate them in the initialization phase, and schedule all generated components in each time step to realize internal component management, external data import, internal component data communication, component integral scheduling, data recording, data export and other functions.

[0050] 3) This application configures different types of engines, aerodynamic parameters, mass parameters and initial data, so that multiple models and multiple tasks can share a set of high-precision dynamic models, which is suitable for the scheduling and simulation of multiple models and multiple platforms. It can also take into account the cross-platform engine of ballistic calculation, guidance analysis, and semi-physical simulation, and realize ultra-real-time and real-time closed-loop simulation from the digital domain to the product level, which well fills the technical gaps in the current models.

[0051] 4) This application can realize dual-machine and multi-machine physical simulation in the physical domain, and has the ability to integrate design verification from solution demonstration to product realization. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for use in the embodiments or the prior art descriptions. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without creative work. By reading the detailed description of the non-limiting embodiments with reference to the following drawings, other features, purposes and advantages of the present invention will become more obvious:

[0053] Figure 1 A flow chart of a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle provided in an embodiment of the present application;

[0054] Figure 2 A schematic diagram of the architecture of a simulation scheduling engine for a new two-stage launch vehicle provided in an embodiment of the present application;

[0055] Figure 3 A schematic diagram of message flow between a root engine and a sub-engine provided in an embodiment of the present application. DETAILED DESCRIPTION

[0056] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0057] It should be noted that when a component is "derived" from another component, it can have all the characteristics of the other component, which is called inheritance. At the same time, the component is also recognized as being able to derive new components. The new component, as an "intermediate" component, can be inherited by new components while inheriting the old component.

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

[0059] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein, for example, can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof 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.

[0060] The following specific embodiments are used to describe in detail the technical solution of the present invention and how the technical solution of the present application solves the above technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

[0061] In conjunction with the accompanying drawings, some embodiments of the present application are described in detail below. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.

[0062] The embodiment of the present application provides a scheduling method for a cross-platform simulation engine for general-purpose launch vehicles, which aims to solve technical problems such as the lack of universality of existing launch vehicle flight dynamics simulation engines, the difficulty in meeting the needs of multi-model and multi-task ballistic calculations and simulated flights, the high maintenance costs, and the uneven calculation accuracy.

[0063] Exemplarily, the method in this application adopts reflection and factory mode to build a general flight simulation engine suitable for most types of rockets. The engine uniformly allocates memory, adopts modular design, divides the earth, engine, tank, mass, and aerodynamic calculation into different components, schedules the corresponding components in each time step, and realizes functions such as internal component management, external data import, internal component data communication, component integral scheduling, data recording, and data export. By configuring different types of engines, aerodynamic parameters, mass parameters, and initial data, multiple models and multiple tasks can be used for a set of high-precision dynamic models, which solves the functional requirements of rapid verification of electrical systems and closed-loop simulation flight during the development of launch vehicle models, and avoids the problems of high maintenance cost, inconsistent calculation accuracy, weak expansibility, and large deviation between scheme design and actual tasks of existing software.

[0064] Figure 1 A flowchart of a scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle provided in an embodiment of the present application is shown in FIG. Figure 1As shown, the method in this embodiment may include the following steps:

[0065] Step S101: register all modules based on the same interface in the module factory, the modules including: different types of engines, functional components, and readers.

[0066] In this embodiment, all modules based on the same interface are first registered in the module factory. Among them, the module factory based on inversion of control (IOC) is used to maintain all module types registered with reference to the unified interface; dynamically generate different module instances according to external requirements; cancel the registered module types; maintain all engine types registered with reference to the unified interface; dynamically generate different engine instances according to external requirements; cancel the registered engine types; maintain all configuration file reader types registered with reference to the unified interface; dynamically generate different readers according to external requirements; and cancel the registered reader types.

[0067] Step S102: Read the dynamics description file of the rocket, and identify the relevant information of the target engine to be generated based on the dynamics description file.

[0068] In this embodiment, the relevant information of the target engine to be generated includes: engine type, subordinate function module type, initial parameters of each function module, input / output relationship with other modules, input / output parameter type, dimension and value.

[0069] Step S103: searching for a target engine to be generated in the module factory, and after generating the target engine, importing all functional module description information and the data structure allocated to the target engine into the engine instance of the target engine.

[0070] In this embodiment, the functional module has a class of unified interface functions such as initialization, startup, update, and integration, and uses a mathematical model to characterize a certain component on the rocket. It has three types of data: initial parameters, input, and output. In each calculation step, it completes refreshing input data, numerical calculation and integration, and output module data in turn, completing the specific implementation of the function and data interaction with other functional modules.

[0071] Step S104: Generate the corresponding functional module in the functional module description information, and register the message on the message bus.

[0072] In this embodiment, the function module in the description information is searched and dynamically generated in the module factory, the initial parameters of the module, the input / output relationship with other modules, and the input / output parameters are clarified, and the message is registered on the message bus to complete the mapping between the message and the behavior.

[0073] Step S105: Start the bus and serial port drivers related to the target engine, and start the background thread related to the target engine.

[0074] In this embodiment, related bus and serial port drivers are started; related background threads are started to prepare for the super real-time / real-time scheduling of the engine.

[0075] Step S106: within one calculation step, all functional modules maintained by the target engine are uniformly called through the Update function to complete the update of the target engine.

[0076] In this embodiment, within one calculation step, an engine update needs to be completed. All functional modules maintained by the engine are uniformly called through the Update function. The functional modules may use the finite state machine to implement state migration as the state changes, or send messages to other modules through the soft bus. Other modules respond to the message and execute the corresponding function.

[0077] Step S107: In one calculation step, the integral parameter set {x} and the differential component set {dx} are refreshed through a unified integrator.

[0078] In this embodiment, within one calculation step, one integration of the engine needs to be completed. All functional modules maintained by the engine are uniformly called through the Derive function, and the integral parameter set {x} and the differential component set {dx} are refreshed through a unified integrator.

[0079] Exemplarily, to ensure the reliability of engine operation, in the above step S102, if the input-output relationship between modules is incorrect, a corresponding error code is returned to indicate that the connection relationship between modules is incorrect; in the above step S103, if the engine type description in the description file cannot be correctly identified in the factory, a corresponding error code is returned to indicate that the construction of the simulation scheduling engine has failed; in the above step S104, if the functional module to which the engine belongs cannot be identified and cannot be generated, a corresponding error code is returned to indicate that the construction of the simulation scheduling engine has failed.

[0080] For example, Figure 2 Schematic diagram of the architecture of the simulation scheduling engine of the new two-stage launch vehicle provided in the embodiment of the present application; see Figure 2 Based on C++ language, a cross-platform, general flight dynamics simulation engine is built using reflection, message bus and factory mode technologies, in order to achieve full-process simulation from scheme to physical object and low-cost generalization. The simulation engine in this embodiment can uniformly allocate memory, adopt modular design, take functional components as objects, dynamically generate them in the initialization phase, and schedule all generated components in each time step to realize internal component management, external data import, internal component data communication, component integral scheduling, data recording, data export and other functions.

[0081] In order to realize the real-time simulation scheduling function of the platform, this application independently sets up the concept of the root engine in the semi-physical test environment. That is, the engine does not maintain the functional module, but the engine queue with a unified interface. Through the message bus maintained by itself and the update function of all engines, cross-platform simulation scheduling is realized. Specifically, the following steps are included:

[0082] Step A1: Register all modules based on the same interface in the module factory. The modules include: different types of engines, functional components, and readers.

[0083] Step A2: Define the target engine as the root engine, read the dynamics description file of the rocket, and identify the relevant information of the root engine to be generated based on the dynamics description file.

[0084] Step A3: Find the root engine to be generated in the module factory, and after generating the root engine, import all subordinate sub-engine description information and the data structure allocated to the root engine into the engine instance of the root engine.

[0085] Step A4: Search and dynamically generate sub-engines in the description information in the module factory, determine the number of sub-engines and engine types belonging to the root engine, and determine the initial parameters of each sub-engine, the input / output relationship with other sub-engines, and the input / output parameters, and register messages on the message bus to complete the mapping between messages and behaviors.

[0086] Step A5: traverse all sub-engines under the root engine, start the bus and serial port drivers related to the root engine, and start the background thread related to the root engine.

[0087] Step A6: In one calculation step, all sub-engines maintained by the root engine are called in sequence through the Update function to complete the update of the root engine. Among them, each sub-engine relies on the message bus of the root engine to complete the message transmission and function call between sub-engines.

[0088] Step A7: In one calculation step, all sub-engines are called in sequence through a unified integrator to refresh the integral parameter set {x} and the differential component set {dx}.

[0089] For example, Figure 3 A schematic diagram of message flow between the root engine and the sub-engine provided in the embodiment of the present application, combined with Figure 3,The root engine that meets the requirements of dual-machine and multi-machine semi-physical real-time simulation and scheduling usually has two sub-engines, one involving the communication engine with functions such as 1553B bus, 422 serial port, and Ethernet communication, and the other involving the calculation engine with functions such as aerodynamic calculation, trajectory calculation, engine thrust and torque calculation, and mass center of mass calculation. Before the calculation starts, the communication module will be updated first, complete the reading of navigation information on the bus and serial port, and after reading the message content, send a message to tell the calculation module that it can start numerical calculation; after the calculation module completes integration and update, it will send a message to the communication engine to tell the communication engine that the calculation has been completed and it can organize messages to the bus, serial port, and Ethernet modules.

[0090] The embodiment of the present application also provides a cross-platform simulation engine and scheduling system for general-purpose launch vehicles, characterized in that the steps for implementing the above-mentioned cross-platform simulation engine and scheduling method for general-purpose launch vehicles are as follows:

[0091] The module factory is used to maintain all module types registered with reference to the unified interface, dynamically generate different module instances according to external requirements, and cancel registered module types; maintain all engine types registered with reference to the unified interface, dynamically generate different engine instances according to external requirements, and cancel registered engine types; maintain all configuration file reader types registered with reference to the unified interface, dynamically generate different readers according to external requirements, and cancel registered reader types;

[0092] The functional module contains classes with various unified interface functions, which are used to characterize a certain component on the rocket with a mathematical model internally, and has three types of data: initial parameters, input, and output. In each calculation step, it refreshes input data, performs numerical calculations and integration, and outputs module data in sequence, thus completing the implementation of functions and data interaction with other functional modules.

[0093] The engine is used to receive the launch vehicle dynamics model description from the outside, dynamically generate corresponding modules in the module factory according to the launch vehicle dynamics model description, maintain and initialize all module instances; in each calculation step, all modules under it are updated uniformly through the Update function; in each calculation step, the integration of all subordinate modules is uniformly completed through the Derive function;

[0094] Finite state machine, used to control the functional module to complete the corresponding state switching behavior according to the external identifier, so as to maintain its own state and clarify the module behavior;

[0095] The message soft bus is used to define the message subject and message type, maintain the instructions corresponding to each module function, and complete the message registration; accept instructions issued by any module; index and schedule corresponding behaviors in the registered messages;

[0096] The file reader is used to read the rocket dynamics model described in the configuration file, allocate memory space for the rocket dynamics model, and determine the type of engine called; convert the text description into a data structure that can be read by the engine.

[0097] It should be noted that the current launch vehicle models do not have a cross-platform engine that can take into account ballistic calculation, guidance analysis, and semi-physical simulation, and realize ultra-real-time and real-time closed-loop simulation from the digital domain to the product level. The method and system provided by this application can well fill the technical gaps in the current models. In addition, the multi-engine simulation scheduling method proposed in the present invention can realize dual-machine and multi-machine physical simulation in the physical domain, and has the integrated design verification capability from scheme demonstration to product realization.

[0098] It should be noted that those skilled in the art will appreciate that various aspects of the present invention may be implemented as systems, methods or program products. Therefore, various aspects of the present invention may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to as "circuit", "module" or "platform" herein.

[0099] In addition, an embodiment of the present application further provides a computer-readable storage medium, in which computer-executable instructions are stored. When at least one processor of a user device executes the computer-executable instructions, the user device executes the above-mentioned various possible methods. Among them, the computer-readable medium includes a computer storage medium and a communication medium, wherein the communication medium includes any medium that facilitates the transmission of a computer program from one place to another. The storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer. An exemplary storage medium is coupled to a processor so that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an ASIC. In addition, the ASIC can be located in a user device. Of course, the processor and the storage medium can also exist in a communication device as discrete components.

[0100] The present application also provides a program product, which includes a computer program. The computer program is stored in a readable storage medium. At least one processor of the server can read the computer program from the readable storage medium. At least one processor executes the computer program so that the server implements any method of the above-mentioned embodiments of the present invention.

[0101] The program product may adopt any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, a system, device or component of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination thereof. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof.

[0102] The above describes the specific embodiments of the present invention. It should be understood that the present invention is not limited to the above specific embodiments, and those skilled in the art may make various modifications or variations within the scope of the claims, which do not affect the essence of the present invention.

Claims

1. A scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle, characterized in that: include: Step 1: Register all modules based on the same interface in the module factory, including: different types of engines, functional components, and readers; Step 2: Read the dynamics description file of the rocket, and identify the relevant information of the target engine to be generated according to the dynamics description file; Step 3: searching for the target engine to be generated in the module factory, and after generating the target engine, importing all functional module description information and the data structure allocated to the target engine into the engine instance of the target engine; Step 4: Generate the corresponding functional module in the functional module description information and register the message on the message bus; Step 5: Start the bus and serial port driver related to the target engine, and start the background thread related to the target engine; Step 6: In one calculation step, all functional modules maintained by the target engine are uniformly called through the Update function to complete the update of the target engine; Step 7: In one calculation step, the integral parameter set {x} and the differential component set {dx} are refreshed through the unified integrator.

2. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to claim 1, characterized in that: The relevant information of the target engine to be generated in step 2 includes: Engine type, subordinate functional module types, initial parameters of each functional module, input / output relationship with other modules, input / output parameter types, dimensions and values.

3. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to claim 1, characterized in that: The step 4 comprises: Step 4.1: Searching and dynamically generating the function module corresponding to the function module description information in the module factory; Step 4.2: Determine the initial parameters of each functional module, the input / output relationship with other modules, and the input / output parameters; Step 4.3: Register the message on the message bus to complete the mapping between the message and the behavior.

4. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to claim 1, characterized in that: When the functional module in step 6 uses a finite state machine to implement state migration as the state changes, or sends a message to other modules through a soft bus, all functional modules maintained by the target engine are uniformly called through the Update function, so that other modules connected to the functional module respond to the received message and execute the corresponding function.

5. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to any one of claims 1 to 4, characterized in that: Also includes: When there is an error in the input / output relationship between the functional modules in step 2, a corresponding first-type error code is returned, where the first-type error code is used to indicate that there is an error in the connection relationship between the functional modules.

6. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to any one of claims 1 to 4, characterized in that: Also includes: When the description of the engine type in the dynamics description file cannot be correctly identified in the module factory, a corresponding second-type error code is returned, and the second-type error code is used to indicate that the construction of the simulation scheduling engine has failed.

7. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to any one of claims 1 to 4, characterized in that: Also includes: When the functional module to which the target engine belongs cannot be identified and the functional module cannot be generated, a corresponding third-type error code is returned, and the third-type error code is used to indicate failure in constructing the simulation scheduling engine.

8. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to any one of claims 1 to 4, characterized in that: If the object maintained by the target engine to be generated is an engine queue with a unified interface, the method includes: Register all modules based on the same interface in the module factory, including: different types of engines, functional components, and readers; The target engine is defined as the root engine, a dynamics description file of the rocket is read, and relevant information of the root engine to be generated is identified according to the dynamics description file; Searching for a root engine to be generated in the module factory, and after generating the root engine, importing all subordinate sub-engine description information and the data structure allocated to the root engine into the engine instance of the root engine; Search and dynamically generate sub-engines in the description information in the module factory, determine the number and engine type of sub-engines to which the root engine belongs, determine the initial parameters of each sub-engine, the input / output relationship with other sub-engines, and the input / output parameters, and register messages on the message bus to complete the mapping between messages and behaviors; Traverse all sub-engines under the root engine, start the bus and serial port drivers related to the root engine, and start the background thread related to the root engine; In one calculation step, all sub-engines maintained by the root engine are called in sequence through the Update function to complete the update of the root engine, wherein each sub-engine relies on the message bus of the root engine to complete the message transmission and function call between sub-engines; In one calculation step, all sub-engines are called in sequence through a unified integrator to refresh the integral parameter set {x} and the differential component set {dx}.

9. The scheduling method for a cross-platform simulation engine for a general-purpose launch vehicle according to claim 8, characterized in that: When the root engine includes two sub-engines, the two sub-engines are divided into a communication engine and a computing engine according to their functions, wherein: Before the calculation engine starts calculation, the communication engine is updated to complete the reading of navigation information on the bus and the serial port; After reading the message content, sending the message to the computing engine; The calculation engine starts calculation after receiving the message, and after completing the integral update, feeds back calculation completion information to the communication engine, so that the communication engine organizes messages to the bus, serial port, and Ethernet module.

10. A scheduling system for a cross-platform simulation engine for a general-purpose launch vehicle, characterized in that: Steps for implementing the scheduling method of a cross-platform simulation engine for general-purpose launch vehicles as described in any one of claims 1 to 9; the system comprises: The module factory is used to maintain all module types registered with reference to the unified interface, dynamically generate different module instances according to external requirements, and cancel registered module types; maintain all engine types registered with reference to the unified interface, dynamically generate different engine instances according to external requirements, and cancel registered engine types; maintain all configuration file reader types registered with reference to the unified interface, dynamically generate different readers according to external requirements, and cancel registered reader types; The functional module contains classes with various unified interface functions, which are used to characterize a certain component on the rocket with a mathematical model internally, and has three types of data: initial parameters, input, and output. In each calculation step, it refreshes input data, performs numerical calculations and integration, and outputs module data in sequence, thus completing the implementation of functions and data interaction with other functional modules. The engine is used to receive the launch vehicle dynamics model description from the outside, dynamically generate corresponding modules in the module factory according to the launch vehicle dynamics model description, maintain and initialize all module instances; in each calculation step, all modules under it are updated uniformly through the Update function; in each calculation step, the integration of all subordinate modules is uniformly completed through the Derive function; Finite state machine, used to control the functional module to complete the corresponding state switching behavior according to the external identifier, so as to maintain its own state and clarify the module behavior; The message soft bus is used to define the message subject and message type, maintain the instructions corresponding to each module function, and complete the message registration; accept instructions issued by any module; index and schedule corresponding behaviors in the registered messages; The file reader is used to read the rocket dynamics model described in the configuration file, allocate memory space for the rocket dynamics model, and determine the type of engine called; convert the text description into a data structure that can be read by the engine.

Citation Information

Patent Citations

  • Simulation model management system supporting multiple simulation engines and simulation model scheduling method

    CN115964131A

  • Model independent simulation

    US20070038416A1