Unit inheritance method, device, electronic device and storage medium of grid model

By generating text files and importing target sets, the units in the grid model are automatically inherited, which solves the tedious problem of manual unit search in finite element analysis, achieves efficient and accurate grid model inheritance, and reduces labor costs.

CN112395682BActive Publication Date: 2024-10-11BYD CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910704552.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-07-31
Publication Date
2024-10-11
Estimated Expiration
2039-07-31

AI Technical Summary

Technical Problem

In finite element analysis, the manual method of finding mesh model elements is cumbersome and error-prone, resulting in poor inheritance results, heavy workload, and high cost.

Method used

Automatically inherit the units in the grid model by generating a text file, import the target collection using the text file, and add the corresponding units to the inheritance collection to achieve automatic inheritance of the grid model.

Benefits of technology

It effectively reduces labor costs, improves the inheritance efficiency and effect of grid units, simplifies the inheritance process of grid models, and improves accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112395682B_ABST
    Figure CN112395682B_ABST
Patent Text Reader

Abstract

The present invention proposes a unit inheritance method, device, electronic device and storage medium of a grid model, wherein the grid model is a CAE grid model, and the method comprises generating a text file according to the information of the unit to be inherited in the first grid model; importing the text file in an application program that loads the second grid model, and creating a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the unit to be inherited; adding the unit in the second grid model corresponding to the information in the text file to the target set, and using the unit added in the target set as some units that inherit the unit to be inherited. The present invention can realize automatic inheritance of some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of the grid units, and improve the inheritance effect.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of vehicle technology, and in particular to a unit inheritance method, device, electronic equipment and storage medium of a grid model. Background Art

[0002] When using Computer Aided Engineering (CAE) for finite element analysis modeling, multiple engineers usually make local modifications to the same CAE mesh model, and then add different loads to perform different types of performance analysis. When engineers need to find mesh cells with the same information (such as identity identifiers) in different modified CAE mesh models, the information to be queried is generally displayed in one CAE mesh model, and then the mesh cells with the corresponding information are manually found step by step in another CAE mesh model by searching by number.

[0003] In this way, the workload is large, and the manual search for inherited grid units is cumbersome and prone to omissions or errors, resulting in poor inheritance effects. Summary of the invention

[0004] The present invention aims to solve one of the technical problems in the related art at least to a certain extent.

[0005] To this end, the purpose of the present invention is to propose a unit inheritance method, device, electronic device and storage medium for a grid model, which can automatically inherit some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0006] To achieve the above-mentioned purpose, a unit inheritance method for a grid model is proposed in an embodiment of the first aspect of the present invention, wherein the grid model is a CAE grid model, comprising: generating a text file based on information of the units to be inherited in the first grid model; importing the text file in an application that loads the second grid model, and creating a new target set based on the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited; adding the units in the second grid model corresponding to the information in the text file to the target set, and using the units added in the target set as some units that inherit the units to be inherited.

[0007] The unit inheritance method of the grid model proposed in the embodiment of the first aspect of the present invention generates a text file according to the information of the units to be inherited in the first grid model, and creates a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited. This can realize the automatic inheritance of some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0008] To achieve the above-mentioned purpose, a unit inheritance device for a grid model proposed in an embodiment of the second aspect of the present invention, wherein the grid model is a CAE grid model, comprises: a first generation module, used to generate a text file according to the information of the units to be inherited in the first grid model; a second generation module, used to import the text file in an application that loads the second grid model, and create a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited; an inheritance module, used to add the units in the second grid model corresponding to the information in the text file to the target set, and use the units added in the target set as some units that inherit the units to be inherited.

[0009] The unit inheritance device of the grid model proposed in the embodiment of the second aspect of the present invention generates a text file according to the information of the units to be inherited in the first grid model, and creates a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited. This can realize the automatic inheritance of some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0010] To achieve the above-mentioned purpose, the fourth aspect of the present invention proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the unit inheritance method of the grid model as described above is implemented.

[0011] The electronic device proposed in the fourth aspect of the embodiment of the present invention can automatically inherit some units in the grid model by generating a text file according to the information of the units to be inherited in the first grid model, and creating a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, so as to effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0012] To achieve the above-mentioned purpose, the fifth aspect of the present invention proposes a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, it implements: the unit inheritance method of the grid model proposed in the first aspect of the present invention.

[0013] The computer-readable storage medium proposed in the fifth aspect of the embodiment of the present invention can realize automatic inheritance of some units in the grid model by generating a text file according to the information of the units to be inherited in the first grid model, and creating a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, so as to effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0014] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] The above and / or additional aspects and advantages of the present invention will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0016] Figure 1 It is a flowchart of a unit inheritance method of a grid model proposed in one embodiment of the present invention;

