Grid node position adjustment method and device based on geometric feature recognition

By building feature recognition models, etc., the grid nodes are adjusted according to the relationship between nodes and geometric features, the problem of failure to consider the correspondence relationship of geometric features in grid smoothness optimization is solved, and the consistency between grid nodes and components and the improvement of grid smoothness quality is achieved.

CN118965912BActive Publication Date: 2025-03-28ZHEJIANG YUANSUAN TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411408279.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-10
Publication Date
2025-03-28
Estimated Expiration
2044-10-10

AI Technical Summary

Technical Problem

In the process of finite element grid smoothness optimization, the geometric characteristics correspondence between the grid nodes and parts cannot be effectively considered, resulting in low quality of the grid smoothness, large errors in the simulation results, and may lead to distortion and deformation of the grid.

Method used

By constructing a feature recognition model, deformation calculation model, movement target model and position adjustment model, the target node to be adjusted is determined according to the relationship between the node and the geometric features, and a deformation control node is set to minimize the mesh deformation, determine the movement direction of the target node, and realize the position adjustment of the mesh node based on geometric feature recognition.

Benefits of technology

Effectively ensure the consistency of the geometric characteristics of the grid nodes and components, avoid grid distortion and deformation, improve the smooth quality of the grid files, and improve the accuracy and reliability of simulation results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118965912B_ABST
    Figure CN118965912B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and device for adjusting the position of grid nodes based on geometric feature recognition, and belongs to the technical field of grid optimization. The existing scheme guides the position adjustment of grid nodes through regular points, does not consider the corresponding relationship between the grid nodes and the geometric features of parts, and cannot ensure that the geometric features of the grid nodes and parts are consistent. The method for adjusting the position of grid nodes based on geometric feature recognition of the present invention determines the target node to be adjusted according to the relationship between the node and the geometric feature; and sets a deformation control node so that the deformation of the grid formed by the target node and the adjacent nodes is minimized, and at the same time determines the moving direction of the target node, so as to realize the grid node position adjustment based on geometric feature recognition, thereby effectively ensuring the consistency of the geometric features of the grid nodes and parts, avoiding distortion and deformation of the adjusted grid, and thus effectively improving the smoothing quality of the grid file, and improving the accuracy and reliability of the simulation results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a grid node position adjustment method and equipment based on geometric feature recognition, and belongs to the technical field of grid optimization. Background Art

[0002] In the process of automobile design and manufacturing, finite element meshing is a basic step in simulation using computer-aided engineering (CAE) software and is crucial to simulation accuracy and reliability.

[0003] The Chinese patent (CN113792459B) discloses a method and device for optimizing mesh smoothing of finite element triangular meshes. First, the triangular mesh units are regarded as independent mesh units that are not connected to each other. The positions of the three nodes of the triangle are gradually adjusted to approach the positions of the regular points through the guidance of regular points to achieve mesh smoothing of a single independent mesh unit, and then these separated independent mesh units after mesh smoothing optimization are assembled into a complete mesh network. In addition, the entire triangular mesh smoothing can be executed synchronously and independently, which greatly reduces the amount of calculation and improves the optimization efficiency.

[0004] The above scheme guides the position adjustment of mesh nodes through regular points to ensure the smoothness of mesh lines, but does not consider the correspondence between mesh nodes and the geometric features of parts. If the geometric features of mesh nodes and parts are inconsistent after mesh smoothing optimization, it will affect the smoothing quality of the mesh file and cause large errors in simulation results.

[0005] Furthermore, the above scheme only performs smoothing optimization on the grid lines based on regular points, which may cause distortion and deformation of individual grids, thereby further affecting the smoothing quality of the grid file and reducing the accuracy of the finite element analysis.

[0006] The information disclosed in this Background Art is only for understanding the background of the inventive concept and therefore it may include information that does not constitute the prior art. Summary of the invention

[0007] In response to the above problem or one of the above problems, an object of the present invention is to provide a method and device for adjusting the position of grid nodes based on geometric feature recognition, by constructing a feature recognition model, a deformation calculation model, a moving target model, and a position adjustment model, and determining the target node to be adjusted according to the relationship between the node and the geometric feature; and setting a deformation control node so that the grid deformation formed by the target node and the adjacent nodes is minimized, and at the same time determining the moving direction of the target node, to achieve grid node position adjustment based on geometric feature recognition, thereby effectively ensuring the consistency of the geometric features of the grid nodes and parts, avoiding distortion and deformation of the adjusted grid, and thus effectively improving the smoothness quality of the grid file and improving the accuracy and reliability of the simulation results.

[0008] In view of the above problem or one of the above problems, the second purpose of the present invention is to provide a method and device for adjusting the position of grid nodes based on geometric feature recognition, and determine the target node to be adjusted according to the relationship between the node and the geometric feature, so that the geometric features of the grid and the parts are consistent, ensuring that the grid nodes can accurately reflect the geometric features of the parts. At the same time, the minimum deformation is introduced to guide the direction of node movement, that is, to move towards the position with the minimum deformation energy, so as to reduce the distortion and deformation of the grid, thereby effectively improving the accuracy and reliability of the grid node adjustment scheme.

[0009] To achieve one of the above purposes, the first technical solution of the present invention is:

[0010] The mesh node position adjustment method based on geometric feature recognition includes the following contents:

