Method for rapidly evaluating flatness error

By translating the measured plane data points along the Z-axis as a whole and setting an ideal reference plane, and using the direction vectors of the farthest and nearest points for iterative search, the problems of low efficiency and low accuracy in flatness error assessment in the existing technology are solved, and a fast, stable and high-precision assessment effect is achieved.

CN121829433APending Publication Date: 2026-04-10绍兴职业技术学院
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-25
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

Existing technologies for assessing flatness error are slow, inefficient, and inaccurate, and existing algorithms are complex and costly.

Method used

By translating the measured plane data points along the Z-axis as a whole, setting the ideal reference plane as passing through the origin of the coordinate system, and using the direction vector formed by the farthest point and the nearest point for iterative search, combined with adaptively adjusted search step size and normal vector update, a concise mathematical model is constructed to evaluate the flatness error.

Benefits of technology

It achieves high-precision flatness error assessment in a short time, improves computational efficiency and stability, reduces algorithm complexity, and is suitable for scenarios with high real-time requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121829433A_ABST
    Figure CN121829433A_ABST
Patent Text Reader

Abstract

The invention relates to a method for quickly evaluating a flatness error, which comprises the following steps of: performing integral translation on discrete data points of a measured plane based on a minimum region criterion, constructing a standardized flatness mathematical model, and searching a unit normal vector of an ideal reference surface to realize quick calculation of the flatness error. According to the method, an original measurement point is moved forwards by a preset distance along a Z axis, so that Z coordinates of all data points are positive, and the influence of coordinate positions on an evaluation result is eliminated; then assuming that an ideal reference surface passes through an original point, establishing a reference surface equation and a unit normal vector thereof, and calculating a projection distance from each point to the reference surface; constructing an objective function through the maximum projection distance and the minimum projection distance, and updating a reference surface normal vector by adopting an iteration mode to obtain an ideal reference surface meeting a minimum region criterion; and outputting the minimum distance difference between the inner and outer parallel surfaces as a flatness error. The method is clear in structure, easy to code, high in implementation speed and capable of obtaining a high-precision flatness evaluation result in a short time.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of measurement tool technology, and more specifically, to the field of a method for rapidly assessing flatness error, and in particular to a method for rapidly assessing flatness error. Background Technology

[0002] A plane is a fundamental geometric element of mechanical parts and is frequently used as a benchmark for part machining, inspection, and use. Flatness error is a crucial parameter for evaluating parts, directly impacting the quality of parts and products, and its research has significant engineering implications. Currently, flatness error assessment mainly relies on search algorithms that solve for flatness using feature points to construct ideal geometric elements, such as the convex hull method, computational geometry method, incremental algorithm, particle swarm optimization, and artificial bee colony optimization. While these methods have some practical value, they are generally quite complex and not easily applied in real-world scenarios.

[0003] Existing simple geometric search methods are fast, but require many iterations, resulting in low evaluation efficiency and low accuracy. Other biomimetic intelligent optimization algorithms offer high accuracy, but their evaluation processes are complex, computationally expensive, and inefficient. Summary of the Invention

[0004] To address the aforementioned technical problems, this application provides a method for rapidly assessing flatness error.

[0005] This application provides a method for rapidly evaluating flatness error, which employs the following technical solution: A method for quickly assessing flatness error includes the following steps: Step 1: Obtain the three-dimensional coordinates of multiple discrete data points on the plane being measured; Step 2: Shift all data points along the positive Z-axis by a preset distance L, so that the coordinates of the shifted data points satisfy the following conditions; Step 3: Assume the ideal reference plane passes through the origin of the coordinate system, and its plane equation is: And let the unit normal vector of the reference plane be In the formula, a and b are the coefficients of the datum plane equation, and n is the unit normal vector of the datum plane; Step 4: Based on the translated data points, calculate the distance from each point to the reference plane; Step 5: Determine the maximum and minimum distances to the reference plane for all data points; Step 6: Based on the function, with the goal of satisfying the minimum region criterion, obtain the ideal reference surface that minimizes flatness through iterative search of the unit normal vector; Step 7: Output the distance difference corresponding to the ideal reference surface after the search as the flatness error.

[0006] By adopting the above technical solution, the influence of the coordinate origin position on the flatness calculation is eliminated by translating the original data points along the Z-axis, making the flatness evaluation model more standardized and stable. Secondly, by setting the ideal datum plane to pass through the origin and using a unified form of plane equation, the mathematical description of the flatness error is made more concise. The minimum region criterion objective function is constructed based on the projection distance from the point to the datum plane, and the error is quantified by the difference between the maximum and minimum distances, giving the evaluation results a clear geometric meaning. By iteratively searching the unit normal vector of the datum plane based on the direction information of the farthest and nearest points, the algorithm can quickly converge to the optimal datum plane direction, which not only reduces the algorithm complexity but also improves the search efficiency. Finally, the flatness error is calculated by the minimum distance difference between the two parallel planes inside and outside the ideal datum plane, realizing the ability to output high-precision evaluation results in a short time.

