Amesim-based element model and system model storage and knowledge integration method
By adopting the management method and knowledge association function of web page plus database in AMESim, the problems of management and reuse of AMESim component model and system model are solved, efficient model use and knowledge reference are achieved, and design efficiency and accuracy are improved.
Patent Information
- Application Number
- CN202411438385.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-15
- Publication Date
- 2025-02-14
AI Technical Summary
The prior art is difficult to manage and reuse mature AMESim component models and system models in a unified manner, and designers lack systematic explanations and knowledge correlations when using these models, resulting in difficulty in understanding parameter settings.
The C/S and B/S management methods of web page plus database are adopted to realize the precise storage and management of AMESim component models and system models, and bind and associate the model with corresponding knowledge, providing convenient knowledge viewing and citation functions.
It realizes unified management and reuse of AMESim component model and system model, improves designers' work efficiency, ensures seamless connection from virtual design to actual products, and improves work accuracy and versatility.
Smart Images

Figure CN119443229A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of knowledge engineering, and in particular relates to a component model and system model storage and knowledge integration method based on Amesim. Background Art
[0002] AMESim software is widely used in system simulation. With the progress of simulation work, many mature component models and system models have been established. For the same component model or system model, component models or system models with different parameters that are adapted to different actual model specifications or actual system performance have also been established. These component models or system models can be used by different designers in different system simulations. However, these mature component models and system models are usually kept in the hands of individual designers, so it is necessary to manage these component models and system models in a unified manner. These component models and system models usually have only simple descriptions, no systematic descriptions, especially no association with corresponding standards and technical documents, resulting in a designer sharing the component model or system model he established with other designers. It is difficult for other designers to understand the parameter settings of the component model and system model, especially why it is set so and why the system model is so simplified. Therefore, in order to enable different designers to have a more detailed understanding of the component or system after selecting the corresponding component model or system model, it is necessary to integrate the component model or system model with the corresponding knowledge. Summary of the invention
[0003] Purpose of the invention: A method for storing component models and system models and integrating knowledge based on AMESim is proposed to achieve unified management of mature component models and system models, and promote their reuse in a convenient way. AMESim component models and system models are accurately saved in a one-to-one manner using the C / S and B / S management methods of web pages plus databases. Mature component model parameters are stored in the database in a clear table form and remotely managed on the web page. At the same time, the component model and system model are bound and associated with knowledge, so that users can view and reference relevant knowledge content at any time during system model design, simulation analysis or task execution, thereby completing work more efficiently. This binding logic expands the ease of use of AMESim. In actual application, users can directly download the required component model or system model, and the plug-in will automatically write the configured parameters directly into the component model, thereby ensuring that AMESim components can be flexibly reused. When closely associated with actual products, the AMESim plug-in can realize an automated conversion process, and conveniently view the knowledge corresponding to the component model and system model during use. Ensure seamless connection from virtual design to actual products, further improving work efficiency and accuracy. This not only enhances the convenience of work, but also improves its versatility.
[0004] Technical Solution
[0005] A component model and system model storage and knowledge integration method based on Amesim, the steps are as follows:
[0006] Step 1: Configure the storage database address, user information, and working directory, where the storage database includes sub-libraries such as component library, system library, and knowledge base;
[0007] Step 2: Create component models and system models, and upload component models and system models to corresponding libraries;
[0008] Step 3: Import the component model and system model saved in the component library and system library into AMESim;
[0009] Step 4: Associate component models and system models with knowledge.
[0010] Further, in step one, the specific process is as follows:
[0011] Set the storage database address for data transmission;
[0012] Define the working directory and select a local path as the working directory to store temporary files;
[0013] User information includes: Fingerprint authentication: the user authenticates through a fingerprint scanner; Key acquisition: the system generates or extracts a key for the user based on the fingerprint matching result; Key verification: verifying the validity of the key by calling the TokenWS Web service interface;
[0014] Check the interface response: Analyze the data returned by the TokenWS Web service interface to confirm whether it contains a success flag; if the configuration is successful, save the encrypted configuration information to a database or other persistent storage for subsequent use.
[0015] Furthermore, in step 2, the component model uploading process is as follows:
[0016] 1a. Open or create a new file in AMESim;
[0017] 1b. Drag and drop the required component model into the file, edit the component model properties and save it as a .ame file;
[0018] 1c. Use XmlDocument to parse the component model information in the .ame file, including component model attributes and positions, and then bind this information to the DataTable data structure;
[0019] 1d. Display the component model information in the DataTable on the interface for users to select;
[0020] 1e. The user selects the component model to be uploaded from the displayed list. The system captures the properties of the selected component model and writes these properties to a JSON file.
[0021] 1f. The user specifies the target component library node to which the component model will be uploaded;
[0022] 1g. Compress and merge the .ame file and the property JSON file into one archive file;
[0023] 1h. Use HttpWebRequest to create an HTTP request, set the necessary request headers, and set the timeout;
[0024] 1i. Use BinaryReader to read the file content, convert it into a byte stream, and read the file in a loop in 4KB segments, and upload it through HttpWebRequest;
[0025] 1j. After the upload is completed, get the response from the storage database through WebResponse and parse the returned data to confirm the upload status;
[0026] 1k. Use the POST method of the RESTful interface to record the upload log, including the user key, file name, file ID, and upload device information;
[0027] 1l. The storage database returns the storage ID of the file for subsequent query of file information and downloading of files.
[0028] Furthermore, in step 2, the upload process of the system model is as follows:
[0029] 2a. Open or create a new ame file in the AMESim software environment;
[0030] 2b. Build the system model by dragging component models, connecting component models, and filling in component model properties;
[0031] 2c. Use the XmlDocument method to parse the ame suffix file in the previous step, and obtain the component model and its attributes and location information through the CIRCUIT node;
[0032] 2d. After parsing all component model information, write the attributes into a json file;
[0033] 2e. Compress the ame file and its attribute files into one package;
[0034] 2f. When the system model is ready to be uploaded, the storage database is accessed through the RESTful API to obtain the system model data, and the data is displayed to the user in a tree structure so that the user can select the corresponding system model;
[0035] 2g. Use HttpWebRequest to create an HTTP request and set a timeout; add a key to the request header to verify the user's identity;
[0036] 2h. Use BinaryReader to read the file and convert it into a byte stream. Loop through the file in 4KB segments and upload it using the HttpWebRequest object created previously.
[0037] 2i. After starting to upload, get the response from the storage database through WebResponse and parse the returned data;
[0038] 2j. Perform the next step based on the parsed information;
[0039] 2k. Use the POST method of the RESTful interface to record the upload log, which includes the user key, file name, file ID, and upload device information;
[0040] 2l. After the upload is completed, the storage database returns the storage ID of the file, which can be used for subsequent query of file information and downloading of files.
[0041] Furthermore, in step 3, the component model import process is as follows:
[0042] 3a. Open or create a new ame file in AMESim;
[0043] 3b. Select the import function, access the storage database interface through the RESTful API to obtain the component library data, and display the component library content in a tree structure;
[0044] 3c. Select the component model to be imported;
[0045] 3d. Get the download link of the selected component model file;
[0046] 3e. Create a local storage folder to store the downloaded files;
[0047] 3f. Use HttpWebRequest to create an HTTP request to download the file;
[0048] 3g. If the file name is known, create the file with that name; otherwise, use the file name in the Content-Disposition parameter returned by the request;
[0049] 3h. Use FileStream to write the file into the created file through the obtained byte array;
[0050] 3i. Use the POST method of the RESTful interface to record the download log, which includes the user key, file name, file ID and download device information;
[0051] 3j. Unzip the file and parse the file according to the attribute json;
[0052] 3k. Use the AMEAddComponent method in AMESIM_API to loop and add component models;
[0053] 3l. Then use the AMESetParameterValue method in AMESIM_API to write properties to the component model;
[0054] 3m. Finally, use the AMESaveCircuit method in AMESIM_API to save the ame file.
[0055] Further, in step three, the system model import process is as follows:
[0056] 4a. Log in through the storage database login interface and configuration information;
[0057] 4b. Access the storage database interface through RESTful, obtain the system model library data, and display the data in a tree structure;
[0058] 4c. Select the system model to be imported in the tree structure;
[0059] 4d. Get the download link of the selected system model file;
[0060] 4e. Create a local storage folder to store the downloaded files;
[0061] 4f. Use HttpWebRequest to create an HTTP request to download the file;
[0062] 4g. If the file name is known, create the file with that name; otherwise, use the file name in the Content-Disposition parameter returned by the request;
[0063] 4h. Use FileStream to write the file into the created file through the obtained byte array;
[0064] 4i. Use the POST method of the RESTful interface to record the download log, which includes the user key, file name, file ID and download device information;
[0065] 4j. After downloading the file, unzip it and open the file with the ame suffix.
[0066] Further, in step 4, the knowledge includes:
[0067] Standard specification, selecting applicable standards and accurately mapping specific clauses to the components and systems under design;
[0068] Scientific and technological literature, find and link relevant research reports and technical documents to provide theoretical basis and support for components and systems;
[0069] Methods and steps, organize and cite detailed implementation procedures and operation guidelines;
[0070] Technical experts, authoritative experts in related fields, provide professional advice and guidance for the design of components and systems;
[0071] Risk measures provide possible risks and problems, and provide solutions to potential problems;
[0072] Frequently Asked Questions, which collects problems encountered in previous projects and their solutions;
[0073] Technical documents store relevant specifications and manuals.
[0074] Furthermore, in step 4, the component model association knowledge process is as follows:
[0075] 5a. After the component model is successfully uploaded, the component model is managed using the data repository;
[0076] 5b. In the storage database, view the AMESim component library;
[0077] 5c. Select the AMESim component model that needs to be associated with knowledge, and obtain the node ID of the component model; the database automatically creates a knowledge association form, which contains keywords such as knowledge type and knowledge item, used to record knowledge type and knowledge ID, etc., and can be expanded to multiple knowledge types and knowledge items. Knowledge items are subordinate to knowledge types, so that knowledge can be classified by knowledge type when displayed. At the same time, multiple component model and system model indexes are established in the knowledge items.
[0078] 5d. According to the selected component model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The content of the knowledge items should include the determination method of each parameter setting of the component model and the standard specifications followed. Multiple knowledge types and multiple knowledge items can be selected at the same time. ;
[0079] 5e. After selecting the knowledge entry, use the RESTful interface KECombine to store the component model ID, knowledge type and knowledge ID in the knowledge association form of the data repository to form an association reference. The data repository will record the component model ID, knowledge ID, component model type and knowledge type. One component model can be associated with multiple pieces of knowledge and knowledge types.
[0080] 5f. After association, when viewing the component model, you can obtain all associated knowledge categories and knowledge IDs through the component model ID in the data repository, and view specific knowledge information through the knowledge ID; you can also know which component models and system models the knowledge is applied to through the component model and system model indexes in the knowledge entry.
[0081] 5g. When you use the component model later, you can view the relevant knowledge associated with the component model.
[0082] Furthermore, in step 4, the system model association knowledge process is as follows:
[0083] 6a. After the system model is uploaded successfully, use the data repository to manage the system model;
[0084] 6b. View the AMESim system model in the storage database;
[0085] 6c. Select the AMESim system model that needs to be associated with knowledge; the database automatically creates a knowledge association form, which contains keywords such as knowledge type and knowledge item, used to record knowledge type and knowledge ID, etc. Multiple knowledge types and knowledge items can be expanded. Knowledge items are subordinate to knowledge types, so that knowledge items can be classified by knowledge type when displayed. At the same time, multiple component model and system model indexes are established in the knowledge items.
[0086] 6d. According to the selected system model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The knowledge items should include the determination methods of component model and system model parameter settings and the standards and specifications followed, system model simplification methods, etc. You can select multiple knowledge types and multiple knowledge items at the same time.
[0087] 6e. After selecting the knowledge item, store the knowledge type and knowledge ID of the knowledge with the system model ID in the database knowledge association form to form an association reference. The data repository will record the system model ID and knowledge ID as well as the system model type and knowledge type. One system model can be associated with multiple pieces of knowledge and knowledge types;
[0088] 6f. When you use the system model later, you can view the related knowledge associated with the system model. You can also know which component models and system models the knowledge is applied to through the component model and system model index in the knowledge entry.
[0089] In summary, the beneficial effects of the present invention are as follows:
[0090] 1) Unified management of customer-customized AMESim component models and system models, models are reused, and the work efficiency of designers is improved;
[0091] 2) AMESim component models and system models are associated with knowledge. Designers can refer to the relevant standards, specifications, literature and other knowledge of component models and system models to know how and why each parameter is set, why the system model is built in this way, and how to simplify it. BRIEF DESCRIPTION OF THE DRAWINGS
[0092] Figure 1 It is a schematic diagram of the system model knowledge business process;
[0093] The AMESim system library in the storage database is classified according to system models. Each type of system model contains several system models with specific parameters. The system model is associated with the knowledge base through knowledge attributes, and is specifically associated with specific knowledge items in the technical expert library, method step library, etc.
[0094] Reference the system model containing specific parameters in AMESim software to form an instantiated system model. The instantiated system model can view various related knowledge items.
[0095] Figure 2 It is a schematic diagram of the component model knowledge business process;
[0096] The AMESim component library in the storage database is classified by component models. Each type of component model contains several customized component models with specific parameters. The component model is associated with the knowledge base through knowledge attributes, and is specifically associated with specific knowledge items in the technical expert library, method step library, etc.
[0097] In AMESim software, the customized component model containing specific parameters is referenced to form an instantiated component model. The instantiated component model can view various related knowledge items.
[0098] Figure 3 This is a schematic diagram of the plug-in operation process;
[0099] Open the AMESim file, design the component model, set the specific parameters of the component model and extract the parameters, upload the component model to the component library, then associate the knowledge and store it in the database, then you can view the knowledge.
[0100] When downloading component models to files, you can also view knowledge and write parameters into component models. You can download multiple component models and combine them to generate a system model.
[0101] Figure 4 It is a schematic diagram of the class diagram;
[0102] The classes used for method implementation mainly include AMESIM_API, AMESIMModel, SUBMODEl, etc., among which the API used by all AMESim operations includes initialization, creating component models, connecting wires, writing properties to component models, saving ame files, and opening ame files. AMESIMModel is used to extract the component model properties of AMESim and upload them to the storage database after structuring. SUBMODEl is a subclass of AMESimModel, which mainly reflects the various properties of the AMESim component model.
[0103] Figure 5 This is a schematic diagram of the AMESim_API class properties;
[0104] AMESim_API class includes AMESim_API, AME_COPPILER, AME_PAR_VAR_FLAG, etc. AME_COPPILER is an enumeration object used to describe the compilation method used by the file. AME_PAR_VAR_FLAG is an enumeration object used to list the properties of AMESim in enumeration mode.
[0105] Figure 6 This is the schematic diagram of the AMESim component library;
[0106] The AMESim component library interface is shown in the figure, including tree structure classification and specific component models. The specific component model interface includes details, parameters, as well as standards, specifications, scientific and technological literature and other knowledge.
[0107] Figure 7 This is the schematic diagram of the AMESim system library;
[0108] The AMESim system library interface is shown in the figure, which includes classification and specific system models. The specific system models include models, simulation results, standard specifications, scientific and technological literature and other knowledge.
[0109] Figure 8 For AMESim plugin - upload schematic diagram;
[0110] The interface is as shown in the figure. On the left is the tree-structured system library and component library obtained from the storage database; on the upper right is the AMESim file that needs to be opened; on the lower right is the component model loaded from the AMESim file to confirm the upload.
[0111] Fig. 9 Download schematic for AMESim plugin.
[0112] The interface is as shown in the figure. Select to obtain the model in the component library or system library from the storage database. You can save it as or open the model directly. DETAILED DESCRIPTION
[0113] In order to accurately store components and their parameter models and save parameter information at the same time, the present invention is based on a Java-based storage database platform and uses Oracle database as a storage medium to achieve management of AMESim component models and parameters.
[0114] In the browser platform, system model management is the main focus, and component model management is the auxiliary, which records the system model and component model generated by AMESim software during work. The underlying platform uses Java language, Spring framework, and Oracle database.
[0115] In the platform, in order to ensure that knowledge can be seamlessly integrated into the use of system models and component models, the knowledge ID needs to be bound to the AEMSim component or system model. The specific binding logic is to write the corresponding knowledge ID into each component model or system model. Through this operation, whether uploading or downloading component models and system models, the corresponding knowledge content can be easily obtained through the knowledge ID. When using the AMESim plug-in, the knowledge related to the model and component can be viewed through simple operations.
[0116] The present invention includes four modules: configuration, upload, import, and associated knowledge. The module functions are as follows:
[0117] 1) Configuration: used to configure the address of the storage database, user login information and working directory. Ensure that all data can be accessed correctly and users can easily manage personal settings.
[0118] 2) Upload: The upload module is divided into component model upload and system model upload. In order to facilitate the management of component models and systems, AMESim component library and AMESim system library are established respectively.
[0119] Component model upload: You can upload custom component models to the AMESim component library. The component library is a warehouse that centrally stores various AMESim component models (such as pumps, valves, springs, gears, cylinders, etc.), supports reuse, and improves design efficiency.
[0120] System model upload: You can upload the complete system model to the AMESim system model library. The system model library is a database dedicated to saving AMESim system models, which allows users to call existing system models for viewing and editing at any time.
[0121] 3) Import: The import module is divided into component model import and system model import, which imports the component model and system model saved in the storage database into AMESim.
[0122] 4) Associated knowledge: Link the existing component models and system models in the storage database with related knowledge documents. When using component models or system models, users can directly access related knowledge and technical documents to facilitate in-depth understanding of their working principles and application scope.
[0123] The function implementation method is as follows:
[0124] 1) Configuration:
[0125] a.Configure the storage database address and working directory
[0126] Set the storage database address: Determine the storage database address for data transmission (for example, https: / / myserver.example.com).
[0127] Define the working directory: Select a local path as the working directory to store temporary files (for example, / tmp / myproject).
[0128] Encrypted storage configuration information: Use an encryption algorithm to encrypt the information storing the database address and working directory, and save it to a secure location.
[0129] b. User Authentication
[0130] Fingerprint Authentication: Users authenticate themselves via a fingerprint scanner.
[0131] Key acquisition: The system generates or extracts a key for the user based on the fingerprint matching result.
[0132] Key verification: Verify the validity of the key by calling the TokenWS Web service interface. If the verification is successful, it means that the user's identity has been confirmed by the system.
[0133] c. Determine whether the configuration is successful
[0134] Check the interface response: Analyze the data returned by the TokenWS interface to confirm whether it contains a success flag.
[0135] Persistent configuration: If the configuration is successful, the encrypted configuration information is saved to a database or other persistent storage for subsequent use.
[0136] 2) Upload
[0137] a) Upload component models
[0138] a. Open or create a new file in AMESim;
[0139] b. Drag and drop the required component model into the file, edit the component model properties and save it as an .ame file;
[0140] c. Use XmlDocument to parse the component model information in the .ame file, including component model properties (such as pump name, rated pressure and flow, etc.) and location, and then bind this information to the DataTable data structure;
[0141] d. Display the component model information in the DataTable on the interface for users to select;
[0142] e. The user selects the component model to be uploaded from the displayed list. The system captures the properties of the selected component model (such as Alias, Component, Submodel, etc.) and writes these properties to the JSON file;
[0143] f. The user specifies the target component library node where the component model will be uploaded;
[0144] g. Compress and merge the .ame file and the property JSON file into one archive file;
[0145] h. Create an HTTP request using HttpWebRequest, set the necessary request headers (such as a key to verify the user's identity), and set a timeout;
[0146] i. Use BinaryReader to read the file content, convert it into a byte stream, and read the file in a loop in 4KB segments, and upload it through HttpWebRequest;
[0147] j. After the upload is completed, get the response from the storage database through WebResponse and parse the returned data to confirm the upload status;
[0148] k. Use the POST method of the RESTful interface to record the upload log, including the user key, file name, file ID, and upload device information;
[0149] l. The storage database returns the storage ID of the file for subsequent query of file information and downloading of files.
[0150] b) Upload the system model
[0151] a. Open or create a new ame file in the AMESim software environment;
[0152] b. Build the system model by dragging component models, connecting component models, and filling in component model properties;
[0153] c. Use the XmlDocument method to parse the ame suffix file in the previous step, and obtain the component model and its attributes and location information through the CIRCUIT node;
[0154] d. After parsing all component model information, properties such as Alias, Component, Submodel, etc. are written into the json file;
[0155] e. Compress the ame file and its attribute files into one package;
[0156] f. When preparing to upload the system model, access the storage database through the RESTful API to obtain the model data, and display it to the user in a tree structure so that the user can select the corresponding system model;
[0157] g. Use HttpWebRequest to create an HTTP request and set a timeout; add a key to the request header to verify the user's identity;
[0158] h. Use BinaryReader to read the file and convert it into a byte stream, read the file in a loop in 4KB segments, and upload it using the HttpWebRequest object created previously;
[0159] i. After starting to upload, get the response from the storage database through WebResponse and parse the returned data;
[0160] j. Execute the next step based on the parsed information;
[0161] k. Use the POST method of the RESTful interface to record the upload log, which includes the user key, file name, file ID, and upload device information;
[0162] l. After the upload is completed, the storage database returns the storage ID of the file, which can be used for subsequent query of file information and downloading of files.
[0163] 3) Import
[0164] a) Import of component models
[0165] a. Open or create a new ame file in AMESim;
[0166] b. Select the import function, access the storage database interface through the RESTful API to obtain component library data, and display the component library content in a tree structure;
[0167] c. Select the component model to be imported;
[0168] d. Get the download link of the selected component model file;
[0169] e. Create a local storage folder to store the downloaded files;
[0170] f. Use HttpWebRequest to create an HTTP request to download files;
[0171] g. If the file name is known, create the file with that name; otherwise, use the file name in the Content-Disposition parameter returned by the request;
[0172] h. Use FileStream to write the file into the created file through the obtained byte array;
[0173] i. Use the POST method of the RESTful interface to record download logs, including user key, file name, file ID, and download device information;
[0174] j. Unzip the file and parse the file according to the attribute json
[0175] k. Use the AMEAddComponent method in AMESIM_API to add component models in a loop
[0176] l. Then use the AMESetParameterValue method in AMESIM_API to write attributes to the component model
[0177] m. Finally, use the AMESaveCircuit method in AMESIM_API to save the ame file
[0178] b) Import of system model
[0179] a. Log in through the storage database login interface and configuration information;
[0180] b. Access the storage database interface through RESTful, obtain the system model library data, and display the data in a tree structure;
[0181] c. Select the system model to be imported in the tree structure;
[0182] d. Get the download link of the selected system model file;
[0183] e. Create a local storage folder to store the downloaded files;
[0184] f. Use HttpWebRequest to create an HTTP request to download files;
[0185] g. If the file name is known, create the file with that name; otherwise, use the file name in the Content-Disposition parameter returned by the request;
[0186] h. Use FileStream to write the file into the created file through the obtained byte array;
[0187] i. Use the POST method of the RESTful interface to record download logs, including user key, file name, file ID, and download device information;
[0188] j. After downloading the file, unzip it and open the file with the ame suffix
[0189] 4) Related knowledge
[0190] In order to manage and utilize knowledge more effectively, a knowledge base is specially constructed. The knowledge base includes sub-bases in categories such as standards and specifications, scientific and technological literature, methods and procedures, technical experts, risk measures, common problems, and technical documents.
[0191] Standards and specifications: Various applicable technical standards and specifications are included. Users can select appropriate standards according to their needs and ensure that each component and system in the design strictly complies with these standards to meet industry requirements.
[0192] Scientific and technological literature: Contains a wealth of research reports and technical documents. Users can consult these materials to provide a solid theoretical basis and technical support for the components and systems in the design.
[0193] Methods and Steps: Detailed operation guidelines and implementation processes are provided to ensure that each step in the design plan can be executed accurately, thereby improving the efficiency and quality of the entire project.
[0194] Technical experts: It brings together expert information from various fields. Users can seek professional opinions and guidance from these experts during the design process to ensure the advancement and feasibility of the design.
[0195] Risk measures: Lists various risks and problems that may be encountered, and provides corresponding preventive measures and solutions to help avoid potential problems in the early stages of design.
[0196] Frequently Asked Questions: Based on past project experience, here is a summary of common problems and solutions that can help users quickly solve problems and avoid repeating mistakes.
[0197] Technical documents: Various technical documents are stored, such as specifications, operating manuals, etc., to ensure that every detail of the design plan has a basis, and it also facilitates subsequent production and maintenance work.
[0198] a) Component model related knowledge
[0199] a. After the component is successfully uploaded, use the data repository to manage the component;
[0200] b. In the storage database, view the AMESim component library;
[0201] c. Select the AMESim component that needs to be associated with knowledge, and obtain the node ID of the component; the database automatically creates a knowledge association form, which contains keywords such as knowledge type and knowledge item, used to record knowledge type and knowledge ID, etc. Multiple knowledge types and knowledge items can be expanded, and knowledge items are subordinate to knowledge types, so that knowledge can be classified by knowledge type when displayed. At the same time, multiple component model and system model indexes are established in the knowledge items.
[0202] d. According to the selected component model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The content of the knowledge items should include the determination method of each parameter setting of the component model and the standard specifications followed. You can select multiple knowledge types and multiple knowledge items at the same time.
[0203] e. After selecting the knowledge entry, use the RESTful interface KECombine to store the model ID and knowledge ID in the knowledge association form of the data repository to form an association reference. The data repository will record the component model ID, knowledge ID, model type, knowledge type and other information. A component model can be associated with multiple pieces of knowledge and knowledge types;
[0204] f. After association, when viewing the model, you can obtain all associated knowledge categories and knowledge IDs through the model ID in the data repository, and view specific knowledge information through the knowledge ID; you can also know which component models and system models the knowledge is applied to through the component model and system model indexes in the knowledge entry.
[0205] g. When using the model in the future, you can view the relevant knowledge associated with the component model, such as component parameter setting requirements and corresponding specifications.
[0206] b) System model related knowledge
[0207] a. After the system model is uploaded successfully, use the data repository to manage the model;
[0208] b. View the AMESim system model in the storage database;
[0209] c. Select the AMESim model that needs to be associated with knowledge; the database automatically creates a knowledge association form, which contains keywords such as knowledge type and knowledge item, used to record knowledge type and knowledge ID, etc. Multiple knowledge types and knowledge items can be expanded. Knowledge items are subordinate to knowledge types, so that knowledge items can be classified by knowledge type when displayed. At the same time, multiple component model and system model indexes are established in the knowledge items.
[0210] d. According to the selected system model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The knowledge items should include the determination methods of component model and system model parameter settings and the standards and specifications followed, system model simplification methods, etc. You can select multiple knowledge types and multiple knowledge items at the same time.
[0211] e. After selecting a knowledge entry, the knowledge type and knowledge ID of the associated knowledge and the model ID are stored in the database knowledge association form to form an association reference. In addition, the data repository will also record the knowledge category and model category at the same time, in order to better classify and store data, as well as for subsequent search and reference. A model can be associated with multiple pieces of knowledge and knowledge types;
[0212] f. When using the model in the future, you can view the relevant knowledge associated with the model, such as the technical documents of the related system required for the system model parameter setting. You can also know which component models and system models the knowledge is applied to through the component model and system model index in the knowledge entry.
[0213] System model and component model view reference knowledge flow such as Figure 1 and Figure 2 .
[0214] The plug-in design process is as follows Figure 3 As shown, after the model is split according to components, component parameters are obtained in batches and the data is uploaded. When needed in the working model, the component combination is downloaded and the component parameters are written. The components are merged to generate a new ame file, i.e., a new system model.
[0215] AMESim plug-in usage classes mainly include AMESIM_API, AMESIMModel, SUBMODEl and other classes, such as Figure 4 .
[0216] AMESim_API class attributes such as Figure 5 shown.
Claims
1. A component model and system model storage and knowledge integration method based on Amesim, characterized by: Here are the steps: Step 1: Configure the storage database address, user information, and working directory, where the storage database includes component library, system library, and knowledge base; Step 2: Create component models and system models, and upload component models and system models to corresponding libraries; Step 3: Import the component models and system models saved in the component library and system library into AMEsim; Step 4: Associate component models and system models with knowledge.
2. The method according to claim 1, characterized in that: In step one, the specific process is as follows: Set the storage database address for data transmission; Define the working directory and select a local path as the working directory to store temporary files; User information includes: Fingerprint authentication: the user authenticates through a fingerprint scanner; Key acquisition: the system generates or extracts a key for the user based on the fingerprint matching result; Key verification: verifying the validity of the key by calling the TokenWS Web service interface; Check the interface response: Analyze the data returned by the TokenWS Web service interface to confirm whether it contains a success flag; if the configuration is successful, save the encrypted configuration information to a database or other persistent storage for subsequent use.
3. The method according to claim 2, characterized in that: In step 2, the component model upload process is as follows: 1a. Open or create a new file in AMESim; 1b. Drag and drop the required component model into the file, edit the component model properties and save it as a .ame file; 1c. Use XmlDocument to parse the component model information in the .ame file, including component model attributes and positions, and then bind this information to the DataTable data structure; 1d. Display the component model information in the DataTable on the interface for users to select; 1e. The user selects the component model to be uploaded from the displayed list, captures the properties of the selected component model, and writes these properties to a JSON file; 1f. The user specifies the target component library node to which the component model will be uploaded; 1g. Compress and merge the .ame file and the property JSON file into one archive file; 1h. Use HttpWebRequest to create an HTTP request, set the necessary request headers, and set the timeout; 1i. Use BinaryReader to read the file content, convert it into a byte stream, and read the file in a loop in 4KB segments, and upload it through HttpWebRequest; 1j. After the upload is completed, get the response from the storage database through WebResponse and parse the returned data to confirm the upload status; 1k. Use the POST method of the RESTful interface to record the upload log, including the user key, file name, file ID, and upload device information; 1l. The storage database returns the storage ID of the file for subsequent query of file information and downloading of files.
4. The method according to claim 3, characterized in that: In step 2, the upload process of the system model is as follows: 2a. Open or create a new ame file in the AMESim software environment; 2b. Build the system model by dragging component models, connecting component models, and filling in component model properties; 2c. Use the XmlDocument method to parse the ame suffix file in the previous step, and obtain the component model and its attributes and location information through the CIRCUIT node; 2d. After parsing all component model information, write the attributes into a json file; 2e. Compress the ame file and its attribute files into one package; 2f. When the system model is ready to be uploaded, the storage database is accessed through the RESTful API to obtain the system library system model data, and the data is displayed to the user in a tree structure for the user to select the corresponding system model; 2g. Use HttpWebRequest to create an HTTP request and set a timeout; add a key to the request header to verify the user's identity; 2h. Use BinaryReader to read the file and convert it into a byte stream. Loop through the file in 4KB segments and upload it using the HttpWebRequest object created previously. 2i. After starting to upload, get the response from the storage database through WebResponse and parse the returned data; 2j. Perform the next step based on the parsed information; 2k. Use the POST method of the RESTful interface to record the upload log, which includes the user key, file name, file ID, and upload device information; 2l. After the upload is completed, the storage database returns the storage ID of the file, which can be used for subsequent query of file information and downloading of files.
5. The method according to claim 4, characterized in that: In step 3, the component model import process is as follows: 3a. Open or create a new ame file in AMESim; 3b. Select the import function, access the storage database interface through the RESTful API to obtain the component library data, and display the component library content in a tree structure; 3c. Select the component model to be imported; 3d. Get the download link of the selected component model file; 3e. Create a local storage folder to store the downloaded files; 3f. Use HttpWebRequest to create an HTTP request to download the file; 3g. If the file name is known, create the file with that name; Otherwise, use the file name in the Content-Disposition parameter returned by the request; 3h. Use FileStream to write the file into the created file through the obtained byte array; 3i. Use the POST method of the RESTful interface to record the download log, which includes the user key, file name, file ID and download device information; 3j. Unzip the file and parse the file according to the attribute json; 3k. Use the AMEAddComponent method in AMESIM_API to loop and add component models; 3l. Then use the AMESetParameterValue method in AMESIM_API to write properties to the component model; 3m. Finally, use the AMESaveCircuit method in AMESIM_API to save the ame file.
6. The method according to claim 5, characterized in that: In step 3, the system model import process is as follows: 4a. Log in through the storage database login interface and configuration information; 4b. Access the storage database interface through RESTful, obtain the system model library data, and display the data in a tree structure; 4c. Select the system model to be imported in the tree structure; 4d. Get the download link of the selected system model file; 4e. Create a local storage folder to store the downloaded files; 4f. Use HttpWebRequest to create an HTTP request to download the file; 4g. If the file name is known, create the file with that name; Otherwise, use the file name in the Content-Disposition parameter returned by the request; 4h. Use FileStream to write the file into the created file through the obtained byte array; 4i. Use the POST method of the RESTful interface to record the download log, which includes the user key, file name, file ID and download device information; 4j. After downloading the file, unzip it and open the file with the ame suffix.
7. The method according to claim 6, characterized in that: In step 4, knowledge includes: Standard specification, selecting applicable standards and accurately mapping specific clauses to the components and systems under design; Scientific and technological literature, find and link relevant research reports and technical documents to provide theoretical basis and support for components and systems; Methods and steps, organize and cite detailed implementation procedures and operation guidelines; Technical experts, authoritative experts in related fields, provide professional advice and guidance for the design of components and systems; Risk measures provide possible risks and problems, and provide solutions to potential problems; Frequently Asked Questions, which collects problems encountered in previous projects and their solutions; Technical documents store relevant specifications and manuals.
8. The method according to claim 7, characterized in that: In step 4, the component model association knowledge process is as follows: 5a. After the component model is successfully uploaded, the component model is managed using the data repository; 5b. In the storage database, view the AMESim component library; 5c. Select the AMESim component model that needs to be associated with knowledge, and obtain the node ID of the component model; the database automatically creates a knowledge association form, which contains knowledge types and knowledge item keywords, and is used to record knowledge types and knowledge IDs. Multiple knowledge types and knowledge item keywords can be expanded, and knowledge items are subordinate to knowledge types, so that knowledge can be classified by knowledge type when displayed; at the same time, multiple component model and system model indexes are established in the knowledge items; 5d. According to the selected component model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The content of the knowledge items should include the determination method of each parameter setting of the component model and the standard specifications followed. Multiple knowledge types and multiple knowledge items can be selected at the same time; 5e. After selecting the knowledge entry, use the RESTful interface KECombine to store the component model ID, knowledge type and knowledge ID in the knowledge association form of the data repository to form an association reference. The data repository will record the component model ID, knowledge ID, component model type and knowledge type. One component model can be associated with multiple pieces of knowledge and knowledge types. 5f. After association, when viewing the component model, you can obtain all associated knowledge categories and knowledge IDs through the component model ID in the data repository, and view specific knowledge information through the knowledge ID; through the component model and system model indexes in the knowledge entry, you can know which component models and system models the knowledge is applied to. 5g. When you use the component model later, you can view the relevant knowledge associated with the component model.
9. The method according to claim 8, characterized in that: In step 4, the system model association knowledge process is as follows: 6a. After the system model is uploaded successfully, use the data repository to manage the system model; 6b. View the AMESim system model in the storage database; 6c. Select the AMESim system model that needs to be associated with knowledge; the database automatically creates a knowledge association form, which contains knowledge types and knowledge item keywords, and is used to record knowledge types and knowledge IDs. Multiple knowledge types and knowledge item keywords can be expanded. Knowledge items are subordinate to knowledge types, so that knowledge items can be classified by knowledge type when displayed; at the same time, multiple component model and system model indexes are established in the knowledge items; 6d. According to the selected system model attributes, search or create corresponding knowledge types and knowledge items in the knowledge base. The knowledge items should include the determination method of each parameter setting of the component model and the system model and the standards and specifications followed, and the system model simplification method; select multiple knowledge types and multiple knowledge items at the same time; 6e. After selecting the knowledge item, the knowledge type and knowledge ID of the knowledge and the system model ID are stored in the database knowledge association form to form an association reference; The data repository will record the ID of the system model, the ID of the knowledge, and the system model type and knowledge type. One system model can be associated with multiple pieces of knowledge and knowledge types. 6f. When you use the system model later, you can view the related knowledge associated with the system model; through the component model and system model indexes in the knowledge entry, you can know which component models and system models the knowledge is applied to.