[0011] The mesh file is processed through a pre-built feature recognition model to obtain a number of nodes, and the target nodes to be adjusted are determined based on the relationship between the nodes and the geometric features;

[0012] Using the pre-built deformation calculation model, based on the target node, the deformation control node and its coordinates are solved; the deformation control node minimizes the mesh deformation formed by the target node and the adjacent nodes;

[0013] Using the pre-built moving target model, the moving direction of the target node is determined according to the deformation control node and its coordinates, and the objective function is constructed with the goal of mesh smoothness and uniformity;

[0014] The pre-built position adjustment model is used to solve the objective function, obtain the latest coordinate value of the target node, and realize the mesh node position adjustment based on geometric feature recognition.

[0015] The present invention constructs a feature recognition model, a deformation calculation model, a moving target model, and a position adjustment model, and determines the target node to be adjusted according to the relationship between the node and the geometric feature; and sets the deformation control node so that the mesh deformation formed by the target node and the adjacent nodes is minimized, and at the same time determines the moving direction of the target node, so as to realize the mesh node position adjustment based on geometric feature recognition, thereby effectively ensuring the consistency of the geometric features of the mesh node and the parts, avoiding the distortion and deformation of the adjusted mesh, and thus effectively improving the smoothing quality of the mesh file, and improving the accuracy and reliability of the simulation results.

[0016] Furthermore, the present invention fully considers the correspondence between the grid nodes and the geometric features of the parts, and identifies the positional relationship between the grid nodes and the geometric features of the parts by constructing a feature recognition model, ensuring that the grid nodes can remain consistent with the geometric features of the parts after adjustment, so that the grid nodes can accurately reflect the geometric features of the parts.

[0017] Furthermore, the present invention sets the moving direction of the target node through a deformation calculation model and a moving target model, and minimizes the mesh deformation formed by the moved target node and the adjacent nodes; that is, the direction of node movement is guided by the minimum deformation amount, so that the node moves toward the position with the minimum deformation energy, thereby reducing the distortion and deformation of the mesh, further affecting the smoothness quality of the mesh file, and improving the accuracy of finite element analysis, which in turn helps to speed up the process of product design and analysis, reduce R&D costs, and improve product quality.

[0018] As the preferred technical measures:

[0019] The method of processing the mesh file through the pre-built feature recognition model to obtain several nodes and determining the target nodes to be adjusted according to the relationship between the nodes and the geometric features is as follows:

[0020] Obtain the finite element mesh file of a part, judge the quality of the finite element mesh file, and select the quadrilateral mesh with unqualified quality as the target mesh, that is, the mesh to be adjusted;

[0021] Read all nodes of the target grid, including node numbers and their corresponding coordinate information;

[0022] The computer vision library is used to construct geometric features, and the read nodes are classified to obtain the nodes located on the geometric features and the nodes not on the geometric features;

[0023] The nodes that are not on the geometric features are taken as the target nodes to be adjusted.

[0024] As the preferred technical measures:

[0025] The method of constructing geometric features and classifying the read nodes is as follows:

[0026] Marking all nodes in the target grid with a first color to form a node image;

[0027] Based on the shape features of a part, a second color is used to mark the mesh file, obtain feature lines, and form geometric features;

[0028] The color channel algorithm is used to filter out all feature line information, and the feature lines in the grid file are extracted through edge detection;

[0029] For each node, construct the characteristic line equation;

[0030] Based on the characteristic line equation, calculate the difference distance from each node to the characteristic line;

[0031] When the difference distance is less than the difference threshold, add the node to the first list array

[0032] Otherwise, add the node to the second list array;

[0033] After iterating over all nodes, the second list array is used as the target node information.

[0034] As the preferred technical measures:

[0035] Using the pre-built deformation calculation model, based on the target node, the method for solving the deformation control node and its coordinates is as follows:

[0036] Based on the target node information, all adjacent nodes are obtained;

[0037] From the target node information, select a target node and connect it with adjacent nodes to obtain a polygon consisting of four triangles;

[0038] For any triangle, construct an equilateral triangle on the same side as the base of the triangle;

[0039] Then calculate the height of the base of the triangle, one, and the height of the base of the regular triangle, two;

[0040] Then calculate the distance between the vertices of the triangle and the vertices of the regular triangle;

[0041] According to height one, height two and interval distance, a deformation calculation formula is constructed;

[0042] Based on the deformation calculation formula, the mesh nodes are adjusted so that after the mesh nodes are displaced, the sum of the deformations of all triangles belonging to the mesh nodes is minimized;

[0043] The mesh node that minimizes the sum of deformations is used as the deformation control node, and its displacement coordinates are used as the adjustment boundary of the optimization point.

[0044] As the preferred technical measures:

[0045] Using the pre-built moving target model, the moving direction of the target node is determined according to the deformation control node and its coordinates, and the mesh smoothness and uniformity are taken as the goal. The method of constructing the objective function is as follows:

[0046] According to the deformation control node and its coordinates, the optimal path for the position of the target node is constructed and used as the moving direction of the target node;

[0047] With the goal of making the mesh smooth and uniform, set relevant variables and expected results;

[0048] The relevant variables include the number of nodes that do not satisfy the grid and the distance moved relative to the target node;

[0049] The desired result is to reduce the number of nodes that do not satisfy the grid as a whole and minimize the distance moved relative to the target node;