[0007] Optionally, the translation distance L in step two is determined based on the minimum Z value of the plane data points, so that all translated Z-axis coordinates are positive.

[0008] By adopting the above technical solutions, the flatness assessment model can operate in a unified and standardized coordinate space, avoiding the instability of distance calculation caused by differences in coordinate signs, improving the reliability of objective function construction and the convergence of the search process, thereby further improving the accuracy and computational efficiency of flatness error assessment.

[0009] Optionally, in step four, the distance from the point to the reference plane is calculated as the projection length of the spatial vector of the measured point relative to the origin onto the unit normal vector direction of the reference plane.

[0010] By adopting the above technical solution, the distance from a point to the reference surface is calculated by the projection length of the spatial vector on the unit normal vector direction of the reference surface, which makes the distance calculation process have a clear geometric meaning, avoids the complex algebraic derivation in traditional algorithms, and improves the stability and consistency of the calculation. This method allows the distance from each measurement point to the reference surface to be directly obtained by vector operation, quickly iterates and updates the objective function, and improves the calculation efficiency and overall accuracy of the flatness evaluation model.

[0011] Optionally, in step six, the search direction for the ideal reference plane is constructed from the direction vector l defined by the farthest point and the nearest point.

[0012] By adopting the above technical solution, the direction vector l defined by the farthest point and the nearest point is used as the search direction of the ideal reference surface. This allows the update of the normal vector to directly reflect the true deviation trend of the current data distribution, avoiding the inefficiency caused by random search or complex optimization processes. It also enables the iterative process to quickly adjust the attitude of the reference surface along the direction of maximum error convergence, thereby accelerating the convergence speed of the objective function, improving the accuracy and efficiency of the ideal reference surface search, and significantly enhancing the overall computational performance of flatness error assessment.

[0013] Optionally, the direction vector l is determined by the following formula, where P l and P c These represent the data point farthest from the reference plane and the data point closest to it in space, respectively.

[0014] By adopting the above technical solution, the direction vector l constructed between the farthest and nearest points to the reference surface is used to obtain the most representative spatial direction reference during the reference surface search and fitting process. This enables the algorithm to automatically adapt to the overall data distribution trend for optimized search, improve the directional accuracy and convergence efficiency of ideal reference surface finding, effectively avoid the interference of local noise points on the search direction, achieve a more stable and robust reference surface determination effect, and improve the overall measurement and calibration accuracy.

[0015] Optionally, the search step size λ can be adaptively adjusted according to the degree of convergence of the search iterations to ensure both search accuracy and convergence speed.

[0016] By adopting the above technical solution, the search step size λ is adaptively adjusted according to the convergence degree of the search iteration, enabling the algorithm to maintain a large step size in the early stage of convergence to quickly approach the optimal solution, and automatically reduce the step size when approaching convergence to improve the search resolution and accuracy. The adaptive mechanism effectively avoids problems such as oscillation, overshoot or slow convergence caused by fixed step size, realizes dynamic optimization of the search process, and thus improves the stability, efficiency and final accuracy of the reference surface fitting.

[0017] Optionally, a normalization step can be added during the update process of the unit normal vector n to ensure that the updated vector always maintains a unit length.

[0018] By adopting the above technical solution, a normalization step is added to the update process of the unit normal vector n, ensuring that the updated normal vector always maintains a unit length. This avoids errors in the judgment of the reference surface direction caused by the vector length offset accumulated from multiple iterations, improves the numerical stability of the normal vector update process, and enables the algorithm to maintain directional consistency and computational reliability in long iteration sequences. This also improves the accuracy of the reference surface fitting results and the overall robustness of the algorithm.

[0019] Optionally, the iteration may terminate when the following stopping condition is met during the search: The flatness error f decreases as the number of iterations increases. Once the trend reaches an inflection point, i.e. the calculated flatness error value increases, the calculation stops.

[0020] By adopting the above technical solution, the trend of flatness error f is used as the basis for terminating the iteration during the search process. When the error reaches an inflection point after continuous decrease and begins to increase, the calculation is stopped immediately. This achieves automatic identification and rapid convergence of the neighborhood of the optimal solution, enabling the algorithm to lock the minimum flatness error in the shortest time and improve the stability, efficiency and overall calculation accuracy of the evaluation process.

