Data interaction association mapping transmission method for SKTC task model
By adopting the unified data interaction format and mapping rules of the FMI standard, the SysML and Modelica models are exported into FMU format and integrated in a collaborative simulation environment, the problem of inefficient model data interaction is solved and the seamless docking and collaboration of the model is achieved simulation.
Patent Information
- Application Number
- CN202411635636.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-15
- Publication Date
- 2025-02-18
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
SysML and Modelica models require complex transformation processes when data interaction and mapping pass-through, resulting in inefficiency and data loss.
The FMI standard is used to define unified data interaction formats and mapping rules, export SysML and Modelica models into FMU formats through a format that complies with the FMI interface standards, and integrate them in a collaborative simulation environment, so that the two models can be seamlessly connected.
The seamless connection between SysML and Modelica models is realized, ensuring accurate data transfer and model collaborative simulation, greatly improving the interactiveness and reusability of the model.
Smart Images

Figure CN119475796A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of data interaction and association mapping between SysML design models and Modelica simulation models, and in particular relates to a SKTC task model data interaction association mapping transmission method. Background Art
[0002] In the field of deep space exploration, system modeling and simulation are important tools for designing and verifying mission-critical systems. Traditional system modeling methods, such as SysML (System Modeling Language) and Modelica, although powerful in their respective fields, have limitations in data interaction and model mapping.
[0003] The SysML model focuses on the description of the system's requirements, structure, and behavior, while the Modelica model focuses on the simulation of the system's dynamic behavior and physical processes. For example, Chinese patent CN115913990A provides a method for defining the functions and interfaces of a low-orbit communication constellation network based on SysML. The method first analyzes the stakeholders' requirements for the low-orbit communication constellation network based on the SysML use case diagram, sorts out specific communication indicators and indicator performance, and presents them with a SysML requirement diagram; then analyzes the interface relationship of the constellation network service target and the communication network used, and presents them with a SysML internal structure diagram; finally, the behavior of each network system during operation is explained. For example, Chinese patent CN109522602A provides a method for optimizing Modelica model parameters based on proxy model, and the steps are as follows: 1. Compile Modelica model and obtain model parameters and variable information; 2. Optimize modeling; 3. Generate sampling points; 4. Simulate parameter combinations; 5. Analyze simulation results; 6. Build proxy model; 7. Use proxy model to replace Modelica model for optimization iteration to find the optimal parameters; 8. Simulate the optimal parameters. If the error between the simulation result and the output result of proxy model is less than the set value, execute step 10, otherwise execute step 9; 9. Use the simulation result of step 8 to dynamically update the proxy model, and then execute step 7; 10. The optimal parameters calculated in step 7 are the final optimization results, and the parameter optimization is completed; the purpose of improving the optimization efficiency of Modelica model parameters is to solve the practical problem that the amount of calculation in the optimization process of Modelica model parameters is huge and it is difficult to optimize parameters for large models. Chinese patents CN111930345A, CN115913990A, etc., all provide a modeling solution based on SysML.
[0004] Although both models have their own advantages, they often require complex conversion processes during data interaction and mapping transfer, resulting in low efficiency and data loss. Therefore, the present application provides a SKTC task model data interaction association mapping transfer method. Summary of the invention
[0005] The purpose of the present invention is to provide a SKTC task model data interaction association mapping and transmission method. By adopting a unified data interaction format and mapping rule, namely the FMI standard, models constructed by different modeling and simulation tools are exported into an executable FMU (Functional Mock-up Unit) format in accordance with the FMI interface standard, and the FMU is effectively integrated into a collaborative simulation environment, so that the SysML model and the Modelica model can be seamlessly connected, and accurate data transmission and model collaborative simulation are achieved, thereby solving the existing problems.
[0006] In order to solve the above technical problems, the present invention is achieved through the following technical solutions:
[0007] The present invention is a method for interactively associating and mapping data of SKTC task model, comprising the following steps:
[0008] Step S11: defining a unified data exchange format according to the FMI standard, which is used to define data structure, data type and data exchange protocol;
[0009] Step S12: designing mapping rules for associating SysML model elements with Modelica model elements;
[0010] Step S13: calling a data interaction interface to support data reading and writing operations between the SysML model and the Modelica model;
[0011] Step S14: A collaborative simulation environment is used to support joint simulation and result analysis of multiple models.
[0012] Furthermore, the data interaction format uniformly adopts XML or JSON format, and the data interaction format and data exchange protocol comply with the FMI standard, thereby ensuring the interoperability of the model.
[0013] Furthermore, the mapping rules include element attribute mapping and behavior mapping, and after the SysML model elements are associated with the Modelica model elements, the interface provided by FMI is used to implement data reading and writing operations between the SysML model and the Modelica model;
[0014] The name of the configuration file of the mapping relationship is fixed as: config.txt;
[0015] The configuration file path is fixed as:
[0016] %AppData%\Roaming\M-Design-v4\nodeServer.
[0017] Furthermore, the elements in the SysML model and the Modelica model include metadata information of model variables, interfaces, capabilities, and model architecture extension restrictions.
[0018] Furthermore, the elements that need to be sent in the SysML model are carried by opaque expressions in the state machine diagram, and the opaque expressions contain content and language, the content is the data content to be sent to the Modelica model, and the language is Modelica; if the parameter value of the simulation UI needs to be sent, the configuration file is written in a standard format, and "${send}" is filled in the content to obtain the information passed to the Modelica model in the configuration file.
[0019] Furthermore, the data format to be sent in the Modelica model is a digital (integer, floating point) format in the form of: **,** (multiple returned data are separated by English commas, for example: 36.5,55,88,11, this example returns the values of 4 fields). The number of fields contained in a returned data needs to correspond one-to-one to the mapping configuration; similarly, the configuration file needs to be written in a standard format to obtain the information passed to SysML in the configuration file.
[0020] Furthermore, the IP and port of the Modelica model and the port of the SysML model receiving data are sent through the configuration file; the name of the communication configuration file is fixed as:
[0021] application-netty.yml;
[0022] The configuration file path is fixed as:
[0023] %AppData%\Roaming\M-Design-v4\nodeServer.
[0024] Furthermore, the data interaction interface includes API calls and database operations, and the model parameters are set and the calculation steps are triggered through the C-API interface of FMI.
[0025] Furthermore, the collaborative simulation environment supports real-time data updating, supports joint simulation and result analysis of SysML models and Modelica models, and utilizes the joint simulation function of the FMI standard to achieve coupling of multiple simulation programs and mutual coupling between subsystems.
[0026] Furthermore, in the collaborative simulation environment, the joint simulation of SysML models and Modelica models is realized by developing plug-ins. After the plug-in is integrated, it needs to be started manually for the first time. By right-clicking the root directory -> Integration -> MODELICA -> Model Mapping, the page pops up and the model tree on the left is displayed, indicating that the startup is successful.
[0027] The present invention has the following beneficial effects:
[0028] The present invention defines a unified data interaction format and mapping rules, exports the design model and the simulation model into the FMU format in a format that complies with the FMI interface standard, and effectively integrates them in a collaborative simulation environment, so that the two models can be seamlessly connected, achieving accurate data transmission and collaborative simulation of models, and greatly improving the interactivity and reusability of the models.
[0029] Of course, any product implementing the present invention does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for describing the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.
[0031] Figure 1 This is a flow chart of the deep space exploration mission model data interactive association mapping and transmission method of the present invention;
[0032] Figure 2 Sending a data content graph for the SysML model of the present invention;
[0033] Figure 3 Exchange data content and format diagrams for the model of the present invention;
[0034] Figure 4 It is the SysML model diagram of the present invention;
[0035] Figure 5 is a Modelica model diagram of the present invention;
[0036] Figure 6 A communication configuration file diagram of the present invention;
[0037] Figure 7 Launching a plug-in diagram for the joint simulation environment of the present invention;
[0038] Figure 8 A successful start diagram for the joint simulation environment of the present invention;
[0039] Fig. 9 This is a joint simulation result diagram of the present invention. DETAILED DESCRIPTION
[0040] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0041] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0042] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0043] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0044] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0045] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0046] See also Figure 1 As shown, the present invention is a SKTC task model data interaction and mapping transfer method, which aims to achieve efficient data interaction and mapping transfer between SysML models and Modelica models, and adopts a unified data interaction format and mapping rule - FMI standard. Models constructed by different modeling and simulation tools are exported into executable FMU (Functional Mock-up Unit) format in a format that complies with the FMI interface standard, and are effectively integrated in a collaborative simulation environment, so that SysML models and Modelica models can be seamlessly connected, and accurate data transfer and model collaborative simulation are achieved. The method includes the following steps:
[0047] Determine the data elements that need to be interacted between SysML models and Modelica models, and define a unified data interaction format based on the FMI standard to define data structures, data types, and data exchange protocols. These formats and protocols follow the FMI standard to ensure the interoperability of the models.
[0048] According to the defined data exchange format, the data elements are standardized to ensure that the data between different models can be seamlessly connected;
[0049] Design mapping rules to associate SysML model elements with Modelica model elements, use the interface provided by FMI to implement data reading and writing operations between models, and achieve accurate data transmission through FMI's mapping mechanism;
[0050] Call the data interaction interface to support data reading and writing operations between SysML models and Modelica models, and set model parameters and trigger calculation steps through the FMI C-API interface;
[0051] The collaborative simulation environment is used to support the joint simulation and result analysis of multiple models, support data reading and writing operations between SysML models and Modelica models, and use the joint simulation capabilities of the FMI standard to achieve the coupling of multiple simulation programs and the mutual coupling between subsystems.
[0052] As an embodiment provided by the present invention, preferably, the data interaction format uniformly adopts XML or JSON format, and the data interaction format and data exchange protocol comply with the FMI standard, thereby ensuring the interoperability of the model.
[0053] As an embodiment provided by the present invention, preferably, the mapping rules include element attribute mapping and behavior mapping, and after the SysML model element is associated with the Modelica model element, the interface provided by FMI is used to implement the data reading and writing operation between the SysML model and the Modelica model;
[0054] The name of the configuration file of the mapping relationship is fixed as: config.txt;
[0055] The configuration file path is fixed as:
[0056] %AppData%\Roaming\M-Design-v4\nodeServer.
[0057] As an embodiment provided by the present invention, preferably, the elements in the SysML model and the Modelica model include metadata information of model variables, interfaces, capabilities and model architecture extension restrictions.
[0058] As an embodiment provided by the present invention, preferably, the elements to be sent in the SysML model are carried by an opaque expression in the state machine diagram, and the opaque expression contains content and language, the content is the data content to be sent to the Modelica model, and the language is Modelica; if the parameter value of the simulation UI needs to be sent, the configuration file is written in a standard format, and "${send}" is filled in the content to obtain the information passed to the Modelica model in the configuration file, such as Figure 2 shown.
[0059] As an embodiment provided by the present invention, preferably, the data format that Modelica needs to send is a digital (integer, floating point) format, in the form of: **, ** (return multiple data separated by English commas, for example: 36.5, 55, 88, 11, this example returns the values of 4 fields), and the number of fields contained in a returned data needs to correspond to the mapping configuration one by one. Similarly, it is necessary to write a configuration file in a standard format to obtain the information passed to SysML in the configuration file, data interaction content and format, such as Figure 3 shown.
[0060] As an embodiment provided by the present invention, preferably, data elements are standardized according to a defined data interaction format to ensure that data between different models can be seamlessly connected.
[0061] In this embodiment, the standardized processing of the SysML model adopts UI configuration, such as Figure 4 shown.
[0062] In this embodiment, the standardization process of the Modelica model adopts text language, such as Figure 5 shown.
[0063] As an embodiment provided by the present invention, preferably, the IP and port of the Modelica model and the port of the SysML model receiving data are sent through a configuration file, such as Figure 6 As shown; the name of the communication profile is fixed as:
[0064] application-netty.yml;
[0065] The configuration file path is fixed as:
[0066] %AppData%\Roaming\M-Design-v4\nodeServer.
[0067] As an embodiment provided by the present invention, preferably, the data interaction interface includes API calls and database operations, and the model parameters are set and the calculation steps are triggered through the C-API interface of FMI.
[0068] As an embodiment provided by the present invention, preferably, the collaborative simulation environment supports real-time data update, supports joint simulation and result analysis of SysML models and Modelica models, and utilizes the joint simulation function of the FMI standard to achieve coupling of multiple simulation programs and mutual coupling between subsystems.
[0069] As an embodiment provided by the present invention, preferably, in a collaborative simulation environment, a plug-in is developed to realize the joint simulation of the SysML model and the Modelica model. After the plug-in is integrated, it needs to be started manually for the first time by selecting the root directory right key->Integration->MODELICA->Model Mapping, such as Figure 7 As shown, after the page pops up, the model tree on the left is displayed, indicating that the startup is successful. Figure 8 shown.
[0070] As an embodiment provided by the present invention, preferably, the result of the joint simulation is as follows: Fig. 9 As shown, the left side is the SysML model simulation result, and the right side is the Modelica simulation result.
[0071] As an embodiment provided by the present invention, preferably, the mapping relationship between SysML model elements and Modelica model elements is shown in Table 1 below:
[0072] Table 1
[0073]
[0074]
[0075] A data interaction and mapping transfer method for SKTC task models is proposed. By defining a unified data interaction format and mapping rules, the design model and the simulation model are exported to the FMU format in a format that complies with the FMI interface standard, and are effectively integrated in a collaborative simulation environment, so that the two models can be seamlessly connected, and accurate data transmission and model collaborative simulation are achieved, which greatly improves the interactivity and reusability of the model.
[0076] In the description of this specification, the description with reference to the terms "one embodiment", "example", "specific example", etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0077] The preferred embodiments of the present invention disclosed above are only used to help illustrate the present invention. The preferred embodiments do not describe all the details in detail, nor do they limit the invention to the specific implementation methods described. Obviously, many modifications and changes can be made according to the content of this specification. This specification selects and specifically describes these embodiments in order to better explain the principles and practical applications of the present invention, so that those skilled in the art can understand and use the present invention well. The present invention is limited only by the claims and their full scope and equivalents.
Claims
1. A method for interactive association mapping and transmission of SKTC task model data, characterized in that: The following steps are involved: Step S11: defining a unified data interaction format according to the FMI standard, which is used to define data structure, data type and data exchange protocol; and standardizing SysML model elements and Modelica model elements according to the defined data interaction format; Step S12: designing mapping rules for associating SysML model elements with Model ica model elements; Step S13: calling the data interaction interface to support data reading and writing operations between the SysML model and the Model ica model; Step S14: A collaborative simulation environment is used to support joint simulation and result analysis of multiple models.
2. A SKTC task model data interactive association mapping and transmission method according to claim 1, characterized in that: The data interaction format uniformly adopts XML or JSON format, and the data interaction format and data exchange protocol comply with the FMI standard.
3. The SKTC task model data interactive association mapping and transmission method according to claim 2 is characterized in that: The mapping rules include element attribute mapping and behavior mapping. After the SysML model elements are associated with the Modelica model elements, the interface provided by FMI is used to implement the data reading and writing operations between the SysML model and the Modelica model. The name of the configuration file of the mapping relationship is fixed as: config.txt; The configuration file path is fixed as: %AppData%\Roaming\M-Design-v4\nodeServer.
4. The SKTC task model data interactive association mapping and transmission method according to claim 3 is characterized in that: The elements in the SysML model and Modelica model include metadata information of model variables, interfaces, capabilities and model architecture extension restrictions.
5. The SKTC task model data interactive association mapping and transmission method according to claim 3 is characterized in that: The elements that need to be sent in the SysML model are carried by opaque expressions in the state machine diagram. The opaque expressions contain content and language. The content is the data content to be sent to the Modelica model, and the language is Modelica. If the parameter value of the simulation UI needs to be sent, the configuration file is written in the standard format, and "${send}" is filled in the content to obtain the information passed to the Modelica model in the configuration file.
6. The SKTC task model data interactive association mapping and transmission method according to claim 3 is characterized in that: The data format to be sent in the Model ica model is in digital format, in the form of: **,**; Returns a data entry containing the number of fields and mapping configurations in one-to-one correspondence; writes configuration files in a standard format to obtain information passed to SysML in the configuration files.
7. The SKTC task model data interactive association mapping and transmission method according to claim 3 is characterized in that: The IP and port of the Modelica model and the port of the SysML model receiving data are sent through the configuration file; the name of the communication configuration file is fixed as: application-netty.yml; The configuration file path is fixed as: %AppData%\Roaming\M-Design-v4\nodeServer.
8. The SKTC task model data interactive association mapping and transmission method according to claim 1, characterized in that: The data interaction interface includes API calls and database operations, and the model parameters are set and the calculation steps are triggered through the C-API interface of FMI.
9. The SKTC task model data interactive association mapping and transmission method according to claim 1, characterized in that: The collaborative simulation environment supports real-time data update, supports joint simulation and result analysis of SysML models and Modelica models, and utilizes the joint simulation function of the FMI standard to achieve coupling of multiple simulation programs and mutual coupling between subsystems.
10. The SKTC task model data interactive association mapping and transmission method according to claim 1, characterized in that: In the collaborative simulation environment, the joint simulation of SysML model and Modelica model is realized by developing plug-ins. After the plug-in is integrated, it needs to be started manually for the first time. Select the root directory right-click -> Integration -> MODELICA -> Model Mapping. When the page pops up and the model tree on the left is displayed, it indicates that the startup is successful.
Citation Information
Patent Citations
A parameter optimization method of Modelica model based on surrogate model
CN109522602A
Unmanned aerial vehicle system modeling method and device based on SysML and readable storage medium
CN111930345A
Method for defining low-orbit communication constellation network function and interface based on SysML
CN115913990A
Heterogeneous simulation data unified integrated visual method
CN105893667A
Method for supporting AADL integrated simulation by applying FMI protocol
CN111552636A
Cited By
Modelica-based FMU integration method, system, equipment and medium
CN120029654A
Multi-target conflict coordination method for model mapping configuration optimization
CN121072725A