[0050] According to the relevant variables and expected results, the objective function is constructed to obtain the optimal grid location points.

[0051] As the preferred technical measures:

[0052] Using the pre-built position adjustment model, the objective function is solved to obtain the latest coordinate value of the target node. The method for implementing the position adjustment of the mesh node based on geometric feature recognition is as follows:

[0053] The displacement coordinates of the deformation control nodes are used as adjustment boundaries, and the positions of the target nodes are gradually adjusted through the node position adjustment algorithm under the guidance of the objective function until a global optimal solution is found.

[0054] The global optimal solution is used as the latest coordinate value of the target node, and according to the latest coordinate value, the position of the grid node is adjusted and the shape of the target grid is changed to obtain a smooth and uniform grid.

[0055] As the preferred technical measures:

[0056] The method of finding a global optimal solution through the node position adjustment algorithm is as follows:

[0057] Set the initial node coordinates, final node coordinates and the upper limit of the number of iterations;

[0058] The initial node coordinates are the original target node coordinates; the final node coordinates are the latest coordinate values ​​of the target node;

[0059] Based on the initial node coordinates, generate a new node coordinate;

[0060] According to the new coordinates of the nodes, the deformation increment of the target mesh is calculated;

[0061] If the deformation increment is less than zero, the new node coordinates are accepted as the final node coordinates;

[0062] If the deformation increment is greater than or equal to zero, the initial node coordinate value is reduced and the iteration is repeated until the termination condition is met;

[0063] When the termination condition is met, the new node coordinates at this time are output as the global optimal solution.

[0064] As the preferred technical measures:

[0065] The termination condition is that the new coordinates of several consecutive nodes are not accepted;

[0066] Or / and, the termination condition is that the number of iterations is equal to the upper limit of the number of iterations;

[0067] Or / and, the termination condition is that the initial node coordinate value is greater than or equal to the final node coordinate value.

[0068] To achieve one of the above purposes, the second technical solution of the present invention is:

[0069] The method for adjusting the position of mesh nodes based on geometric feature recognition comprises the following steps:

[0070] Step 1: Process the grid file to obtain several nodes, and determine the target nodes to be adjusted according to the relationship between the nodes and the geometric features;

[0071] Step 2: Based on the target node, the deformation control node and its coordinates are obtained; the deformation control node minimizes the mesh deformation formed by the target node and the adjacent nodes;

[0072] Step 3: Determine the moving direction of the target node according to the deformation control node and its coordinates, and construct the objective function with the goal of mesh smoothness and uniformity;

[0073] Step 4: Solve the objective function to obtain the latest coordinate value of the target node and realize the grid node position adjustment based on geometric feature recognition.

[0074] The present invention determines the target node to be adjusted based on the relationship between the node and the geometric feature, so that the geometric features of the mesh and the parts are consistent, ensuring that the mesh nodes can accurately reflect the geometric features of the parts. At the same time, the minimum deformation is introduced to guide the direction of node movement, that is, to move towards the position with the minimum deformation energy, which can reduce the distortion and deformation of the mesh, thereby effectively improving the accuracy and reliability of the mesh node adjustment scheme.

[0075] To achieve one of the above purposes, the third technical solution of the present invention is:

[0076] A grid node position adjustment device based on geometric feature recognition, comprising:

[0077] one or more processors;

[0078] A storage device for storing one or more programs;

[0079] When the one or more programs are executed by the one or more processors, the one or more processors implement the above-mentioned method for adjusting the position of grid nodes based on geometric feature recognition.

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

[0081] The present invention constructs a feature recognition model, a deformation calculation model, a moving target model, and a position adjustment model, and determines the target node to be adjusted according to the relationship between the node and the geometric feature; and sets the deformation control node so that the mesh deformation formed by the target node and the adjacent nodes is minimized, and at the same time determines the moving direction of the target node, so as to realize the mesh node position adjustment based on geometric feature recognition, thereby effectively ensuring the consistency of the geometric features of the mesh node and the parts, avoiding the distortion and deformation of the adjusted mesh, and thus effectively improving the smoothing quality of the mesh file, and improving the accuracy and reliability of the simulation results.

[0082] Furthermore, the present invention fully considers the correspondence between the grid nodes and the geometric features of the parts, and identifies the positional relationship between the grid nodes and the geometric features of the parts by constructing a feature recognition model, ensuring that the grid nodes can remain consistent with the geometric features of the parts after adjustment, so that the grid nodes can accurately reflect the geometric features of the parts.

[0083] Furthermore, the present invention sets the moving direction of the target node through a deformation calculation model and a moving target model, and minimizes the mesh deformation formed by the moved target node and the adjacent nodes; that is, the direction of node movement is guided by the minimum deformation amount, so that the node moves toward the position with the minimum deformation energy, thereby reducing the distortion and deformation of the mesh, further affecting the smoothness quality of the mesh file, and improving the accuracy of finite element analysis, which in turn helps to speed up the process of product design and analysis, reduce R&D costs, and improve product quality.

[0084] Furthermore, the present invention determines the target node to be adjusted based on the relationship between the node and the geometric feature, which can make the mesh consistent with the geometric features of the parts and ensure that the mesh nodes can accurately reflect the geometric features of the parts. At the same time, the minimum deformation is introduced to guide the direction of node movement, that is, to move towards the position with the minimum deformation energy, which can reduce the distortion and deformation of the mesh, thereby effectively improving the accuracy and reliability of the mesh node adjustment scheme. BRIEF DESCRIPTION OF THE DRAWINGS