[0021] Optionally, the search for the ideal reference surface uses gradient-based direction updates, which makes the evaluation algorithm have high computational speed and simple coding implementation.

[0022] By adopting the above technical solution, gradient-based direction updates are introduced during the search process of the ideal reference surface, enabling the normal vector or search direction to be rapidly iteratively adjusted based on the error gradient, which significantly improves the computation speed of the algorithm.

[0023] In summary, this application includes at least one of the following beneficial technical effects: 1. By translating the data points along the Z-axis as a whole and unifying the form of the reference surface equation, the flatness evaluation model can operate in a standardized coordinate space, thereby improving the model's stability and versatility.

[0024] 2. By using a distance calculation method based on spatial vector projection, the distance calculation becomes more geometrically meaningful, improving the simplicity, consistency, and numerical stability of the calculation process.

[0025] 3. By using the direction vector formed by the farthest point and the nearest point to search the reference plane, the algorithm automatically adapts to the data distribution characteristics, significantly improving the accuracy of the search direction and the speed of iterative convergence.

[0026] 4. By adaptively adjusting the search step size λ, a balance between fast convergence and high-precision search is achieved, avoiding oscillations and inefficient iterations caused by a fixed step size.

[0027] 5. By normalizing the normal vector during updates, we ensure that the normal vector always maintains a unit length, thereby improving the robustness and fitting accuracy during the iteration process.

[0028] 6. By setting iteration stopping criteria, intelligent control of the iteration process can be achieved, avoiding invalid calculations and ensuring convergence quality.

[0029] 7. By adopting gradient-based direction updates, the algorithm implementation complexity is reduced and the overall computational efficiency is improved, making this method suitable for scenarios with high real-time requirements. Attached Figure Description

[0030] Figure 1 This refers to the region between two parallel planes in the embodiments of this application.

[0031] Figure 2 The flatness error of the measured plane profile is such that changing the position of the origin of the coordinate system in the embodiments of this application does not affect the flatness error of the measured plane profile.

[0032] Figure 3 This is the normal vector of the search reference plane in the embodiments of this application.

[0033] Figure 4 This is a route diagram of an embodiment of this application. Detailed Implementation

[0034] The following is in conjunction with the appendix Figure 1-4 This application will be described in further detail.

[0035] This application discloses a method for rapidly assessing flatness error. Flatness error refers to the maximum variation of the measured actual planar contour feature relative to its ideal reference plane. It should meet the minimum area assessment criterion, where the area between parallel planes contains all data points, and the perpendicular distance between the two parallel planes—the target value—is minimized. In the flatness error assessment process, once the ideal reference plane and its normal vector are obtained, the flatness error can be calculated. The search speed for the ideal reference plane and its normal vector determines the computational efficiency of the assessment method.

[0036] Reference Figure 1 Let the coordinates of the measured plane data points be... , … … To facilitate the construction of a mathematical model for flatness assessment, the measured plane data is shifted by an L value along the positive Z-axis. In the formula: , These are the Z-axis coordinates of the measured plane contour points before and after translation. .

[0037] Reference Figure 2 , Figure 2 This is a schematic diagram illustrating the flatness error of the measured plane profile without affecting the position of the coordinate system origin. To simplify the mathematical model for flatness assessment, assume the ideal datum plane passes through the origin O, and the plane equation and unit normal vector of the datum plane are: , , In the formula, a and b are the coefficients of the datum plane equation, and n is the unit normal vector of the datum plane.

[0038] Measured point P i The distance to the datum plane is the length of the projection of the spatial vector between the origin and that point onto the unit normal vector of the datum plane. , In the formula: From the origin O to point P i spatial vectors, Let d be the maximum distance from the measured point to the reference plane. max The minimum distance is d min , To minimize f, we need to obtain the ideal datum surface and its unit normal vector n. A mathematical model is established to search for the ideal datum surface normal vector and to evaluate the flatness error f. min, .

[0039] Reference Figure 3 To minimize f, based on the current unit normal vector n of the reference plane and the point P farthest from the reference plane... l And the nearest point P c Construct the direction of movement l of the reference plane normal vector, so that d max Take the minimum value and d min Take the maximum value; Update the reference plane normal vector The process is as follows: In the formula: λ is the direction vector; λ is the search step size.

[0040] The technical solution of this application is, with reference to Figure 4 In flatness calculation, we only need to search for the ideal reference plane, so the calculation is easy to code and can obtain sufficient accuracy in a short time. Detailed calculation process.

[0041] The key steps in the evaluation process for this application are as follows: The position of the measured contour data on the Z-axis is shifted by a value L, and the flatness error f remains unchanged after the shift.