[0017] Figure 2 is a schematic flow chart of a unit inheritance method of a grid model proposed in another embodiment of the present invention;

[0018] Figure 3 It is a structural schematic diagram of a unit inheritance device of a grid model proposed in one embodiment of the present invention;

[0019] Figure 4 is a schematic structural diagram of a unit inheritance device of a grid model proposed in another embodiment of the present invention;

[0020] Figure 5 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0021] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements with the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and are not to be construed as limitations of the present invention. On the contrary, embodiments of the present invention include all changes, modifications and equivalents that fall within the spirit and connotation of the appended claims.

[0022] In order to solve the technical problem in the related art that the manual search for inherited grid units is cumbersome, prone to omissions or errors, and has a poor inheritance effect, a unit inheritance method for a grid model is provided in an embodiment of the present invention, by generating a text file according to the information of the units to be inherited in the first grid model, and creating a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, so that some units in the grid model can be automatically inherited, effectively reducing labor costs, improving the inheritance efficiency of grid units, and improving inheritance effects.

[0023] Figure 1 It is a flowchart of a unit inheritance method of a grid model proposed in one embodiment of the present invention.

[0024] This embodiment is explained by taking the unit inheritance method of the grid model as an example in which the unit inheritance device of the grid model is configured.

[0025] In this embodiment, the unit inheritance method of the grid model can be configured in the unit inheritance device of the grid model. The unit inheritance device of the grid model can be set in a server or in a mobile device, and the embodiment of the present invention does not limit this.

[0026] The unit inheritance device of the mesh model in this embodiment is applied to CAE analysis, and specifically, can be applied to the CAE analysis pre-processing application program HyperMesh, in which the mesh model is a CAE mesh model.

[0027] See also Figure 1 , the method comprising:

[0028] S101: Generate a text file according to information of the unit to be inherited in the first grid model.

[0029] The grid model to which the current unit to be inherited belongs may be referred to as the first grid model.

[0030] The information of the unit to be inherited may be, for example, an identifier or a number, and the information may be used to uniquely identify the corresponding grid unit.

[0031] The text file may be a readable or executable script file. After the text file is generated according to the information of the unit to be inherited in the first grid model, the text file can be read or executed to obtain the information contained therein, and there is no limitation on this.

[0032] In the specific execution process, when it is necessary to inherit a unit in the mesh model, the application HyperMesh can be started, and the CAE mesh model to which the unit to be inherited belongs can be imported. Then, corresponding prompt information is generated to prompt the user to select the unit to be inherited from the imported CAE mesh model.

[0033] Then, in response to the user's selection instruction, a text file is generated according to the information of the unit to be inherited selected by the user's selection instruction.

[0034] When generating a text file according to the information of the unit to be inherited in the first grid model, the embodiment of the present invention can call a preset application programming interface and execute a corresponding script file to automatically generate the text file.

[0035] S102: importing a text file into an application program that loads the second grid model, and creating a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited.

[0036] The grid model that currently inherits the cells in the first grid model may be referred to as the second grid model.

[0037] In the specific execution process, the file name of the text file can be extracted, and a new target set can be created according to the file name. After the new target set is created, an association relationship between the target set and the second grid model can be established.

[0038] Specifically, a new target set can be created in another application HyperMesh according to the text file. The other application HyperMesh is used to pre-import the second mesh model. The other application HyperMesh and the application HyperMesh that pre-imports the first mesh model are different application HyperMesh.

[0039] It can be seen that in the embodiment of the present invention, the second mesh model and the target set are both run in another application HyperMesh that is different from the application HyperMesh that pre-imports the first mesh model.

[0040] Optionally, the first mesh model and the second mesh model are run in different HyperMesh applications. Before generating a text file based on information of the units to be inherited in the first mesh model, the first HyperMesh application is started; the first mesh model is imported into the first HyperMesh application; before creating a new target set based on the text file, the second HyperMesh application is started; and the second mesh model is imported into the second HyperMesh application.

[0041] By configuring the first mesh model and the second mesh model to run in different HyperMesh applications, subsequent efficient and orderly inheritance can be achieved, making the unit inheritance logic between different mesh models clearer, further ensuring inheritance accuracy, and avoiding erroneous inheritance or missed inheritance.

[0042] S103: adding the units in the second grid model corresponding to the information in the text file to the target set, and using the added units in the target set as partial units that inherit the units to be inherited.