[0085] Figure 1 A schematic diagram of a flow chart of a method for adjusting the position of a grid node according to the present invention;

[0086] Figure 2 A schematic diagram of a polygon formed by connecting a target node and adjacent nodes of the present invention;

[0087] Figure 3 A schematic diagram of a quadrilateral grid to be adjusted according to the present invention;

[0088] Figure 4 A schematic diagram of nodes and feature lines extracted by the present invention;

[0089] Figure 5 A schematic diagram of the grid node position adjustment result of the present invention. DETAILED DESCRIPTION

[0090] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0091] On the contrary, the present invention covers any substitution, modification, equivalent method and scheme made on the essence and scope of the present invention as defined by the claims. Further, in order to make the public have a better understanding of the present invention, some specific details are described in detail in the following detailed description of the present invention. Those skilled in the art can fully understand the present invention without the description of these details.

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

[0093] like Figure 1 As shown, the first specific embodiment of the method for adjusting the position of grid nodes based on geometric feature recognition of the present invention is as follows:

[0094] The mesh node position adjustment method based on geometric feature recognition includes the following contents:

[0095] The mesh file is processed through a pre-built feature recognition model to obtain a number of nodes, and the target nodes to be adjusted are determined based on the relationship between the nodes and the geometric features;

[0096] Using the pre-built deformation calculation model, based on the target node, the deformation control node and its coordinates are solved; the deformation control node minimizes the mesh deformation formed by the target node and the adjacent nodes;

[0097] Using the pre-built moving target model, the moving direction of the target node is determined according to the deformation control node and its coordinates, and the objective function is constructed with the goal of mesh smoothness and uniformity;

[0098] The pre-built position adjustment model is used to solve the objective function, obtain the latest coordinate value of the target node, and realize the mesh node position adjustment based on geometric feature recognition.

[0099] In this embodiment, the method of processing the grid file by using the pre-built feature recognition model to obtain a number of nodes and determining the target node to be adjusted according to the relationship between the node and the geometric feature is as follows:

[0100] Obtain the finite element mesh file of a part, judge the quality of the finite element mesh file, and select the quadrilateral mesh with unqualified quality as the target mesh, that is, the mesh to be adjusted;

[0101] Read all nodes of the target grid, including node numbers and their corresponding coordinate information;

[0102] The computer vision library OpenCV is used to construct geometric features, and the read nodes are classified to obtain the nodes located on the geometric features and the nodes not on the geometric features;

[0103] The nodes that are not on the geometric features are taken as the target nodes to be adjusted.

[0104] In this embodiment, the method of constructing geometric features and classifying the read nodes is as follows:

[0105] Marking all nodes in the target grid with a first color to form a node image;

[0106] Based on the shape features of a part, a second color is used to mark the mesh file, obtain feature lines, and form geometric features;

[0107] The color channel algorithm is used to filter out all feature line information, and the feature lines in the grid file are extracted through edge detection;

[0108] For each node, construct the characteristic line equation;

[0109] Based on the characteristic line equation, calculate the difference distance from each node to the characteristic line;

[0110] When the difference distance is less than the difference threshold, add the node to the first list array

[0111] Otherwise, add the node to the second list array;

[0112] After iterating over all nodes, the second list array is used as the target node information.

[0113] In this embodiment, the method of obtaining the deformation control node and its coordinates based on the target node by using the pre-built deformation calculation model is as follows:

[0114] Based on the target node information, all adjacent nodes are obtained;

[0115] From the target node information, select a target node and connect it with adjacent nodes to obtain a polygon consisting of four triangles;

[0116] For any triangle, construct an equilateral triangle on the same side as the base of the triangle;

[0117] Then calculate the height of the base of the triangle, one, and the height of the base of the regular triangle, two;

[0118] Then calculate the distance between the vertices of the triangle and the vertices of the regular triangle;

[0119] According to height one, height two and interval distance, a deformation calculation formula is constructed;

[0120] Based on the deformation calculation formula, the mesh nodes are adjusted so that after the mesh nodes are displaced, the sum of the deformations of all triangles belonging to the mesh nodes is minimized;

[0121] The mesh node that minimizes the sum of deformations is used as the deformation control node, and its displacement coordinates are used as the adjustment boundary of the optimization point.

[0122] In this embodiment: a pre-built moving target model is used to determine the moving direction of the target node according to the deformation control node and its coordinates, and the smoothness and uniformity of the mesh are taken as the goal. The method for constructing the objective function is as follows:

[0123] According to the deformation control node and its coordinates, the optimal path for the position of the target node is constructed and used as the moving direction of the target node;

[0124] With the goal of making the mesh smooth and uniform, set relevant variables and expected results;

[0125] The relevant variables include the number of nodes that do not satisfy the grid and the distance moved relative to the target node;

[0126] The desired result is to reduce the number of nodes that do not satisfy the grid as a whole and minimize the distance moved relative to the target node;

[0127] According to the relevant variables and expected results, the objective function is constructed to obtain the optimal grid location points.

