Method for measuring large-scale parts based on STL triangle facets CAD model
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA UNIV OF PETROLEUM (EAST CHINA)
- Filing Date
- 2026-02-03
- Publication Date
- 2026-06-19
Smart Images

Figure CN122237475A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of scanning instruments, and more specifically to a method for measuring large-scale parts of CAD models based on STL triangular facets. Background Technology
[0002] With the rapid development of high-precision technology industries, large-scale complex curved surfaces are increasingly prevalent in medium and large-sized equipment parts, particularly in fields such as aviation, aerospace, shipbuilding, and new energy vehicles. These parts, featuring large-scale free-form surfaces, require extremely high precision. In mass production on industrial assembly lines, ensuring production accuracy while maintaining efficiency is paramount. All mass-produced parts must meet their design specifications, and the manufactured parts must adhere to acceptable tolerances compared to the design model to achieve the same superior performance. Current developments in this field focus on automating mass production and automating online inspection of manufactured parts.
[0003] To improve the detection efficiency of large-scale freeform surfaces, mounting multi-line laser scanners on the end effector of industrial robots and using the robot's motion to drive the scanner to scan and measure the target is becoming a new direction in automated inspection. The prerequisite for the normal operation of an industrial robot scanning system is the generation of an efficient and reasonable scanning path, which can be achieved through two methods: manual teaching and offline programming. Traditional industrial robot path planning mainly relies on manual teaching, where the operator moves the robot's end effector to the target spatial position and generates a sequence of actions based on this spatial position to create the scanning path. This method is overly dependent on the operator's skill level, is time-consuming, and the path is not reproducible. Most importantly, manual setting cannot guarantee that the scanning path is optimal, and the overall scanning accuracy cannot be guaranteed. Furthermore, repetitive scanning paths significantly impact scanning efficiency.
[0004] Therefore, there is a need for a method for measuring large-scale CAD models based on STL triangular facets that can adapt to complex curved surfaces and has high scanning accuracy and efficiency. Summary of the Invention
[0005] The main objective of this invention is to provide a method for measuring large-scale parts of CAD models based on STL triangular patches, in order to solve the problems of low scanning accuracy and low scanning efficiency in the existing technology for measuring large-scale parts of CAD models.
[0006] To achieve the above objectives, this invention provides a method for measuring large-scale parts based on STL triangular facets in CAD models, specifically including the following steps: S1. The surface to be measured is divided into triangular patches using linear deviation and angular deviation, and an STL triangular patch model of the surface of the part to be measured is established.
[0007] S2, establish a neighborhood search method, and use a greedy algorithm to select initial triangular patches in sequence, and use the neighborhood search method to divide the single scan area.
[0008] S3, based on the visual cone, solves the unique measurement point orientation of each scanned area; S4, based on each scan area and the unique measurement point orientation of each scan area, solve for the optimal measurement point position of the corresponding scan area; S5. Establish a local coordinate system based on the optimal measurement point and solve the industrial robot scanning measurement path; S6 generates the execution language for industrial robots, enabling them to automatically reach the optimal measurement point and maintain the corresponding posture to scan the free-form surface of the workpiece.
[0009] Furthermore, step S1 specifically includes the following steps: S1.1, linear deviation is the maximum deviation distance between the triangular patch and the actual curved surface, expressed as: ; in, The maximum deviation distance, This is the distance between the triangular patch and the actual curved surface. This is the function for finding the maximum value.
[0010] S1.2, the angular deviation is the maximum deviation angle of the change in the normal vector angle between adjacent triangular facets, expressed as: ; in, and Let be the normal vector of the adjacent triangular facet. The angle of maximum deviation It is a cosine function.
[0011] Furthermore, step S2 specifically includes the following steps: S2.1, use a greedy algorithm to select the initial triangular facet with the area of the triangular facet as a constraint.
[0012] S2.2, Design a neighborhood search method for triangular faces in the STL model. Take all triangular faces and their three edges as a mapping set, search for adjacent triangular faces in sequence and add the triangular faces to the total area of a single scan, and then delete the searched triangular faces from the mapping set.
[0013] S2.3, determine whether the measurement range limitation conditions are met.
[0014] S2.4 If the condition is met, continue with step S2.2; otherwise, return the triangle facet to the mapping set and end the loop, completing the single scan region determination.
[0015] Furthermore, step S2.2 specifically includes the following steps: S2.2.1 Extract all triangular faces and their corresponding three edges, and treat the triangular faces and their three edges as a mapping set; set a reference plane, and find the triangular faces with edges corresponding to the reference plane from the remaining triangular faces to obtain the first-order neighborhood of the reference plane, represented as: ; in, As the reference plane, For a first-order neighborhood, For the corresponding edge of the reference plane, For the mapping set, Let be a triangular facet in a first-order neighborhood.
[0016] S2.2.2, sequentially obtain the reference planes. In the order neighborhood, remove the searched triangle faces and corresponding edges from the total set, and then... Using the corresponding triangular facet in the neighborhood as a reference, the corresponding neighborhood triangle is found in the total set, and finally the single-scan region division is completed under the constraint conditions, as shown below: ; in, for Rank neighborhood, for The corresponding edges of the triangular facets in the neighborhood of order.
[0017] Furthermore, the measurement range limitations in step S2.3 include: Take 60% of the center of the rectangular measurement area formed by the laser grid emitted by the scanner as the effective single scan range.
[0018] The included angles of the vectors corresponding to all triangular patches in a single scan region Smaller than the scanner's measurement angle range : ; in, Position of the scanner camera. For the point to be measured, For the point to be measured The normal vector of the tangent plane. It is an inverse cosine function. is the unit vector of the line connecting the camera and the point to be measured.
[0019] The angle between the normal vector at the scan point and the measurement center vector of the scanner The field of view is set to a limit less than half the center vector field of view of all added triangular facets. ; in, This is the unit normal vector for the scanner's scanning direction.
[0020] The optimal measurement distance for the scanner satisfies the following relationship: ; ; in, For optimal measurement distance of the scanner, For depth of field height, It represents the highest point of all triangle facet vertices within the range of a single scan. It represents the lowest point among all the vertices of the triangular facets within the range of a single scan.
[0021] Further, step S3 includes the following steps: S3.1, Solve for the visible cones corresponding to all triangular faces in the single-scan region obtained in step S2. Move all visible cone vertices to the same point and perform Boolean intersection to obtain the cone-like structure of the single-scan region. Take the base of the cone-like structure. A family of points to be determined is obtained by uniformly sampling points.
[0022] S3.2, take the attitude direction vector corresponding to each point in the family of points to be determined, and substitute the attitude direction vector back into all visible cones to solve for the relationship between the attitude direction vector and the coordinates of the points. The deflection angle is calculated, and the deflection angle is inversely normalized to obtain the score; where the attitude direction vector is: bottom surface The direction vector from the previous point to the vertex of the cone-like structure.
[0023] S3.3, sum all the scores and sort the sums to obtain the final score table; take the attitude direction vector corresponding to the highest score in the score table as the unique attitude direction of the measurement point in this measurement area.
[0024] S3.4 Repeat steps S3.1 to S3.3 to finally complete the attitude solution for all measurement points.
[0025] Furthermore, in step S3.1, the solution to the visible cones corresponding to all triangular facets in the single-scan region obtained in step S2 is specifically as follows: the centroid of all triangular facets in the single-scan region is taken as the point to be measured. , the point to be measured As the vertex of the visible cone, For the point to be measured The normal vector of the tangent plane, with The scanner is positioned along the axis of the visible cone, with the optimal measurement distance of the scanner as the height of the visible cone, thus obtaining the visible cone corresponding to each triangular facet. The optimal measurement distance for the scanner satisfies the following relationship: ; in, The optimal measurement distance for the scanner.
[0026] Further, step S4 includes the following steps: S4.1, Solve for the smallest region containing all centroids of the triangular facets in the single scan region obtained in step S2, and solve for the center point of the smallest region containing the centroids.
[0027] S4.2, Using the unique orientation direction of the scanned area obtained in step S3 as the orientation, translate the center point with the optimal measurement distance as the length to obtain the optimal measurement point in the current measurement area. Location; S4.3 Repeat steps S4.1 to S4.2 until the optimal measurement point location for all scanned areas is determined.
[0028] Furthermore, step S5 specifically includes: Based on the optimal measurement point Establish a local coordinate system for the optimal measurement point in each scanning area, along... The Z-axis is established along the orientation direction of the robot, the Y-axis is established in the opposite direction along the robot base mounting, and the X-axis follows a right-handed coordinate system. Using the shortest overall path as the objective function, basic constraints are set such that each optimal measurement point is visited exactly once, and each point is visited once. Conditional constraints are set to ensure that the order of the selected optimal measurement points cannot be reversed. The industrial robot scanning measurement path is then solved, expressed as: ; st ; ; ; ; in, For point coordinate, For norm, The judgment value selected for this path segment. 1. To select this path segment, 0 means this path segment is not selected. The access sequence number for point A. This represents the total number of nodes. For path point labels, This is a function that takes the minimum value.
[0029] Furthermore, step S6 specifically includes: Based on the scanning measurement path obtained in step S5, the optimal scanning sequence of measurement points is obtained, an industrial robot execution language is generated, and the robot is controlled to reach the corresponding path points in a specific posture to perform scanning measurements and obtain freeform surface scanning data.
[0030] The present invention has the following beneficial effects: This invention improves scanning accuracy while maintaining scanning efficiency by dividing the CAD model of the part to be tested into STL model triangular patches and combining the surface morphology of the freeform surface with the characteristics of the scanner to obtain personalized measurement point positions and orientations. This invention also has high adaptability and can achieve the effect of automatically and adaptively generating scanning paths on the CAD model of parts with large freeform surface characteristics. Attached Figure Description
[0031] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. In the drawings: Figure 1 A flowchart of a method for measuring large-scale parts based on STL triangular facets in a CAD model according to the present invention is shown.
[0032] Figure 2 A system diagram illustrating the application of this invention is shown.
[0033] Figure 3 The STL triangular patch model of the test piece generated using step S1 of the present invention is shown.
[0034] Figure 4 A schematic diagram of the scanning principle of the present invention is shown.
[0035] Figure 5 A schematic diagram of step S3.1 generating a cone-like structure is shown.
[0036] Figure 6 The diagram illustrates the principle of solving the visible cone in step S3 of the present invention.
[0037] Figure 7 The diagram illustrates step S5 of the present invention, which establishes a local coordinate system based on the optimal measurement point.
[0038] The reference numerals in the above figures are: 1. Optical platform; 2. Industrial robot; 3. Scanner; 4. Multi-view camera; 5. Part to be tested. Detailed Implementation
[0039] The technical solution of the present invention will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0040] like Figure 1 The method for measuring large-scale parts based on STL triangular facets in CAD models, as shown, includes the following steps: S1, using linear and angular deviations, divide the surface to be measured into triangular patches, and establish an STL triangular patch model of the surface of the part to be measured, such as... Figure 3 As shown.
[0041] S2, establish a neighborhood search method, and use a greedy algorithm to select initial triangular patches in sequence, and use the neighborhood search method to divide the single scan area.
[0042] S3, based on the visual cone, solves the orientation of the unique measurement point in each scan area.
[0043] S4, based on each scan area and the orientation of the unique measurement point in each scan area, solves for the optimal measurement point position in the corresponding scan area.
[0044] S5 establishes a local coordinate system based on the optimal measurement point and solves the scanning measurement path of the industrial robot.
[0045] S6 generates the execution language for industrial robots, enabling them to automatically reach the optimal measurement point and maintain the corresponding posture to scan the free-form surface of the workpiece.
[0046] The system apparatus to which the method provided by this invention is applied is such as Figure 2As shown, the system includes: an optical platform 1, an industrial robot 2 placed on the optical platform, and a scanner 3. It also includes a multi-view camera 4 located outside the optical platform. The scanner 3 scans the part 5 to be measured. The scanner 3 is connected to the end effector of the industrial robot 2. The industrial robot 2 has six degrees of freedom and can control the line structure scanner 3 to perform arbitrary spatial movements. The multi-view camera 4 tracks the position of the scanner 3 in real time for large-area point cloud stitching and integration. When the scanner (i.e., a multi-line laser scanner) is working, it emits lasers in three directions to weave a rectangular mesh. The multi-view camera detects the changes in the laser mesh as it moves across the surface to be measured, thus achieving three-dimensional shape reconstruction. The multi-view camera also tracks the scanner's position in real time, completing the point cloud stitching and enabling large-scale free-form surface measurement. The industrial robot has six degrees of freedom and can control the scanner to perform arbitrary spatial movements within the workspace. The tracking scanner has multiple cameras, effectively expanding the tracking range of the tracker and thus the working range of the scanner.
[0047] Specifically, step S1 includes the following steps: S1.1, linear deviation is the maximum deviation distance between the triangular patch and the actual curved surface, in mm, expressed as: ; in, The maximum deviation distance, This is the distance between the triangular patch and the actual curved surface. This is the function for finding the maximum value.
[0048] S1.2, angular deviation is the maximum deviation angle of the normal vector angle between adjacent triangular facets, in degrees, expressed as: ; in, and Let be the normal vector of the adjacent triangular facet. The angle of maximum deviation It is a cosine function.
[0049] Linear deviation and angular deviation are the deviations between the triangular facets in the STL model and the surface of the CAD model. They are used to represent the accuracy of fitting the CAD model surface using triangular facets. Setting different linear deviations and angular deviations will directly affect the number of triangular facets and their size differences, thus affecting the adaptive distribution of measurement points.
[0050] Specifically, step S2 includes the following steps: S2.1, use a greedy algorithm to select the initial triangular facet with the area of the triangular facet as a constraint.
[0051] S2.2, Design a neighborhood search method for triangular faces in the STL model. Take all triangular faces and their three edges as a mapping set, search for adjacent triangular faces in sequence and add the triangular faces to the total area of a single scan, and then delete the searched triangular faces from the mapping set.
[0052] S2.3, determine whether the measurement range limitation conditions are met.
[0053] S2.4 If the condition is met, continue with step S2.2; otherwise, return the triangle facet to the mapping set and end the loop, completing the single scan region determination.
[0054] Specifically, step S2.2 includes the following steps: S2.2.1 Extract all triangular faces and their corresponding three edges, and treat the triangular faces and their three edges as a mapping set; set a reference plane, and find the triangular faces with edges corresponding to the reference plane from the remaining triangular faces to obtain the first-order neighborhood of the reference plane, represented as: ; in, As the reference plane, For a first-order neighborhood, For the corresponding edge of the reference plane, For the mapping set, Let be a triangular facet in a first-order neighborhood.
[0055] S2.2.2, sequentially obtain the reference planes. In the order neighborhood, remove the searched triangle faces and corresponding edges from the total set, and then... Using the corresponding triangular facet in the neighborhood as a reference, the corresponding neighborhood triangle is found in the total set, and finally the single-scan region division is completed under the constraint conditions, as shown below: ; in, for Rank neighborhood, for The corresponding edges of the triangular facets in the neighborhood of order.
[0056] Specifically, such as Figure 4 As shown, the measurement range limitations in step S2.3 include: In measurement, to meet the limitations of the scanner's measurement range, a multi-line laser scanner emits lasers in three directions to weave a laser mesh, and uses a multi-view camera to capture the deformation information as the laser mesh sweeps across the surface to be measured, thus achieving three-dimensional topography reconstruction. The effective single scan range is defined as 60% of the center of the rectangular measurement area formed by the laser mesh emitted by the scanner.
[0057] The included angles of the vectors corresponding to all triangular patches in a single scan region Smaller than the scanner's measurement angle range : ; in, Position of the scanner camera. For the surface to be measured, For the point to be measured The normal vector of the tangent plane. It is an inverse cosine function. is the unit vector of the line connecting the camera and the point to be measured; The angle between the normal vector at the scan point and the measurement center vector of the scanner The field of view is set to a limit less than half the center vector field of view of all added triangular facets. ; in, This is the unit normal vector of the scanner's scanning direction; The optimal measurement distance for the scanner satisfies the following relationship: ; ; in, For optimal measurement distance of the scanner, For depth of field height, It represents the highest point of all triangle facet vertices within the range of a single scan. It represents the lowest point among all the vertices of the triangular facets within the range of a single scan.
[0058] Specifically, the area differences between the triangular facets are reverse-normalized, and the corresponding weight settings are calculated. The expression is as follows: ; in, Let the area of the triangular face be... To find the area of the largest triangular facet, To find the area of the smallest triangular facet, This represents the normalized area of the triangular facet.
[0059] Multiply the weight by the angle between the normal vector and the center vector, and use this as a reference for this constraint.
[0060] Specifically, step S3 includes the following steps: S3.1, Solve for the visible cones corresponding to all triangular faces in the single-scan region obtained in step S2. Move all the vertices of the visible cones to the same point and perform Boolean intersection to obtain the cone-like structure of the single-scan region, such as... Figure 5 The diagram shows the model before and after Boolean intersection, taking the base of the conical structure as an example. A family of points to be determined is obtained by uniformly sampling points.
[0061] S3.2, take the attitude direction vector corresponding to each point in the family of points to be determined, and substitute the attitude direction vector back into all visible cones to solve for the relationship between the attitude direction vector and the normal vector of each visible cone, i.e., the relationship between the attitude direction vector and the normal vector of each visible cone. The deflection angle is calculated, and the deflection angle is inversely normalized to obtain the score; where the attitude direction vector is: bottom surface The direction vector from the previous point to the vertex of the cone-like structure; S3.3, sum all the scores and sort the sums to obtain the final score table; take the attitude direction vector corresponding to the highest score in the score table as the unique attitude direction of the measurement point in this measurement area; S3.4 Repeat steps S3.1 to S3.3 to finally complete the attitude solution for all measurement points.
[0062] Specifically, in step S3.1, the solution to the visible cones corresponding to all triangular facets in the single-scan region obtained in step S2 is as follows: the centroid of all triangular facets in the single-scan region is taken as the point to be measured. , the point to be measured As the vertex of the visible cone, For the point to be measured The normal vector of the tangent plane, with The scanner is positioned along the axis of the visible cone, with the optimal measurement distance of the scanner as the height of the visible cone, thus obtaining the visible cone corresponding to each triangular facet. like Figure 6 As shown, For optimal scanning surface, Distance to the point to be measured The distance is This refers to the optimal measurement distance for the scanner. The scanner's orientation is... Direction at the point to be measured The highest accuracy is achieved through measurement, using the normal vector. With the best scanning surface Intersecting points This is the optimal measurement point. To ensure the best measurement results, the measurement must be accurate. The scanner allows for the maximum tilt angle. Scanning curved surfaces. and These are the highest and lowest planes to the point to be measured, and the distance between the two planes is... This refers to the depth of field. (For) In point measurement, it is necessary to ensure that the deviation angle of the point to be measured is located within the visible cone, and is located within... and Only by limiting the depth of field can we ensure that the accuracy of this scan measurement is within an acceptable range.
[0063] Specifically, step S4 includes the following steps: S4.1, Solve for the smallest region containing all centroids of the triangular facets in the single scan region obtained in step S2, and solve for the center point of the smallest region containing the centroids.
[0064] S4.2, Using the unique orientation direction of the scanned area obtained in step S3 as the orientation, translate the center point with the optimal measurement distance as the length to obtain the optimal measurement point in the current measurement area. The optimal measurement distance depends on the scanner's performance.
[0065] S4.3 Repeat steps S4.1 to S4.2 until the optimal measurement point location for all scanned areas is determined.
[0066] Specifically, step S5 is as follows: Based on the optimal measurement point Establish a local coordinate system for the optimal measurement points in each scanned area, such as... Figure 7 As shown, along The Z-axis is established along the orientation direction, the Y-axis is established in the opposite direction along the robot base mounting, and the X-axis follows a right-handed coordinate system. Using the shortest overall path as the objective function, basic constraints are set such that each optimal measurement point is visited exactly once, meaning each optimal measurement point is both visited once and left once. Conditional constraints are also set to ensure that the order of the selected optimal measurement points cannot be reversed. The industrial robot scanning measurement path is then solved, expressed as: ; st ; ; ; ; in, For point coordinate, For norm, The judgment value selected for this path segment. 1. To select this path segment, 0 means this path segment is not selected. The access sequence number for point A. This represents the total number of nodes. For path point labels, This is a function that takes the minimum value.
[0067] Specifically, step S6 is as follows: Based on the scanning measurement path obtained in step S5, the optimal scanning sequence of measurement points is determined, and an industrial robot execution language is generated to control the robot to reach the corresponding path points in a specific posture for scanning measurement and acquisition of freeform surface scanning data. Before measurement, by inputting the CAD model of the part to be measured, and combining the freeform surface morphology and scanner characteristics, the industrial robot adaptively sets the corresponding optimal measurement point pose to achieve the measurement of large-scale freeform surface parts. In generating the optimal measurement point pose, the scanner model remains unchanged, thus keeping parameters such as linear deviation, angular deviation, and visible cone constant, achieving parameter setting only once. Even if the part to be measured is changed subsequently, only the corresponding CAD model needs to be input to automatically generate the optimal measurement points.
[0068] This invention utilizes an STL model that decomposes the CAD model of the surface to be measured into triangular patches by setting linear and angular deviations. Then, it employs a neighborhood search method to set constraints, divides the scanning area, and determines the pose of the measurement points based on the scanner's specific visible cone and the center points of the triangular patches in the scanning area. This effectively avoids missed scans of the surface of the part being measured, improves scan completeness, and enhances the accuracy of measurement data for fine, large-scale parts. Furthermore, it establishes a local coordinate system for the measurement points, sets constraints to find the shortest path connecting all measurement points, and guides the robot to complete the scanning work, effectively improving overall work efficiency.
[0069] Of course, the above description is not intended to limit the present invention, and the present invention is not limited to the examples given above. Any changes, modifications, additions or substitutions made by those skilled in the art within the scope of the present invention should also fall within the protection scope of the present invention.
Claims
1. A method for measuring large-scale parts of CAD models based on STL triangular facets, characterized in that, Specifically, the steps include the following: S1, the surface to be measured is divided into triangular patches using linear deviation and angular deviation, and an STL triangular patch model of the surface of the part to be measured is established; S2, establish a neighborhood search method, and use a greedy algorithm to select initial triangular patches in sequence, and use the neighborhood search method to divide the single scan area; S3, based on the visual cone, solves the unique measurement point orientation of each scanned area; S4, based on each scan area and the unique measurement point orientation of each scan area, solve for the optimal measurement point position of the corresponding scan area; S5. Establish a local coordinate system based on the optimal measurement point and solve the industrial robot scanning measurement path; S6 generates the execution language for industrial robots, enabling them to automatically reach the optimal measurement point and maintain the corresponding posture to scan the free-form surface of the workpiece.
2. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S1 specifically includes the following steps: S1.1, linear deviation is the maximum deviation distance between the triangular patch and the actual curved surface, expressed as: ; in, The maximum deviation distance, This is the distance between the triangular patch and the actual curved surface. This is a function to find the maximum value. S1.2, the angular deviation is the maximum deviation angle of the change in the normal vector angle between adjacent triangular facets, expressed as: ; in, and Let be the normal vector of the adjacent triangular facet. The angle of maximum deviation It is a cosine function.
3. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S2 specifically includes the following steps: S2.1, Use a greedy algorithm to select the initial triangular facets with the area of the triangular facets as a constraint; S2.2, Design a neighborhood search method for triangular facets in STL model. Take all triangular facets and three edges as a mapping set, search for adjacent triangular facets in order and add the triangular facets to the total area of a single scan, and then delete the searched triangular facets from the mapping set. S2.3, Determine whether the measurement range limitation conditions are met; S2.4 If the condition is met, continue with step S2.2; otherwise, return the triangle facet to the mapping set and end the loop, completing the single scan region determination.
4. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 3, characterized in that, Step S2.2 specifically includes the following steps: S2.2.1 Extract all triangular faces and their corresponding three edges, and treat the triangular faces and their three edges as a mapping set; set a reference plane, and find the triangular faces with edges corresponding to the reference plane from the remaining triangular faces to obtain the first-order neighborhood of the reference plane, represented as: ; in, As the reference plane, For a first-order neighborhood, For the corresponding edge of the reference plane, For the mapping set, Let be a triangular facet in a first-order neighborhood; S2.2.2, sequentially obtain the reference planes. In the order neighborhood, remove the searched triangle faces and corresponding edges from the total set, and then... Using the corresponding triangular facet in the neighborhood as a reference, the corresponding neighborhood triangle is found in the total set, and finally the single-scan region division is completed under the constraint conditions, as shown below: ; in, for Rank neighborhood, for The corresponding edges of the triangular facets in the neighborhood of order.
5. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 3, characterized in that, The measurement range limitations in step S2.3 include: Take 60% of the center of the rectangular measurement area formed by the laser grid emitted by the scanner as the effective single scan range; The included angles of the vectors corresponding to all triangular patches in a single scan region Smaller than the scanner's measurement angle range : ; in, Position of the scanner camera. For the point to be measured, For the point to be measured The normal vector of the tangent plane. It is an inverse cosine function. is the unit vector of the line connecting the camera and the point to be measured; The angle between the normal vector at the scan point and the measurement center vector of the scanner The field of view is set to a limit less than half the center vector field of view of all added triangular facets. ; in, This is the unit normal vector of the scanner's scanning direction; The optimal measurement distance for the scanner satisfies the following relationship: ; ; in, For optimal measurement distance of the scanner, Depth of field height It represents the highest point of all triangle facet vertices within the range of a single scan. It represents the lowest point among all the vertices of the triangular facets within the range of a single scan.
6. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S3 includes the following steps: S3.1, Solve for the visible cones corresponding to all triangular faces in the single-scan region obtained in step S2. Move all visible cone vertices to the same point and perform Boolean intersection to obtain the cone-like structure of the single-scan region. Take the base of the cone-like structure. A family of points to be determined is obtained by uniformly sampling points; S3.2, take the attitude direction vector corresponding to each point in the family of points to be determined, and substitute the attitude direction vector back into all visible cones to solve for the relationship between the attitude direction vector and the coordinates of the points. The deflection angle is calculated, and the deflection angle is inversely normalized to obtain the score; where the attitude direction vector is: bottom surface The direction vector from the previous point to the vertex of the cone-like structure; S3.3, sum all the scores and sort the sums to obtain the final score table; take the attitude direction vector corresponding to the highest score in the score table as the unique attitude direction of the measurement point in this measurement area; S3.4 Repeat steps S3.1 to S3.3 to finally complete the attitude solution for all measurement points.
7. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 6, characterized in that, Step S3.1 solves for the corresponding visible cones of all triangular facets in the single-scan region obtained in step S2. Specifically, it involves taking the centroid of all triangular facets in the single-scan region as the points to be measured. , the point to be measured As the vertex of the visible cone, For the point to be measured The normal vector of the tangent plane, with The scanner is positioned along the axis of the visible cone, with the optimal measurement distance of the scanner as the height of the visible cone, thus obtaining the visible cone corresponding to each triangular facet. The optimal measurement distance for the scanner satisfies the following relationship: ; in, The optimal measurement distance for the scanner.
8. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S4 includes the following steps: S4.1, Solve for the smallest region containing all centroids of the triangular facets in the single scan region obtained in step S2, and solve for the center point of the smallest region containing the centroids. S4.2, Using the unique orientation direction of the scanned area obtained in step S3 as the orientation, translate the center point with the optimal measurement distance as the length to obtain the optimal measurement point in the current measurement area. Location; S4.3 Repeat steps S4.1 to S4.2 until the optimal measurement point location for all scanned areas is determined.
9. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S5 is as follows: Based on the optimal measurement point Establish a local coordinate system for the optimal measurement point in each scanning area, along... The Z-axis is established along the orientation direction of the robot, the Y-axis is established in the opposite direction along the robot base mounting, and the X-axis follows a right-handed coordinate system. Using the shortest overall path as the objective function, basic constraints are set such that each optimal measurement point is visited exactly once, and each point is visited once. Conditional constraints are set to ensure that the order of the selected optimal measurement points cannot be reversed. The industrial robot scanning measurement path is then solved, expressed as: ; st ; ; ; ; in, For point coordinate, For norm, The judgment value selected for this path segment.
1. To select this path segment, 0 means this path segment is not selected. The access sequence number for point A. This represents the total number of nodes. For path point labels, This is a function that takes the minimum value.
10. The method for measuring large-scale parts of CAD models based on STL triangular facets according to claim 1, characterized in that, Step S6 is as follows: Based on the scanning measurement path obtained in step S5, the optimal scanning sequence of measurement points is obtained, an industrial robot execution language is generated, and the robot is controlled to reach the corresponding path points in a specific posture to perform scanning measurements and obtain freeform surface scanning data.