[0043] During the specific execution process, the preset application programming interface is called and the corresponding script file is executed to traverse the information of each unit in the second grid model, and the information of the traversed unit is matched with the information in the text file. If the match is successful, the unit with successfully matched information in the second grid model is added to the target set. If the match is unsuccessful, the traversal continues to the next unit.

[0044] In this embodiment, by generating a text file based on the information of the units to be inherited in the first grid model, and creating a new target set based on the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, it is possible to automatically inherit some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve inheritance effects.

[0045] Figure 2 It is a flowchart of a unit inheritance method of a grid model proposed in another embodiment of the present invention.

[0046] See also Figure 2 , the method comprising:

[0047] S201: Add the unit to be inherited to an initial set, where the initial set corresponds to the first grid model.

[0048] In the specific execution process, the first HyperMesh application may be started first, the first mesh model may be imported into the first HyperMesh application, and then the unit to be inherited may be added to the initial set. The set corresponding to the first mesh model may be called the initial set.

[0049] Optionally, the unit to be inherited is added to at least one initial set, and the number of the initial set is counted to obtain a count value, which can be used to monitor the execution status of subsequent inheritance.

[0050] In an embodiment of the present invention, if some of the units to be inherited and other units to be inherited belong to different model parts in the CAE mesh model, some of the units to be inherited and other units to be inherited can be added to different initial sets to achieve subsequent targeted inheritance, thereby ensuring the accuracy of inheritance from another perspective.

[0051] S202: Generate a text file according to the information of each unit to be inherited in the initial set.

[0052] Optionally, when the count value is not zero, corresponding text files are generated according to the information of the units to be inherited in each initial set. The number of text files is the same as the number of initial sets. Each initial set has a corresponding text file to achieve targeted inheritance and ensure the accuracy of inheritance from another perspective.

[0053] When generating a text file based on the information of each unit to be inherited in the initial set, the information of each unit to be inherited may be arranged in sequence, with different information separated by spaces to form a character string to form a text file, and there is no limitation to this.

[0054] S203: importing a text file into the application program that loads the second grid model, and creating a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited.

[0055] Optionally, when the number of text files is not zero, a corresponding target set is newly created according to each text file, and the target set includes a plurality of target sets, and each text file has a corresponding target set.

[0056] In this embodiment, when the number of text files is not zero, a corresponding target set is created according to each text file, thereby determining the timing for triggering inheritance. If the number of text files is zero, it indicates that inheritance has been completed and the inheritance process can be stopped. This enables monitoring of the inheritance timing, ensures a high degree of automation in starting and stopping inheritance, and improves the automation effect of unit inheritance.

[0057] S204: adding the cells in the second grid model corresponding to the information in the text file to the target set, and using the added cells in the target set as partial cells that inherit the cells to be inherited.

[0058] During the specific execution process, the preset application programming interface is called and the corresponding script file is executed to traverse the information of each unit in the second grid model, and the information of the traversed unit is matched with the information in the text file. If the match is successful, the unit with successfully matched information in the second grid model is added to the target set. If the match is unsuccessful, the traversal continues to the next unit.

[0059] The following example illustrates the unit inheritance method in the present invention:

[0060] 1. Model two CAE mesh models;

[0061] 2. Start the first HyperMesh application, import a CAE mesh model, and add the unit to be inherited to the initial set Set. The number of initial sets can be one or more. The number of initial sets is multiple for example. When the number of initial sets is multiple, a corresponding identification ID can be assigned to each initial set.

[0062] 3. Set the variable ID_list and configure its initial value to be empty, then write the identification IDs of all initial sets Set into the variable ID_list;

[0063] 4. When writing the identification IDs of all the initial sets Set into the variable ID_list, you can select the ID of the above Set, configure multiple IDs to form a string in the form of sequential arrangement and separation of different IDs with spaces, and assign it to the above variable ID_list;

[0064] 5. Measure the length of the variable ID_list, that is, how many units to be inherited exist in the Set, and assign it to the variable L1;

[0065] 6. When the loop variable i=1, extract the first ID in the variable ID_list, and extract the unit numbers of all the units to be inherited in the Set, create a new text file with the same name as the ID, and output the unit numbers of all the units to be inherited in the Set to the text file;

[0066] 7. When the loop variable i=2, extract the second ID in the variable ID_list, and extract the unit numbers of all the units to be inherited in the Set, create a new text file with the same name as the ID, and output the unit numbers of all the units to be inherited in the Set to the text file;

[0067] 8. Similarly, when the loop variable i=L1, extract the last ID in the variable ID_list, and extract the unit numbers of all the units to be inherited in the Set, create a new text file with the same name as the ID, and output the unit numbers of all the units to be inherited in the Set to the text file;