[0128] In this embodiment, the method of using the pre-built position adjustment model to solve the objective function and obtain the latest coordinate value of the target node to achieve the mesh node position adjustment based on geometric feature recognition is as follows:

[0129] The displacement coordinates of the deformation control nodes are used as adjustment boundaries, and the positions of the target nodes are gradually adjusted through the node position adjustment algorithm under the guidance of the objective function until a global optimal solution is found.

[0130] The global optimal solution is used as the latest coordinate value of the target node, and according to the latest coordinate value, the position of the grid node is adjusted and the shape of the target grid is changed to obtain a smooth and uniform grid.

[0131] In this embodiment, the method of finding a global optimal solution through the node position adjustment algorithm is as follows:

[0132] Set the initial node coordinates, final node coordinates and the upper limit of the number of iterations;

[0133] The initial node coordinates are the original target node coordinates; the final node coordinates are the latest coordinate values ​​of the target node;

[0134] Based on the initial node coordinates, generate a new node coordinate;

[0135] According to the new coordinates of the nodes, the deformation increment of the target mesh is calculated;

[0136] If the deformation increment is less than zero, the new node coordinates are accepted as the final node coordinates;

[0137] If the deformation increment is greater than or equal to zero, the initial node coordinate value is reduced and the iteration is repeated until the termination condition is met;

[0138] When the termination condition is met, the new node coordinates at this time are output as the global optimal solution.

[0139] In this embodiment: the termination condition is that the new coordinates of several consecutive nodes are not accepted.

[0140] A second specific embodiment of the method for adjusting the position of grid nodes based on geometric feature recognition of the present invention:

[0141] The method for adjusting the position of mesh nodes based on geometric feature recognition comprises the following steps:

[0142] Step 1: Process the grid file to obtain several nodes, and determine the target nodes to be adjusted according to the relationship between the nodes and the geometric features;

[0143] Step 2: Based on the target node, the deformation control node and its coordinates are obtained; the deformation control node minimizes the mesh deformation formed by the target node and the adjacent nodes;

[0144] Step 3: Determine the moving direction of the target node according to the deformation control node and its coordinates, and construct the objective function with the goal of mesh smoothness and uniformity;

[0145] Step 4: Solve the objective function to obtain the latest coordinate value of the target node and realize the grid node position adjustment based on geometric feature recognition.

[0146] A third specific embodiment of the method for adjusting the position of grid nodes based on geometric feature recognition of the present invention:

[0147] The mesh node position adjustment method based on geometric feature recognition includes the following contents:

[0148] After obtaining the finite element mesh file of the part from the computer-aided engineering (CAE) software, first, the mesh nodes are identified according to the relationship between the nodes and the geometric features through the feature recognition model, and then the mesh nodes are classified, and the points that are not on the geometric features are taken as the target nodes to be adjusted; then, a deformation calculation model with the minimum deformation as the target is established according to the relationship between the target node and its neighboring nodes; then, the target node and its neighboring nodes are substituted into the deformation calculation model to solve the node that makes the mesh minimally deformed and the coordinate point of the node. The moving target model uses the coordinate point as the guiding moving direction, and then constructs the objective function. Then, the position adjustment model uses the simulated annealing algorithm to find the minimum value of the objective function. Through the simulated annealing algorithm, the position of the target node can be gradually adjusted under the guidance of the objective function until a global optimal or approximately optimal solution is found, thereby obtaining a smoother and more uniform mesh.

[0149] A fourth specific embodiment of the method for adjusting the position of a grid node based on geometric feature recognition of the present invention:

[0150] The method for adjusting the position of mesh nodes based on geometric feature recognition comprises the following steps:

[0151] S1: Obtain the finite element mesh of the automobile part from the computer-aided engineering (CAE) software, make a judgment based on the imported mesh quality file, and use the quadrilateral mesh with unqualified quality in the finite element mesh as the target mesh, that is, the mesh to be adjusted.

[0152] S2: Read all node information of a grid that needs to be adjusted, including the node number and its corresponding coordinate information.

[0153] S3: Classify the read nodes. The classification algorithm uses the computer vision library OpenCV to construct geometric features and grid nodes. The grid nodes are divided into nodes located on the geometric feature line and nodes not on the geometric feature line. The entire classification process is as follows:

[0154] 1) Set up two arrays, which include a first list array and a second list array, and initialize the two arrays;

[0155] The first list array is used to store the grid point numbers and node coordinates located on the feature line, and the second list array is used to store the grid node numbers and node coordinates that are not on the feature line.

[0156] Setting the difference threshold , which is used to determine the distance difference range between the grid point and the feature line. The value range of the difference threshold is as follows:

[0157]

[0158] 2) Use one or more colors to mark all nodes of the mesh and characteristic lines of the car parts on the image.

[0159] 3) Use the color channel to filter out all feature line information from the image, and extract the feature lines in the image through edge detection.

[0160] 4) For each node (x, y), determine whether it is located on the geometric feature line. The specific method is as follows:

[0161] The first step is to construct the characteristic line equation, which is expressed as follows:

[0162]

[0163] in, are the control parameters of the equation respectively.

[0164] The second step is to calculate the distance from the node to the feature line. , and its calculation formula is as follows:

[0165]

[0166] Step 3: If the distance Less than or equal to difference threshold If yes, add the node to the first list array, otherwise, add the node to the second list array.

