A CAD model simulation method based on extended voxels to maintain design features
By combining features with mesh in the CAD model, using extended voxel recording and querying model features, the problem of low simulation speed in the fixed mesh method is solved, efficient simulation and optimization are achieved, and calculation speed and accuracy are significantly improved. .
Patent Information
- Application Number
- CN202310209453.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-07
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2043-03-07
AI Technical Summary
In the CAD-CAE integration, although the fixed grid method avoids grid update and distortion problems, it leads to a reduction in simulation speed, especially in the low calculation efficiency during multiple simulations and optimizations.
Using a method based on expansion voxels, combining features with mesh, recording model features and simulation data through voxels as basic units, constructing feature history trees to query activated and inactivated voxels, and only voxels that need to be recalculated are calculated. Data, calculation results before multiplexing.
It significantly improves the speed of simulation and optimization, reduces calculation time, and does not affect calculation accuracy. It is adapted to any fixed grid method and adaptively sets grid density and accuracy.
Smart Images

Figure CN116090313B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of CAD, finite element simulation and CAD-CAE integration, and in particular to a CAD model simulation method based on extended voxels and maintaining design features. Background Art
[0002] The finite element method (FEM) has undergone decades of development and improvement, and has now become a mainstream numerical simulation and analysis calculation tool that can handle complex engineering practical problems in multiple disciplines, fields, and working conditions, such as statics, dynamics, thermodynamics, and fluid mechanics. At present, most CAD (computer-aided design) and CAE (computer-aided engineering) use FEM to simulate and optimize models. FEM regards an object as a whole composed of a finite number of small units, so before analysis, the entire model needs to be meshed to establish a finite element analysis model. However, it mainly faces two challenges: the first is that the mesh is different from the actual model, and cumbersome model conversion is required, which will cause different degrees of geometric accuracy loss. The second is that in the process of model optimization, each step needs to be re-meshed. In some bad cases, mesh distortion and distortion will produce an ill-conditioned stiffness matrix, causing the optimization process to be forced to interrupt, forming an important problem and key challenge for CAD-CAE integration.
[0003] Therefore, researchers have proposed fixed-grid analysis methods, such as the finite cell method (FCM). FCM uses high-order shape functions to interpolate the physical field to be solved, and combines the virtual region method (FDM), adaptive integration mechanism and fixed grid to accurately solve the mechanical response of the structure, improve the analysis accuracy of the structure, and avoid the grid update process. Since FCM's precise analysis process of complex structures is performed on a fixed grid, it can avoid grid update operations and grid distortion problems during the optimization process, so it is very beneficial for structural shape / topology optimization. However, although this method avoids model-related meshing, it will inevitably introduce units that intersect with the model boundary, and the calculations on these units greatly reduce the simulation speed, especially when multiple simulations and optimizations are required. Summary of the invention
[0004] In view of the problems existing in the above-mentioned fixed grid method, the present invention provides a CAD model method for maintaining design features based on extended voxels, which can significantly improve the simulation and optimization speed. Traditional CAD / CAE methods always use model features as information containers to store design intent (such as shape parameterization) and simulation intent (such as grid programs and boundary conditions). In particular, the present invention uses voxels as information containers for design intent and simulation intent. On the basis of the fixed grid method, the features are combined with the grid to form extended voxels, and the editing operations of the model features are recorded with voxels as the basic unit, that is, the features are embedded in the voxels. Furthermore, various types of data related to the units in the simulation (such as volume and stiffness matrix) are also stored via voxels. By querying the recorded feature attributes, it is possible to determine the voxels that need to retain data and the voxels that need to be recalculated before and after the model is edited. The main advantage of this is that the calculation time is significantly reduced by reusing the calculation results of the previous step without affecting the calculation accuracy at all.
[0005] The technical solution adopted by the present invention is as follows:
[0006] A CAD model method for maintaining design features based on extended voxels, the method combines features with grids to form voxels on the basis of a fixed grid method, specifically comprising: embedding a model to be simulated into a voxel grid, taking voxels as basic units, recording the editing operations of model features, and storing data obtained by simulation calculations, by querying the recorded feature attributes and judging the voxels that need to retain data and the voxels that need to be recalculated before and after the model is edited, and only calculating the voxels that need to be recalculated; specifically comprising the following steps:
[0007] 1) Construct a feature history tree based on model features, establish a mapping relationship between each node and voxel, and divide the voxels into two states: activated or not according to the voxel attribute table;
[0008] 2) Simulate and optimize based on voxel status, only calculate the simulation data of activated voxels and reuse the simulation data of inactivated voxels, and record the simulation calculation results through the corresponding voxels to reduce the calculation time through local calculation;
[0009] 3) Modify the model feature list, update the voxel attribute table, and update the voxel status based on user needs or the optimization results of the previous step;
[0010] 4) Repeat steps 2)-3) until the simulation or optimization is completed.
[0011] In the above technical solution, further, in the step 1), a feature history tree is constructed to establish a mapping between nodes and voxels, as follows:
[0012] The data structure of the feature history tree is a binary tree, whose non-empty nodes store voxel attribute tables, including three data: feature operators, update labels f, and voxel state tables; among them, the feature operator is used to determine whether the node is a basic feature node or to identify the operation that the node should perform, the update label f is used to determine whether the node needs to be updated, and the voxel state table is used to store the voxel state of each grid in the entire fixed grid; in the binary tree, the voxel state table of the parent node is obtained by operating the voxel state tables of its left and right subtrees through the feature operator corresponding to the parent node.
[0013] Furthermore, the feature operator is +, -, * or the basic feature F i , where the + operator represents taking the union of the operation units, the * operator represents taking the intersection, and the - operator represents taking the complement of the subtracted operation unit and then taking the union with the subtracted operation unit;
[0014] The update label f is 0 or 1, where 0 indicates that the node voxel status table has been updated, and 1 indicates that the node is newly added or needs to be updated;
[0015] The voxel state table is maintained independently by each node, corresponding to a fixed grid, and the state of the voxel is determined by the value stored in it; in particular, each value in the voxel state table can only represent one of the following three states: solid voxel, boundary voxel and empty voxel, denoted as S, B and E respectively, which is determined by the specific model characteristics.
[0016] Furthermore, when constructing the feature history tree, the update labels f of all nodes are first set to 1, and each node is updated from bottom to top according to the feature tree structure. Except for the feature nodes, the voxel state of the grid in the voxel state table of each node is calculated by the voxel state of the left and right child nodes at the same grid position according to the feature operator of the node in question; if the voxel state table of a node is empty, it means that it needs to be initialized. Then, no matter what the values of the update labels f of the left and right subtrees are, the update range of its voxel state table is the union of the update ranges of the left and right subtrees; if the voxel state table of a node is not empty, it means that it only needs a partial update. Then the update range of its voxel state table is taken from the union of the update ranges of the subtrees whose f value is 1; finally, the update label f of each node is set to 0, indicating that the voxel state table has been updated.
[0017] Furthermore, in the step 1), the voxels are divided into two states: activated or not activated according to the voxel attribute table, specifically:
[0018] The voxel state table of the top node is a summary of the voxel state tables of all descendant nodes. The voxel state table of the model based on the top node is compared with the voxel state table obtained in the previous cycle to determine the activated voxels: all units with voxel state values of S and E in the voxel state table of this cycle do not need to be activated, and for units with voxel state value B, if the value of the corresponding voxel state table in the previous round is S or E, it is activated. If the value of the corresponding voxel state table in the previous round is B, it means that the voxel is a boundary voxel (i.e., partly empty and partly solid) in both the previous and current rounds. Whether it can be reused (not activated) depends on whether the shape of the model cut by the voxel has changed. At this time, it is necessary to further compare whether the voxel shape is consistent with the previous round. If it is consistent, it means that the model in the voxel has not changed, and it does not need to be activated. Otherwise, it is activated. In order to compare the voxel shape, the method that can be used is to perform multiple sampling in the unit with the voxel state value of B, and the sampling results correspond to the voxel shape one by one, and the sampling results are saved for the next round of comparison. If this is the first cycle, all cells with voxel state value B will be activated.
[0019] Furthermore, in step 3), modifying the model feature list and updating the voxel attribute table include three types of operations: insertion, deletion and modification, specifically:
[0020] 1) Insert
[0021] Insert the F2 feature node at the F1 feature node by any operation to generate an F2 node and a parent node with an empty voxel state table; set the update label f of F2 and its ancestor nodes to 1, and then search for the node grid with the update label f of 1 according to the feature history tree for recursive update;
[0022] Since the voxel state table of the parent node is empty, the voxel state table is updated at the union of the feature ranges of the left and right subtrees, and its own feature range is obtained until no other nodes need to be updated, and the update labels f of all nodes are set to 0;
[0023] 2) Delete
[0024] Set the update labels f of the ancestor nodes of the F1 feature node to 1. After that, delete the F1 feature node, and its parent node will also be deleted. Since the feature range information of the deleted node is lost, the voxel state tables of all its ancestor nodes will be deleted. Then update the node grid until there are no other nodes to be updated, and set the update labels f of all nodes to 0.
[0025] 3) Modification
[0026] Modify the attributes of a feature node model, set the update labels f of the node and its ancestor nodes to 1, and then recursively update the grid nodes; until there are no other nodes that need to be updated, set the update labels f of all nodes to 0.
[0027] The beneficial effects of the present invention are:
[0028] 1) Based on maintaining the design history tree, a cache mechanism such as the voxel state table is constructed. The query time complexity of the activated unit is O(log(n)), which can be used to quickly locate the activated units in a fixed grid.
[0029] 2) The data from the previous iteration can be reused to directly reduce the amount of simulation calculations according to whether the unit is activated or not, without affecting the simulation accuracy, which significantly improves the simulation speed in continuous simulation and optimization.
[0030] 3) The proposed method is decoupled from the specific simulation method, can be adapted to any fixed grid method, and can adaptively set the grid density and grid accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 It is a schematic diagram of the feature history tree node, indicating its data structure.
[0032] Figure 2 This is a schematic diagram of the initialization operation of the model feature history tree;
[0033] Figure 3 This is a schematic diagram of the insertion operation of the model feature history tree;
[0034] Figure 4 This is a schematic diagram of the deletion operation of the model feature history tree;
[0035] Figure 5 This is a schematic diagram of the modification operation of the model feature history tree;
[0036] Figure 6 Figure 1 shows an example of the initialization operation of the model feature history tree (a) before updating; (b) after updating;
[0037] Figure 7 Figure 1 shows an example of inserting a model feature history tree: (a) before updating; (b) after updating;
[0038] Figure 8 Figure 1 shows an example of a deletion operation on a model feature history tree: (a) before updating; (b) after updating;
[0039] Fig. 9 Figure 1 shows an example of the modification operation of the model feature history tree (a) before updating; (b) after updating;
[0040] Fig.10 Schematic diagram of the cantilever beam model (with boundary conditions) and voxel grid.
[0041] Fig.11 The figure is a comparison diagram of the cantilever beam model modification and the present invention and the traditional method. DETAILED DESCRIPTION
[0042] The present invention provides a CAD model method for maintaining design features based on extended voxels, which is used to significantly improve the simulation and optimization speed. In particular, the present invention combines features with grids and uses voxels as the basic unit to record the editing operations of model features / primitives, that is, embed features into voxels. Various types of data related to the units in the simulation (such as volume and stiffness matrix) are also stored via voxels. By querying the recorded feature attributes, it is possible to determine the voxels that need to retain data and the voxels that need to be recalculated before and after the model is edited. The main advantage of this is that the calculation time is significantly reduced by reusing the calculation results of the previous step without affecting the calculation accuracy at all.
[0043] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments.
[0044] First, the general process based on FCM simulation is:
[0045] 1. Initialization: Establish constructive solid geometry model (CSG) and voxel grid.
[0046] 2. Construct simulation linear equations:
[0047] KU=F
[0048] Among them, K is the overall stiffness matrix, U is the required node displacement vector, and F is the node load vector.
[0049] In the above equation, F is generally defined by the user and is a known quantity. The global stiffness matrix K is assembled from the element stiffness matrix KE and requires program calculation, which is the most time-consuming part of the FCM simulation program.
[0050] 3. Solve the linear equations: Solve the linear equations in step 2 to obtain the node displacement vector U.
[0051] 4. Post-processing: Calculate the displacement and stress of each point of the model according to U, and the simulation ends.
[0052] The above is a simulation process, but when a model needs to be modified and simulated multiple times, the above process needs to be performed multiple times. Note that during multiple simulations, the model is mostly only partially modified, that is, most areas of the model remain unchanged, and the unit stiffness matrix KE in step 2 is related to the model, that is, it is not necessary to recalculate the KE of all voxels. In view of this situation, the present invention locates the units that need to be recalculated, reuses the calculation results in the previous simulation process, and only calculates the necessary unit stiffness matrix, which significantly reduces the calculation time without affecting the calculation accuracy.
[0053] As described above, the CAD model method for maintaining design features based on extended voxels proposed by the present invention comprises the following steps:
[0054] 1) Construct a feature history tree based on model features, establish a mapping relationship between each node and voxel, and divide the voxels into two states: activated or not according to the voxel attribute table.
[0055] 2) Perform simulation and optimization based on voxel status (calculate only activated voxel data and reuse inactive voxel data), and record simulation results by voxel to reduce computation time through local calculation.
[0056] 3) Based on user needs or the optimization results of the previous step, modify the model feature list, update the voxel attribute table, and update the voxel status.
[0057] 4) Repeat steps 2)-3) until the simulation or optimization is completed.
[0058] In the above technical solution, the step 1) constructs a feature history tree, which is specifically as follows:
[0059] The data structure of the feature history tree is a binary tree. Its non-empty nodes store three data, feature operators (+, -, * or F), update labels f (0 or 1) and voxel status tables, such as Figure 1 shown.
[0060] The characteristic operator is used to identify the corresponding operation of the node and determine whether it is a characteristic node. Among them, the + operator means taking the union of the operation units, the * operator means taking the intersection, and the - operator means taking the complement of the subtraction operation unit and then taking the union with the subtracted operation unit; F means that the node is a characteristic node and does not depend on other nodes.
[0061] The update label f is used to determine whether the node has changed to reduce calculation, which will be introduced below.
[0062] The voxel state table is maintained independently by each node, corresponding to a fixed grid, and the state of the voxel is determined by the value stored in it. In particular, each value in the voxel state table can only represent one of the following three states: solid voxel, boundary voxel and empty voxel (respectively denoted as S, B and E), determined by specific features. By storing S and B (E does not need to be stored) in a hash table, both storage capacity and access speed can be taken into account.
[0063] By defining the operator, an operation table is given (the first column represents the left operation unit, the first row represents the right operation unit, and the remaining items represent the operation results):
[0064]
[0065]
[0066] When constructing the feature history tree, the f of all nodes is 1, indicating that they are newly added or updated nodes. Each node is updated from bottom to top according to the feature tree structure. The voxel state table of each node is calculated by the voxel state (S, B or E) of the same position of the left and right units according to the above calculation table.
[0067] The calculation rule is: if the voxel state table of a node is empty, then no matter what the f value of the left and right subtrees is, the update range of its voxel state table is the union of the update ranges of the left and right subtrees. If the voxel state table of a node is not empty, then the update range of its voxel state table is the union of the update ranges of the subtrees whose f value is 1.
[0068] The position range of the voxel table that needs to be calculated can be determined by the graphic range of the feature node, which can further reduce the amount of calculation. Finally, each node f is set to 0, indicating that the voxel state table has been updated. Figure 2 shown.
[0069] In the above technical solution, the simulation and optimization are performed based on the voxel state in step 2), as follows:
[0070] The voxel state table of the model based on the top node is compared with the voxel state table in the previous cycle to determine the activated voxels (if it is the first cycle, all cells with value B are activated):
[0071] Specifically, the following rules are given (where the first column represents the voxel state table unit of the previous round, and the first row represents the voxel state table unit of this round):
[0072]
[0073]
[0074] Among them, the units with values of S or E in the voxel state table have uniform simulation data due to their regularity and do not need to be activated. Only the simulation data (such as volume, stiffness matrix, etc.) of the activated voxels are calculated and recalculated and recorded by voxel, while the recorded simulation data of the inactivated voxels are reused.
[0075] In the above technical solution, the voxel attribute table is updated in step 3), specifically as follows:
[0076] The update of the model feature history tree can be briefly divided into the following three categories: insertion, deletion and modification. The following will be introduced in turn:
[0077] 1) Insert
[0078] like Figure 3As shown in the figure, insert the F2 feature node at the F1 feature node by any operation to generate an F2 node and a parent node with an empty voxel state table. Set the f of F2 and its ancestor nodes to 1. Then, according to the feature history tree, search for the node grid with f being 1 for recursive update.
[0079] Since the voxel state table of the parent node is empty, the voxel feature table is updated at the union of the feature ranges of the left and right subtrees, and its own feature range is obtained. Until there are no other nodes to be updated, all f are set to 0.
[0080] 2) Delete
[0081] like Figure 4 As shown in the figure, the ancestor nodes f of the F1 feature node are all set to 1. After that, if the F1 feature node is deleted, its parent node is also deleted. Since the feature range information of the deleted node is lost, the voxel state tables of all its ancestor nodes are deleted. Then the node grid is updated. When there are no other nodes to be updated, all f are set to 0.
[0082] 3) Modification
[0083] like Figure 5 As shown, modify the properties of the F2 feature node model. Set F2 and its ancestor node f to 1. Then recursively update the grid nodes. When there are no other nodes to be updated, set all f to 0.
[0084] More specifically, consider Figure 6-9 The continuous editing operation shown may specifically include the following steps:
[0085] 1) Construct a voxel attribute table based on the model feature list, establish a mapping relationship between model features and voxels, and divide voxels into two states: activated or not according to the voxel attribute table.
[0086] like Figure 6 As shown in (a), the f of all nodes is 1, indicating that it is a newly added or updated node. The voxel state tables of the top two nodes are empty. Since the hash table is used for storage, the table is empty here. Each node is updated from bottom to top according to the feature tree structure. The voxel state table of each node is calculated by the voxel state (S, B or E) of the same position of the left and right units according to the above calculation table. Figure 6 (b) The dotted box indicates the position range of the voxel table that needs to be calculated, which can be determined by the graphic range of the feature node, which can further reduce the amount of calculation. Finally, each node f is set to 0, indicating that the voxel state table has been updated. The voxel state table of the top node represents the voxel state of the model composed of the feature tree.
[0087] Because it is the first cycle, all cells with value B in the voxel state table of the top node are activated.
[0088] 2) Perform simulation and optimization based on voxel status (calculate only activated voxel data and reuse inactive voxel data), and calculate simulation results through voxel records to reduce computation time through local calculation.
[0089] 3) Based on user needs or the optimization results of the previous step, modify the model feature list, update the voxel attribute table, and update the voxel status.
[0090] like Figure 6-8 As shown, the following operations are performed on the model feature history tree in three iterations: insertion, deletion and modification.
[0091] Insert: As Figure 7 As shown in (a), the F4 feature node is inserted into the F3 feature node using the + operation to generate an F4 node and an empty + node. F4 and its ancestor node f are both set to 1. Afterwards, according to the feature history tree, the node grid with f=1 is searched for recursive update. Since the + node voxel state table is empty, the update range of its voxel state table is the union of the left and right subtree update ranges. Since the left subtree (* node) f of the - node is 0 and the right subtree (+ node) f is 1, the voxel feature table is only updated at the feature range of the right subtree, as shown in Figure 7 (b) As shown in Figure 2, there are no other nodes that need to be updated, so all f are set to 0.
[0092] Delete: If Figure 8 As shown in (a), the F3 feature node and its ancestor node f are both set to 1. After that, the F3 feature node is deleted, and the + node is also deleted. Since the feature range information of the deleted node is lost, the voxel state table of its ancestor node is deleted. Then the node grid is updated. Since the voxel state table of the - node is empty, no matter what the left and right subtree values are, they are updated through the union of the feature ranges of the left and right subtrees, as shown in Figure 8 (b) As shown in Figure 2, there are no other nodes that need to be updated, so all f are set to 0.
[0093] Revise:
[0094] like Fig. 9 As shown in (a), modify the attributes of the F4 feature node model, that is, increase the width of the rectangle. Set F4 and its ancestor node f to 1. Then recursively update the grid nodes. First, update the voxel attribute table of the F4 node, which can be obtained from the updated model shape. Then update the - node. Since its left subtree (* node) f is 0 and the right subtree (+ node) f is 1, the voxel feature table is only updated in the feature range of the right subtree, such as Fig. 9 (b) As shown in Figure 2, there are no other nodes that need to be updated, so all f are set to 0.
[0095] After the editing operation is completed, the voxel state table of the model based on the top node is compared with the voxel state table in the previous cycle to determine the activated voxel.
[0096] 4) Repeat steps 2)-3) until the simulation or optimization is completed.
[0097] The following is further explained with examples.
[0098] Consider a cantilever beam model with a hole, embedded in a 6×3 voxel grid, such as Fig.10 shown.
[0099] This example contains 4 simulations, each of which is performed after modifying the model (CSG).
[0100] Specifically:
[0101] 1. Initialize the cantilever beam model with a hole and perform simulation.
[0102] 2. Insert a fillet feature, which consists of a cube and a circle, for simulation.
[0103] 3. Modify the features, reduce the fillet and its corresponding features, and perform simulation.
[0104] 4. Delete the circular hole feature and perform simulation.
[0105] Fig.11 The CSG diagram of each simulation model, the voxels that need to be recalculated (activated) by the traditional FCM method and the method of the present invention (i.e., the corresponding gray units in the figure) are listed. It can be seen that the present invention only needs to calculate the unit stiffness matrix of a smaller number of voxels compared to the traditional FCM method. The method described in the technical solution is used to judge the state of the voxels, among which only the B-type voxels that change due to model changes before and after simulation need to recalculate (activate) their KE (S and E-type voxels can pre-calculate KE, which does not take up simulation time and is not included in statistics).
[0106] In the four simulations, the number of element stiffness matrices KE that need to be calculated by the present invention and the traditional method are 26 and 62 respectively, and the speed is increased by about 2.4 times, which shows the high efficiency of the present invention in the field of continuous simulation.
Claims
1. A CAD model simulation method based on extended voxels and maintaining design features, characterized in that: The method combines features with grids to form voxels based on a fixed grid method, specifically including: embedding the model to be simulated into a voxel grid, taking voxels as basic units, recording the editing operation of the model features, and storing the data obtained by simulation calculation, by querying the recorded feature attributes and judging the voxels that need to retain data and the voxels that need to be recalculated before and after the model is edited, and only calculating the voxels that need to be recalculated; specifically including the following steps: 1) Construct a feature history tree based on model features, establish a mapping relationship between each node and voxel, and divide the voxels into two states: activated or not according to the voxel attribute table; 2) Simulate and optimize based on voxel status, only calculate the simulation data of activated voxels and reuse the simulation data of inactivated voxels, and record the simulation calculation results through the corresponding voxels to reduce the calculation time through local calculation; 3) Modify the model feature list, update the voxel attribute table, and update the voxel status based on user needs or the optimization results of the previous step; 4) Repeat steps 2)-3) until the simulation or optimization is completed; In the step 1), a feature history tree is constructed to establish a mapping between nodes and voxels, as follows: The data structure of the feature history tree is a binary tree, whose non-empty nodes store voxel attribute tables, including three data: feature operators, update labels f, and voxel state tables; among them, the feature operator is used to determine whether the node is a basic feature node or to identify the operation that the node should perform, the update label f is used to determine whether the node needs to be updated, and the voxel state table is used to store the voxel state of each grid in the entire fixed grid; in the binary tree, the voxel state table of the parent node is obtained by operating the voxel state tables of its left and right subtrees through the feature operator corresponding to the parent node.
2. The CAD model simulation method based on extended voxels and maintaining design features according to claim 1, characterized in that: The feature operator is +, -, * or the basic feature F i , where the + operator represents taking the union of the operation units, the * operator represents taking the intersection, and the - operator represents taking the complement of the subtracted operation unit and then taking the union with the subtracted operation unit; The update label f is 0 or 1, where 0 indicates that the node voxel status table has been updated, and 1 indicates that the node is newly added or needs to be updated; The voxel state table is maintained independently by each node, corresponding to a fixed grid, and the state of the voxel is determined by the value stored in it; in particular, each value in the voxel state table can only represent one of the following three states: solid voxel, boundary voxel and empty voxel, denoted as S, B and E respectively, which is determined by the specific model characteristics.
3. The CAD model simulation method based on extended voxels and maintaining design features according to claim 2, characterized in that: When constructing the feature history tree, the update labels f of all nodes are first set to 1, and each node is updated from bottom to top according to the feature tree structure. Except for the feature nodes, the voxel state of the grid in the voxel state table of each node is calculated by the voxel state of the left and right child nodes at the same grid position according to the feature operator of the node in question; if the voxel state table of a node is empty, it means that it needs to be initialized. Then, regardless of the values of the update labels f of the left and right subtrees, the update range of its voxel state table is the union of the update ranges of the left and right subtrees; if the voxel state table of a node is not empty, it means that it only needs a partial update. Then, the update range of its voxel state table is taken from the union of the update ranges of the subtrees whose f value is 1; finally, the update label f of each node is set to 0, indicating that the voxel state table has been updated.
4. The CAD model simulation method based on extended voxels and maintaining design features according to claim 2, characterized in that: In the step 1), the voxels are divided into two states: activated or not activated according to the voxel attribute table, specifically: The voxel state table of the model based on the top node is compared with the voxel state table obtained in the previous cycle to determine the activated voxels: all units with voxel state values of S and E in the voxel state table of this cycle do not need to be activated, and for units with voxel state value of B, if the value in the corresponding voxel state table in the previous cycle is S or E, they are activated; if the value in the corresponding voxel state table in the previous round is B, whether to activate it is determined based on the model data recorded in the unit; if the current is the first cycle, all units with voxel state value B are activated.
5. The CAD model simulation method based on extended voxels and maintaining design features according to claim 4, characterized in that: The determination of activation based on the model data recorded by the unit is as follows: for a unit whose voxel state value is B, if the value in the corresponding voxel state table in the previous round is B, it is necessary to further compare whether the voxel shape is consistent with the previous round. If they are consistent, it means that the model in the voxel has not changed, and there is no need to activate it. Otherwise, it is activated.
6. The CAD model simulation method based on extended voxels and retaining design features according to claim 2, characterized in that: Modifying the model feature list and updating the voxel attribute table in step 3) include three types of operations: inserting, deleting and modifying, specifically: 1) Insert Insert the F2 feature node at the F1 feature node by any operation to generate an F2 node and a parent node with an empty voxel state table; set the update label f of F2 and its ancestor nodes to 1, and then search for the node grid with the update label f of 1 according to the feature history tree for recursive update; Since the voxel state table of the parent node is empty, the voxel state table is updated at the union of the feature ranges of the left and right subtrees, and its own feature range is obtained until no other nodes need to be updated, and the update labels f of all nodes are set to 0; 2) Delete Set the update labels f of the ancestor nodes of the F1 feature node to 1. After that, delete the F1 feature node, and its parent node will also be deleted. Since the feature range information of the deleted node is lost, the voxel state tables of all its ancestor nodes will be deleted. Then update the node grid until there are no other nodes to be updated, and set the update labels f of all nodes to 0. 3) Modification Modify the attributes of a feature node model, set the update labels f of the node and its ancestor nodes to 1, and then recursively update the grid nodes; until there are no other nodes that need to be updated, set the update labels f of all nodes to 0.