[0068] 9. Then, the user is prompted that the Set unit output is successful;

[0069] 10. Close the first HyperMesh application;

[0070] 11. Start a second HyperMesh application and load another CAE mesh model.

[0071] 12. Mark the multiple text files generated above, calculate their number, and assign it to L2;

[0072] 13. When the loop variable j=1, mark the first text file mentioned above, extract its file name, create a target set Set with the same name as the file name in the second HyperMesh application, read the unit numbers of all the units to be inherited in the text file, and add all the units corresponding to the unit numbers to the target set Set one by one;

[0073] 14. When the loop variable j=2, mark the second text file, extract its file name, create a target set Set with the same name as the file name in the second HyperMesh application, read all the unit numbers in the text file, and add all the units corresponding to the unit numbers to the target set Set one by one;

[0074] 15. When the loop variable j=L2, mark the last text file mentioned above, extract its file name, create a target set Set with the same name as the file name in the second HyperMesh application, read all the unit numbers in the text file, and add all the units corresponding to the unit numbers to the target set Set one by one;

[0075] 16. Prompt the user that the unit inheritance is completed.

[0076] In the specific execution process, Tcl / Tk language can be used to generate a corresponding script file according to the steps in the embodiment of the present invention, and the batch and automatic inheritance of units in the CAE mesh model can be realized by calling and executing the script file.

[0077] In this embodiment, the unit to be inherited is added to at least one initial set, and the number of initial sets is counted to obtain a count value, which can be used to monitor the execution of subsequent inheritance. When the count value is not zero, corresponding text files are generated according to the information of the units to be inherited in each initial set. The number of text files is the same as the number of initial sets. Each initial set has a corresponding text file, which realizes targeted inheritance and ensures the accuracy of inheritance from another perspective. When the number of text files is not zero, a corresponding target set is created according to each text file, and the timing of triggering inheritance is determined. If the number of text files is zero, it means that the inheritance has been completed and the inheritance process can be stopped. This enables monitoring of the inheritance timing, ensures a high degree of automation in starting and stopping inheritance, and improves the automation effect of unit inheritance. By generating a text file according to the information of the units to be inherited in the first grid model, and creating a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and adding the units in the second grid model corresponding to the information in the text file to the target set, and using the added units in the target set as some units that inherit the units to be inherited, it is possible to automatically inherit some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0078] Figure 3 It is a structural schematic diagram of a unit inheritance device of a grid model proposed in one embodiment of the present invention.

[0079] The mesh model is a CAE mesh model.

[0080] See also Figure 3 , the device 300 comprises:

[0081] A first generating module 301 is used to generate a text file according to the information of the unit to be inherited in the first grid model;

[0082] The second generation module 302 is used to import the text file into the application program that loads the second grid model, and create a new target set according to the text file, the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited;

[0083] The inheritance module 303 is used to add the cells in the second grid model corresponding to the information in the text file to the target set, and use the added cells in the target set as partial cells that inherit the cells to be inherited.

[0084] Optionally, in some embodiments, see Figure 4 , the first generation module 301 includes:

[0085] An adding submodule 3011 is used to add the unit to be inherited to the initial set, and the initial set corresponds to the first grid model;

[0086] The generating submodule 3012 is used to generate a text file according to the information of each unit to be inherited in the initial set.

[0087] Optionally, in some embodiments, a submodule 3011 is added, specifically used for:

[0088] Add the unit to be inherited to at least one initial set, and count the number of the initial sets to obtain a count value;

[0089] Generate submodule 3012, specifically for:

[0090] When the count value is not zero, corresponding text files are generated according to the information of the units to be inherited in each initial set. The number of text files is the same as the number of initial sets, and each initial set has a corresponding text file.

[0091] Optionally, in some embodiments, the second generating module 302 is specifically configured to:

[0092] When the number of text files is not zero, a corresponding target set is newly created according to each text file, and the target set includes a plurality of target sets, and each text file has a corresponding target set.

[0093] It should be noted that the explanation of the unit inheritance method embodiment of the grid model in the aforementioned embodiment is also applicable to the unit inheritance device 300 of the grid model of this embodiment, and the implementation principle is similar, which will not be repeated here.

[0094] In this embodiment, by generating a text file based on the information of the units to be inherited in the first grid model, and creating a new target set based on the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, it is possible to automatically inherit some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve inheritance effects.

[0095] Figure 5 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention.