[0167] S4: Taking the second list array set obtained in step S3 as the target node, traversing the target node, and obtaining all nodes adjacent to the target node according to the grid coordinate information of the computer-aided engineering (CAE) software.

[0168] S5: Select a target adjustment node P and connect it with adjacent nodes to obtain a polygon consisting of four triangles. Figure 2 , polygons include triangle k1, triangle k2, triangle k3, and triangle k4.

[0169] For any triangle , construct the triangle with the base Equilateral triangles on the same side , and calculate the triangle Bottom High up ,triangle Bottom High up , and the vertex and vertices The distance between , the specific height distance calculation formula is as follows:

[0170]

[0171]

[0172]

[0173] in For the bottom edge Length, and Vertex The horizontal and vertical coordinates of and Vertex The horizontal and vertical coordinates of For triangle area.

[0174] Furthermore, we calculate the triangle Deformation , and the deformation calculation formula is as follows:

[0175]

[0176] The optimization goal is to , so that after the displacement, the sum of the deformations of all triangles in the node area Reach the minimum, where is the displacement of node i in the x and y directions, and the deformation target calculation formula is as follows:

[0177]

[0178] Through the above formula, the position coordinates that can be obtained are the target node Position node with minimum deformation in space , this position node serves as the adjustment boundary of the optimization point.

[0179] S6: According to the adjustment boundary obtained in S5, at the target node that needs to be adjusted and the new location node Between, construct the moving direction, and then construct the objective function The expected result is to reduce the number of unsatisfied grids and relative to the original coordinates The moving distance is the smallest, that is, for the moving point found in space , which can make the objective function The value of is the smallest, and its expression is as follows:

[0180]

[0181] in, It refers to the number of meshes that do not satisfy the overall mesh, and this value can be obtained through computer-aided engineering (CAE) software.

[0182] S7: Based on the boundary obtained in S5 and the objective function defined in S6, the simulated annealing algorithm is used to solve the problem, thereby obtaining the optimal coordinate point. The process is as follows:

[0183] Step 1: Set the initial temperature , Final temperature , and initialize, the initial solution state is the node that needs to be adjusted , each temperature The upper limit of the number of iterations is .

[0184] Step 2: When the number of iterations is less than the upper limit of the number of iterations , and repeat steps 3 to 6.

[0185] Step 3: During execution, a new solution will be generated. .

[0186] Step 4: Calculate the increment based on the new solution , and its calculation formula is as follows:

[0187]

[0188] in, is the objective function.

[0189] Step 5: If the increment is less than 0, accept the new solution As the new current solution, otherwise accept it with incremental probability As the new current solution, the incremental probability The calculation formula is as follows:.

[0190]

[0191] in, It is an exponential function with the natural constant e as base.

[0192] Step 6: If the termination condition is met, the current solution is output as the optimal solution and the program ends. The termination condition is usually taken as the termination of the algorithm when several consecutive new solutions are not accepted.

[0193] Step 7, Initial Temperature Gradually decrease, and when , proceed to step 2.

[0194] S8: According to the coordinate point positions obtained in step S7, the coordinates of the target points of the grid are updated and adjusted to ensure that the position of each node is improved after optimization.

[0195] S9: Repeat steps S2 to S8 for each mesh that does not meet the quality requirements, and ensure that the overall quality of the mesh is evenly improved by optimizing each node one by one.

[0196] An embodiment of applying the present invention to adjust the grid nodes of a certain automobile component:

[0197] The steps of using the present invention to adjust the grid nodes of a certain automobile floor component are as follows:

[0198] Step 1: Obtain the mesh file of the automobile floor parts, and then perform preliminary mesh division on the mesh file.

[0199] Step 2: Obtain a mesh quality file, which includes some mesh indicator thresholds, such as a quadrilateral mesh angle greater than 30 degrees and less than 150 degrees.

[0200] Check the mesh files of the parts according to the mesh quality file, filter out the meshes that need to be adjusted, and color the meshes that do not meet the quality requirements.

[0201] Step 3, read the surrounding grids that need to be adjusted and the node numbers included in each grid unit.

[0202] Step 4: Take a quadrilateral mesh to be adjusted as an example. Figure 3 , Figure 3 The orange grids in the figure are grids whose annotated angles do not meet the threshold. Figure 3 The green lines in the figure are geometric feature lines.

[0203] Select one of the grid points of the quadrilateral grid , use color to mark the node and feature line on the image, use the color channel to filter out all feature line information from the image, and extract the feature lines and nodes in the image through edge detection. The marking results can be seen in Figure 4 .

[0204] Calculate the distance from grid point A to the feature line , and its calculation formula is as follows:

[0205]

[0206] Therefore, it can be seen that the distance from grid point A to the feature line is much greater than the difference threshold , thus judging that this point is not on the feature line, so it is stored in the second list array set.

[0207] Step 5: Substitute the nodes in the second list array set and their adjacent nodes into the above height distance calculation formula to establish a three-dimensional mesh deformation measurement system. Then, the coordinate point position of the minimum deformation of the mesh point is solved through the deformation target calculation formula. .

[0208] Step 6: Take the line connecting the original coordinates and the coordinate point where the minimum deformation is located as the search area and construct the objective function. The expression of the objective function is as follows:

[0209]

[0210] According to the objective function, the simulated annealing algorithm is used to solve and the initial temperature is set , final temperature , the number of iterations for each temperature , the termination condition is that the temperature drops to the final temperature.