[0042] 2) The approximate reference surface of the plane profile and its unit normal vector n are obtained by using the three-point method.

[0043] 3) Obtain the distance d from each point to the reference plane. i Filter the points farthest from and closest to the current reference plane, and calculate the flatness error f.

[0044] 4) Obtain the search direction vector l of the unit normal vector of the reference plane.

[0045] 5) Based on the original unit normal vector n of the datum plane, and combined with a reasonable search step size λ and direction vector l, update the ideal datum plane normal vector n. ’ .

[0046] 6) Repeat steps 3-5. The flatness error f decreases as the number of iterations increases. Once the trend reaches an inflection point, i.e., the calculated flatness error increases, stop the calculation.

[0047] 7) The evaluation is completed, and the front flatness error - minimum f - is output as the final evaluation result.

[0048] The beneficial effect of the technical solution of this application is that it can effectively obtain sufficiently accurate results in a short time and successfully solve the flatness problem.

[0049] The implementation principle of the method for rapidly evaluating flatness error in this application embodiment is as follows: By translating the entire measured plane data along the positive Z-axis, all points are placed in a unified coordinate space, eliminating the interference caused by the difference in the original coordinate system position on the flatness calculation; on this basis, the ideal reference plane is set to pass through the coordinate origin, which simplifies the flatness mathematical model and facilitates subsequent calculation and derivation. The projection distance from the point to the reference plane is used as the error metric, and the distance difference between the farthest point and the nearest point is used as the objective function. The unit normal vector of the reference plane is iteratively optimized according to the minimum region criterion. By constructing the direction vector l derived from the farthest point and the nearest point, the normal vector of the reference plane is always updated along the error convergence direction. Combined with an appropriate search step size λ, the direction of the ideal reference plane is rapidly approximated. As the iteration proceeds, the flatness error gradually decreases. When the change trend shows a reverse growth or a predetermined stopping condition is met, it is considered that the optimal solution has been reached and the search is terminated. Finally, the minimum distance difference f is output. min Flatness error can be obtained, realizing a flatness error evaluation process that is highly efficient, highly stable, and easy to code.

[0050] The above are all preferred embodiments of this application and are not intended to limit the scope of protection of this application. Therefore, all equivalent changes made in accordance with the structure, shape and principle of this application should be covered within the scope of protection of this application.

Claims

1. A method for rapidly assessing flatness error, characterized in that: Includes the following steps: Step 1: Obtain the three-dimensional coordinates of multiple discrete data points on the plane being measured; Step 2: Shift all data points along the positive Z-axis by a preset distance L, so that the coordinates of the shifted data points satisfy the following conditions; Step 3: Assume the ideal reference plane passes through the origin of the coordinate system, and its plane equation is: And let the unit normal vector of the reference plane be In the formula, a and b are the coefficients of the datum plane equation, and n is the unit normal vector of the datum plane; Step 4: Based on the translated data points, calculate the distance from each point to the reference plane; Step 5: Determine the maximum and minimum distances to the reference plane for all data points; Step 6: Based on the function, with the goal of satisfying the minimum region criterion, obtain the ideal reference surface that minimizes flatness through iterative search of the unit normal vector; Step 7: Output the distance difference corresponding to the ideal reference surface after the search as the flatness error.

2. The method according to claim 1, characterized in that: In step two, the translation distance L is determined based on the minimum Z value of the plane data points, so that all translated Z-axis coordinates are positive.

3. The method according to claim 1, characterized in that: In step four, the distance from the point to the reference plane is calculated as the projection length of the spatial vector of the measured point relative to the origin onto the unit normal vector direction of the reference plane.

4. The method according to claim 1, characterized in that: In step six, the search direction of the ideal reference plane is constructed by the direction vector l defined by the farthest point and the nearest point.

5. The method according to claim 4, characterized in that: The direction vector l is determined by the following formula: These are the data points farthest from the reference plane and the closest data points in space.

6. The method according to claim 1, characterized in that: The search step size λ is adaptively adjusted according to the degree of convergence of the search iterations to ensure both search accuracy and convergence speed.

7. The method according to claim 1, characterized in that: A normalization step is added during the update process of the unit normal vector n to ensure that the updated vector always maintains a unit length.

8. The method according to claim 1, characterized in that: The iteration terminates when the following stopping condition is met during the search process: The flatness error f decreases as the number of iterations increases. Once the trend reaches an inflection point, i.e. the calculated flatness error value increases, the calculation stops.

9. The method according to claim 1, characterized in that, The search for the ideal reference surface uses gradient-based direction updates, which makes the evaluation algorithm have high computational speed and simple coding implementation.