[0096] The electronic device 50 includes: a memory 501, a processor 502, and a computer program stored in the memory 501 and executable on the processor 502. When the processor 502 executes the program, the unit inheritance method of the grid model in the above embodiment is implemented.

[0097] In a possible implementation, the electronic device further includes a communication interface 503 for communication between the memory 501 and the processor 502 .

[0098] In this embodiment, by generating a text file based on the information of the units to be inherited in the first grid model, and creating a new target set based on the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, it is possible to automatically inherit some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve inheritance effects.

[0099] In order to implement the above embodiments, the present invention also proposes a computer-readable storage medium. When the instructions in the storage medium are executed by the processor of the encoding device, the encoding device can execute the unit inheritance method of the grid model in the above embodiments.

[0100] The computer-readable storage medium in this embodiment generates a text file according to the information of the units to be inherited in the first grid model, and creates a new target set according to the text file, the target set corresponds to the second grid model, some units in the second grid model inherit the units to be inherited, and the units in the second grid model corresponding to the information in the text file are added to the target set, and the units added in the target set are used as some units that inherit the units to be inherited, so as to realize automatic inheritance of some units in the grid model, effectively reduce labor costs, improve the inheritance efficiency of grid units, and improve the inheritance effect.

[0101] It should be noted that, in the description of the present invention, the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of the present invention, unless otherwise specified, the meaning of "plurality" is two or more.

[0102] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.

[0103] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0104] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.

[0105] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0106] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.

[0107] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" 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 may be combined in any one or more embodiments or examples in a suitable manner.

[0108] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A unit inheritance method for a grid model, characterized in that: The grid model is a CAE grid model, and the method comprises: Generate a text file according to the information of the unit to be inherited in the first grid model; Importing the text file in an application program that loads the second grid model, and creating a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited; Adding the unit in the second grid model corresponding to the information in the text file to the target set, and using the added unit in the target set as a partial unit that inherits the unit to be inherited; generating a text file according to the information of the unit to be inherited in the first grid model, comprises: Adding the to-be-inherited unit to an initial set, where the initial set corresponds to the first grid model; Generating the text file according to the information of each unit to be inherited in the initial set; adding the unit to be inherited to the initial set, wherein the initial set corresponds to the first grid model, includes: Adding the to-be-inherited unit to at least one initial set, and counting the number of the initial set to obtain a count value; The step of generating the text file according to the information of each unit to be inherited in the initial set includes: When the count value is not zero, the corresponding text files are generated according to the information of the units to be inherited in each of the initial sets. The number of the text files is the same as the number of the initial sets, and each of the initial sets has a corresponding text file.

2. The unit inheritance method of the grid model according to claim 1, characterized in that: The creating a new target set according to the text file includes: When the number of the text files is not zero, a corresponding target set is newly created according to each of the text files, and the target set includes a plurality of target sets, and each of the text files has a corresponding target set.

3. A unit inheritance device for a grid model, used to execute the unit inheritance method for a grid model as claimed in claim 1, characterized in that: The grid model is a CAE grid model, and the device comprises: A first generating module, used for generating a text file according to the information of the unit to be inherited in the first grid model; A second generating module is used to import the text file in an application program that loads the second grid model, and to create a new target set according to the text file, wherein the target set corresponds to the second grid model, and some units in the second grid model inherit the units to be inherited; An inheritance module is used to add the units in the second grid model corresponding to the information in the text file to the target set, and use the added units in the target set as partial units that inherit the units to be inherited.

4. The unit inheritance device of the grid model according to claim 3, characterized in that: The first generating module comprises: An adding submodule, used for adding the to-be-inherited unit to an initial set, wherein the initial set corresponds to the first grid model; The generating submodule is used to generate the text file according to the information of each unit to be inherited in the initial set.

5. The unit inheritance device of the grid model as claimed in claim 4, characterized in that: The adding submodule is specifically used for: Adding the to-be-inherited unit to at least one initial set, and counting the number of the initial set to obtain a count value; The generating submodule is specifically used for: When the count value is not zero, the corresponding text files are generated according to the information of the units to be inherited in each of the initial sets. The number of the text files is the same as the number of the initial sets, and each of the initial sets has a corresponding text file.

6. The unit inheritance device of the grid model according to claim 5, characterized in that: The second generating module is specifically used for: When the number of the text files is not zero, a corresponding target set is newly created according to each of the text files, and the target set includes a plurality of target sets, and each of the text files has a corresponding target set.

7. An electronic device, characterized in that: include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the unit inheritance method of the grid model as described in any one of claims 1-2 is implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the unit inheritance method of the grid model as described in any one of claims 1-2 is implemented.