[0211] Step 7: After lowering the set minimum temperature T' through the simulated annealing algorithm, the coordinates of the optimal solution are obtained. The coordinates are used to replace the original coordinate points and applied to the computer-aided engineering (CAE) software to obtain the position adjustment results of the grid nodes. Figure 5 ,pass Figure 5 It can be seen that the adjusted points make the mesh meet the requirements in the preset mesh quality file. At the same time, using computer-aided engineering software CAD, the color of the problematic mesh is changed from orange to gray, thus completing the adjustment of the current mesh.

[0212] Step 8: Adjust all problematic meshes of a certain automobile floor component according to steps 4, 5, 6, and 7, so as to obtain the final mesh optimization result.

[0213] After experimental testing, for parts of automobile floors, in the computer-aided engineering software CAD software, the number of initial divided grids was 256,231, and the number of problematic grids was 1,375. By applying the adjustment method of the present invention, 874 grid adjustments were completed within 18 minutes, which saved 80% of the time compared to manual adjustment of about 2 hours.

[0214] Therefore, the geometric feature recognition technology of the present invention can make the geometric features of the mesh consistent with those of the parts, ensuring that the mesh nodes can accurately reflect the geometric features of the parts. At the same time, the mesh node position adjustment method of the present invention ensures the smoothness and uniformity of the mesh, meeting the requirements of analysis and calculation.

[0215] Furthermore, the grid node position adjustment scheme of the present invention introduces minimum deformation and simulated annealing algorithms to improve the grid quality. Minimum deformation is used to guide the direction of node movement, that is, to move towards the position with the minimum deformation energy, which can reduce the distortion and deformation of the grid. The simulated annealing algorithm is an optimization algorithm that can accept inferior solutions with a certain probability in the search space, thereby avoiding falling into the local optimal solution and ensuring that the global optimal node position is found.

[0216] Furthermore, the solution of the present invention not only improves the accuracy and reliability of finite element analysis, but also provides engineers with an efficient meshing tool, which helps to speed up the process of product design and analysis, reduce R&D costs, and improve product quality.

[0217] An embodiment of a device applying the method of the present invention:

[0218] An electronic device comprising:

[0219] one or more processors;

[0220] A storage device for storing one or more programs;

[0221] When the one or more programs are executed by the one or more processors, the one or more processors implement the above-mentioned method for adjusting the position of grid nodes based on geometric feature recognition.

[0222] A computer medium embodiment using the method of the present invention:

[0223] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the above-mentioned method for adjusting the position of grid nodes based on geometric feature recognition.

[0224] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, and computer program products. Therefore, the present application may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present application may take the form of a computer program product implemented on one or more computer-usable storage media including computer-usable program code.

[0225] The present application is described by flowcharts or / and block diagrams of the methods, devices (systems), and computer program products of the embodiments of the present application. It should be understood that each process or / and block in the flowchart or / and block diagram and the combination of the processes or / and blocks in the flowchart or / and block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart or / and block diagram. Figure 1 Process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0226] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 Process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0227] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 Process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0228] The model in this application is an object that objectively describes the morphological structure with the help of physical or virtual representation. The object is not equal to the object and is not limited to physical and virtual. It can be a data processing function, software program, processing mode, usage method, operation method, workflow, application process, electronic hardware, circuit module, processing system, system imitation or simulation object.

[0229] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field can still modify or replace the specific implementation methods of the present invention with equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be included in the scope of protection of the claims of the present invention.

Claims

1. A grid node position adjustment method based on geometric feature recognition, characterized in that: Includes the following: The mesh file is processed through a pre-built feature recognition model to obtain a number of nodes, and the target nodes to be adjusted are determined based on the relationship between the nodes and the geometric features; The method is as follows: Obtain the finite element mesh file of a part, judge the quality of the finite element mesh file, and select the quadrilateral mesh with unqualified quality as the target mesh, that is, the mesh to be adjusted; Read all nodes of the target grid, including node numbers and their corresponding coordinate information; The computer vision library is used to construct geometric features, and the read nodes are classified to obtain the nodes located on the geometric features and the nodes not on the geometric features; The nodes that are not on the geometric features are taken as the target nodes to be adjusted; Using the pre-built deformation calculation model, based on the target node, the deformation control node and its coordinates are obtained; The deformation control node minimizes the mesh deformation formed by the target node and adjacent nodes; Using the pre-built moving target model, the moving direction of the target node is determined according to the deformation control node and its coordinates, and the objective function is constructed with the goal of mesh smoothness and uniformity; The pre-built position adjustment model is used to solve the objective function, obtain the latest coordinate value of the target node, and realize the mesh node position adjustment based on geometric feature recognition.

2. The method for adjusting the position of mesh nodes based on geometric feature recognition according to claim 1, characterized in that: The method of constructing geometric features and classifying the read nodes is as follows: Marking all nodes in the target grid with a first color to form a node image; Based on the shape features of a part, a second color is used to mark the mesh file, obtain feature lines, and form geometric features; The color channel algorithm is used to filter out all feature line information, and the feature lines in the grid file are extracted through edge detection; For each node, construct the characteristic line equation; Based on the characteristic line equation, calculate the difference distance from each node to the characteristic line; When the difference distance is less than the difference threshold, add the node to the first list array Otherwise, add the node to the second list array; After iterating over all nodes, the second list array is used as the target node information.

3. The method for adjusting the position of mesh nodes based on geometric feature recognition according to claim 1, characterized in that: Using the pre-built deformation calculation model, based on the target node, the method for solving the deformation control node and its coordinates is as follows: Based on the target node information, all adjacent nodes are obtained; From the target node information, select a target node and connect it with adjacent nodes to obtain a polygon consisting of four triangles; For any triangle, construct an equilateral triangle on the same side as the base of the triangle; Then calculate the height of the base of the triangle, one, and the height of the base of the regular triangle, two; Then calculate the distance between the vertices of the triangle and the vertices of the regular triangle; According to height one, height two and interval distance, a deformation calculation formula is constructed; Based on the deformation calculation formula, the mesh nodes are adjusted so that after the mesh nodes are displaced, the sum of the deformations of all triangles belonging to the mesh nodes is minimized; The mesh node that minimizes the sum of deformations is used as the deformation control node, and its displacement coordinates are used as the adjustment boundary of the optimization point.

4. The method for adjusting the position of mesh nodes based on geometric feature recognition according to claim 1, characterized in that: Using the pre-built moving target model, the moving direction of the target node is determined according to the deformation control node and its coordinates, and the mesh smoothness and uniformity are taken as the goal. The method of constructing the objective function is as follows: According to the deformation control node and its coordinates, the optimal path for the position of the target node is constructed and used as the moving direction of the target node; With the goal of making the mesh smooth and uniform, set relevant variables and expected results; The relevant variables include the number of nodes that do not satisfy the grid and the distance moved relative to the target node; The desired result is to reduce the number of nodes that do not satisfy the grid as a whole and minimize the distance moved relative to the target node; According to the relevant variables and expected results, the objective function is constructed to obtain the optimal grid location points.

5. The method for adjusting the position of mesh nodes based on geometric feature recognition according to claim 1, characterized in that: Using the pre-built position adjustment model, the objective function is solved to obtain the latest coordinate value of the target node. The method for implementing the position adjustment of the mesh node based on geometric feature recognition is as follows: The displacement coordinates of the deformation control nodes are used as adjustment boundaries, and the positions of the target nodes are gradually adjusted through the node position adjustment algorithm under the guidance of the objective function until a global optimal solution is found. The global optimal solution is used as the latest coordinate value of the target node, and according to the latest coordinate value, the position of the grid node is adjusted and the shape of the target grid is changed to obtain a smooth and uniform grid.

6. The method for adjusting the position of grid nodes based on geometric feature recognition according to claim 5, characterized in that: The method of finding a global optimal solution through the node position adjustment algorithm is as follows: Set the initial node coordinates, final node coordinates and the upper limit of the number of iterations; The initial node coordinates are the original target node coordinates; the final node coordinates are the latest coordinate values ​​of the target node; Based on the initial node coordinates, generate a new node coordinate; According to the new coordinates of the nodes, the deformation increment of the target mesh is calculated; If the deformation increment is less than zero, the new node coordinates are accepted as the final node coordinates; If the deformation increment is greater than or equal to zero, the initial node coordinate value is reduced and the iteration is repeated until the termination condition is met; When the termination condition is met, the new node coordinates at this time are output as the global optimal solution.

7. The method for adjusting the position of grid nodes based on geometric feature recognition according to claim 6, characterized in that: The termination condition is that the new coordinates of several consecutive nodes are not accepted; Or / and, the termination condition is that the number of iterations is equal to the upper limit of the number of iterations; Or / and, the termination condition is that the initial node coordinate value is greater than or equal to the final node coordinate value.

8. A method for adjusting the position of mesh nodes based on geometric feature recognition, characterized in that: The following steps are involved: Step 1: Process the grid file to obtain several nodes, and determine the target nodes to be adjusted according to the relationship between the nodes and the geometric features; The method is as follows: Obtain the finite element mesh file of a part, judge the quality of the finite element mesh file, and select the quadrilateral mesh with unqualified quality as the target mesh, that is, the mesh to be adjusted; The method is as follows: Read all nodes of the target grid, including node numbers and their corresponding coordinate information; The computer vision library is used to construct geometric features, and the read nodes are classified to obtain the nodes located on the geometric features and the nodes not on the geometric features; The nodes that are not on the geometric features are taken as the target nodes to be adjusted; Step 2: Based on the target node, obtain the deformation control node and its coordinates; The deformation control node minimizes the mesh deformation formed by the target node and adjacent nodes; Step 3: Determine the moving direction of the target node according to the deformation control node and its coordinates, and construct the objective function with the goal of mesh smoothness and uniformity; Step 4: Solve the objective function to obtain the latest coordinate value of the target node and realize the grid node position adjustment based on geometric feature recognition.

9. A grid node position adjustment device based on geometric feature recognition, characterized in that: It includes: one or more processors; A storage device for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the grid node position adjustment method based on geometric feature recognition as described in any one of claims 1-8.

Citation Information

Patent Citations

  • A method and apparatus for mesh smoothing optimization of finite element triangular meshes

    CN113792459B

  • Compliant mechanism generation method based on zero-depletion grid curved surface continuous deformation

    CN111709097A

  • Mesh fairing optimization method and device for finite element triangular mesh

    CN113792459A