Three-dimensional arc line measuring method and system
Through the three-dimensional arc measurement method, using three-point and multi-point fitting steps, combined with the first and last point fixation method and root mean square RMS evaluation, the problem of inconsistency of control points in arc curve measurement in three-dimensional space is solved, and measurement results with higher accuracy and continuity are achieved.
Patent Information
- Application Number
- CN202510844286.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-23
- Publication Date
- 2025-09-23
AI Technical Summary
The existing method for measuring circular arc curves in three-dimensional space has inconsistencies in control points, which leads to deviations in measurement results and affects the continuity and accuracy of engineering design and construction.
A three-dimensional arc measurement method is provided. By judging the number of target measurement points and selecting a suitable fitting strategy, three-point fitting and multi-point fitting steps are adopted. The first and last point fixed method is used to fit the optimal circle equation. Combined with the root mean square (RMS) evaluation index, the center and radius of the circle are calculated. Plane basis vectors are selected to determine the arc sweep direction, and the three-dimensional coordinates of the interpolation point are calculated by interpolation.
It improves the accuracy and reliability of 3D arc measurement, ensures the accuracy and continuity of measurement results, and is suitable for complex engineering scenarios.
Smart Images

Figure CN120685062A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of three-dimensional surveying and mapping technology, and in particular to a three-dimensional arc line measurement method and system. Background Art
[0002] In the field of surveying and mapping, the measurement and fitting of circular curves is an essential component of numerous engineering projects and scientific research. Accurate circular line measurement is crucial for the design and construction of building structures, the manufacturing and testing of mechanical parts, and the acquisition and analysis of geospatial information.
[0003] Currently, most research and practice in circular arc measurement methods focuses on fitting two-dimensional circular arcs. After years of development, two-dimensional circular arc fitting technology has developed a relatively mature and comprehensive theoretical system and algorithm that can meet many needs for measuring simple geometric shapes within a two-dimensional plane. However, with the rapid development of modern science and technology and the continuous expansion of engineering applications, circular arcs in many real-world scenarios are no longer located within a simple two-dimensional plane, but rather exist in complex three-dimensional space. For example, in applications such as the arched structures of large bridges, curved surface components of aerospace vehicles, and the simulation of complex geological structures, the precise measurement and fitting of three-dimensional circular arcs has become an urgent problem to be solved.
[0004] Although some methods involving three-dimensional arc fitting have been proposed, these methods generally have a significant problem, that is, the control points used for fitting are generally not on the fitted arc curve. This situation will bring many adverse effects in practical applications. From the perspective of measurement accuracy, the inconsistency between the control points and the fitted arc will cause the measurement results to deviate from the actual situation and fail to accurately reflect the true three-dimensional arc shape, thus affecting subsequent analysis and decision-making based on the measurement data. From the perspective of engineering applications, the discontinuity of the lines before and after measurement will destroy the integrity and continuity of the entire structure, bringing great difficulties to engineering design and construction. For example, in building structure design, discontinuous lines may cause uneven stress on the structure and increase safety hazards; in mechanical parts manufacturing, inaccurate arc fitting will affect the assembly accuracy and performance of the parts. Summary of the Invention
[0005] The purpose of the present invention is to provide a three-dimensional arc line measurement method and system, which can improve the accuracy and reliability of three-dimensional arc measurement.
[0006] To achieve the above objectives, in a first aspect, the present invention provides a three-dimensional arc measurement method, comprising: Determine the number n of target measurement points obtained. If n < 3, end the measurement method; if n = 3, enter the three-point fitting step; if n > 3, enter the multi-point fitting step; The three-point fitting step includes detecting whether the three points are collinear. If so, the measurement method is terminated. Otherwise, the center and radius of the circle are calculated to obtain the three-dimensional coordinates of the center and radius. The multi-point fitting step includes fitting the equation of the best circle by the first and last point fixed method to obtain the three-dimensional coordinates of the circle center and the radius; Calculate the start and end angles and the arc sweep direction, including selecting the plane basis vectors, calculating the vector from the center of the circle to the point and projecting it, and determining the arc sweep direction; Calculate the interpolated angle value and the three-dimensional coordinates of the arc point, including determining the total angle of the arc and the number of interpolated points, calculating the plane normal vector and the basis vectors in the interpolated plane, and calculating the three-dimensional coordinates of the point on the circle corresponding to the interpolated angle based on the parametric equation of the point on the circle.
[0007] Beneficial effects of the basic solution: This technical solution automatically selects an appropriate fitting strategy based on the number of target measurement points acquired. In three-point fitting, by detecting whether the three points are collinear, invalid or erroneous data input is effectively avoided, ensuring that calculations are performed only when a circular arc is formed, thereby improving the reliability of the results. In multi-point fitting, a fixed-point method is used to fit the optimal circle equation. While prioritizing smooth connections between the beginning and the end, it reduces the impact of measurement errors and noise, improving the calculation accuracy of the center position and radius. This is particularly suitable for actual measurement scenarios with a large number of data points or a certain amount of noise.
[0008] In three-point fitting, by checking whether the three points are collinear, invalid or erroneous data input is effectively avoided, ensuring that calculations are performed only when an arc is formed, thereby improving the reliability of the results. If the three points are not collinear, the center and radius can be directly calculated, quickly obtaining the basic parameters of the arc and achieving effective measurement even with small amounts of data.
[0009] The equation of the optimal circle is obtained by fixing the first and last points, which solves the problem of discontinuity and unevenness of the three-dimensional arc curve fitted by the traditional least squares method. It makes full use of the redundant measurement point information and uses the root mean square (RMS) as the evaluation index to calculate and select the circle equation with the minimum RMS as the fitting result, thereby obtaining more accurate three-dimensional coordinates of the circle center and radius, and improving the measurement accuracy and reliability.
[0010] By selecting plane basis vectors, calculating the vector from the center of the circle to the point and projecting it to determine the direction of the arc sweep, the starting and ending angles of the arc and the sweep direction can be accurately determined, providing accurate direction information for subsequent interpolation calculations.
[0011] After determining the total angle of the arc and the number of interpolated points, the plane normal vector and the basis vectors in the interpolated plane are calculated, and then the three-dimensional coordinates of the point on the circle corresponding to the interpolated angle are calculated based on the parametric equation of the point on the circle. This technical solution can accurately calculate the required three-dimensional coordinates of the interpolated points to meet the measurement needs of more points on the arc line.
[0012] As an implementable preferred solution, the step of detecting whether the three points are collinear includes: The three points passed in are 、 and
[0013] Calculating vectors and ; Compute the cross product of two vectors: ,get
[0014] in,
[0015] Compute the cross product modulo squared , the formula is as follows:
[0016] If the square of the cross product modulus is less than the preset tolerance parameter, the three points are considered collinear.
[0017] As an implementable preferred solution, the steps of calculating the three-dimensional coordinates of the circle center and the radius include: Use vector cross product to get the normal vector of the plane , and to the plane equation Substitution Get the constant value : ; Build 、 The equation of the perpendicular bisector between the two points is as follows:
[0018] get:
[0019] 、 The coefficients of the perpendicular bisector equation are:
[0020] The three equations combined form a linear equation system:
[0021] Solve the three-dimensional coordinates of the center of the circle formed by three points ; Calculate the distance between two points using the formula 、 and arrive Distance of points:
[0022] in, for point To the center distance of the points; Find the average distance from the three points to the center of the circle as the radius:
[0023] in, is the radius.
[0024] As an implementable preferred solution, in the multi-point fitting step, the center and radius of the circle are calculated by cyclically using the starting point, the ending point, and any intermediate point, and the root mean square value is calculated as follows:
[0025] in, is the distance from the point to the center of the circle, It is the root mean square value for judging whether it is the best space circle.
[0026] choose The center and radius corresponding to the minimum value are the best fitting spatial circle.
[0027] As an implementable preferred solution, the steps of calculating the start and end angles and the arc sweep direction include: Select the plane basis vectors and determine the plane where the space circle is located by analyzing the distribution characteristics of all point coordinates; Calculate the vector from the center of the circle to the point and project it onto the plane coordinate system, and calculate the polar angle of the vector; The direction of the arc sweep is determined based on the magnitude of the polar angles.
[0028] As an implementable preferred solution, plane basis vectors are selected and the plane where the space circle is located is determined by analyzing the distribution characteristics of all point coordinates, including: Calculate the sum of the absolute values of the X, Y, and Z coordinates of all points:
[0029] in, 、 and The sum of the absolute values of the X, Y, and Z coordinates of all points respectively; Select the coordinate axis with the smallest absolute value as the normal axis. Minimum, then the basis vector is and ;like Minimum, then the basis vector is and ;like Minimum, then the basis vector is and .
[0030] As an implementable preferred solution, the vector from the center of the circle to the point is calculated and projected onto a plane coordinate system, and the polar angle of the vector is calculated, including: Calculate the center of the circle to each point Vector: , And normalize: , Using basis vectors 、 ,Will Projecting a vector onto a plane coordinate system:
[0031] Calculating vectors Polar angle: , record the angle value of each point ; The direction of the arc sweep depends on the starting point And the second point The size relationship is judged, if , then it is counterclockwise, if , it is clockwise.
[0032] As an implementable preferred solution, the steps of calculating the interpolation angle value and the three-dimensional coordinates of the arc point include: Calculate the total angle of the arc: ; in, is the starting angle, is the ending angle; The number of interpolation points is , the interpolation point step size is , then the angle represented by each interpolation point is: .
[0033] Calculate the plane normal vector and interpolate the in-plane basis vectors; According to the parametric equation of the point on the circle, calculate the three-dimensional coordinates of the point on the circle corresponding to the interpolation angle. The equation is as follows:
[0034] in, is the center of the circle; is the radius; is the angle represented by each interpolated point; are the coordinates of the interpolation point.
[0035] As an implementable preferred solution, the steps of calculating the plane normal vector and interpolating the plane basis vectors include: The plane normal vector is , by calculating the normal vector and a reference vector The cross product of ; judge Is it a zero vector? If so, you need to recalculate the normal vector and another reference vector The cross product of ; If not, then according to the normal vector and vector Cross product to get vector Unitization 、 Vectors, as two basis vectors in the plane where the arc lies:
[0036] According to the parametric equation of the point on the circle, calculate the three-dimensional coordinates of the point on the circle corresponding to the interpolation angle. The equation is as follows:
[0037] in, is the center of the circle, is the radius, is the angle represented by each interpolation point, are the coordinates of the interpolation point.
[0038] In a second aspect, this embodiment further provides a three-dimensional arc line measurement system, which utilizes the above-mentioned three-dimensional arc line measurement method. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] Figure 1 Schematic diagram of the measurement of the traditional least squares method.
[0040] Figure 2 This is a measurement diagram of the head and tail point fixing method.
[0041] Figure 3 FIG. 1 is a schematic diagram showing the structure of an electronic device provided by an embodiment of the present invention.
[0042] Reference numerals: electronic device 500 , processor 501 , communication interface 502 , memory 503 , bus 504 . DETAILED DESCRIPTION
[0043] In order to make the technical solution and advantages of the present application clearer, the technical solution of the present invention will be further described in detail below with reference to the accompanying drawings. It will be understood that the specific embodiments described herein are only partial embodiments of the present invention, which are only used to explain the present application, rather than to limit the present application. It should be noted that the technical features or combinations of technical features described in the following embodiments should not be considered to be isolated, and they can be combined with each other to achieve better technical effects. The same reference numerals appearing in the drawings of the following embodiments represent the same features or components, which can be applied to different embodiments.
[0044] In addition, unless otherwise defined, technical or scientific terms used in the description of the present invention should have the common meanings understood by those skilled in the art in the art to which the present invention belongs.
[0045] The present invention will be further described in detail below with reference to the accompanying drawings: In this embodiment, a 3D circular arc measurement system includes a data acquisition device capable of acquiring 3D coordinate points in space and a data processing device, which communicate via a wireless connection such as Bluetooth. The data acquisition device can be an inertial navigation system, RTK, or total station, and the data processing device can be a mobile smart device such as a mobile phone.
[0046] Inertial navigation devices measure an object's acceleration and angular velocity using internal sensors such as accelerometers and gyroscopes. During measurement, the device is attached to a measurement vehicle (such as a vehicle or drone). As the vehicle moves, the accelerometers continuously measure the vehicle's acceleration along the three axes (X, Y, and Z), while the gyroscopes measure the vehicle's angular velocity around those three axes.
[0047] According to Newton's second law and the law of angular momentum, the position, velocity, and attitude of a vehicle in space can be determined by integrating acceleration and angular velocity. Specifically, the first-order integration of acceleration with respect to time yields velocity, while the first-order integration of velocity with respect to time yields position. The first-order integration of angular velocity with respect to time yields the angular change, which in turn determines the vehicle's attitude.
[0048] The inertial navigation device converts these position and attitude information into three-dimensional coordinates (X, Y, Z) and sends the coordinate data to the data processing device via wireless communication methods such as Bluetooth.
[0049] RTK (Real-Time Kinematic Differential Positioning) equipment is based on global navigation satellite systems (GNSS), such as GPS and BeiDou. It consists of a base station and a rover. The base station is placed at a reference point with precisely known coordinates. It receives and processes satellite signals, calculates distance corrections from the base station to the satellites, and transmits these corrections to the rover via wireless communication methods (such as radio or the Internet).
[0050] The rover simultaneously receives satellite signals and corrections from the base station, modifying the satellite signals it receives to improve positioning accuracy. The rover continuously moves during the measurement process, acquiring its own three-dimensional coordinates (X, Y, Z) in space in real time and transmitting these coordinates to a data processing device via wireless communication methods such as Bluetooth.
[0051] A total station is a high-tech measuring instrument that integrates optics, mechanics, and electronics. It uses a telescope to aim at a target point and uses its internal angle and distance measurement systems to measure the horizontal angle, vertical angle, and slant distance between the target point and the total station.
[0052] Based on the principle of triangulation, the total station converts horizontal angles, vertical angles, and slope distances into three-dimensional coordinates (X, Y, Z). The total station sends the measured three-dimensional coordinates (X, Y, Z) to a data processing device via wireless communication methods such as Bluetooth.
[0053] The data processing device (mobile phone) receives the 3D coordinate data sent by the data acquisition device via Bluetooth. In the Bluetooth settings of the mobile phone, it has been pre-paired with the data acquisition device to ensure the stability and reliability of data transmission.
[0054] After receiving the coordinate data, the mobile application first parses and formats the data, converting the received raw binary data into readable three-dimensional coordinate values (X, Y, Z).
[0055] The app then displays the received 3D coordinates in real time on the interface, allowing the operator to visually view the location of the measured points. Simultaneously, the app stores the received coordinate data to the phone's internal memory or an external storage card for subsequent data processing and analysis. The stored data can be formatted as a common text file (such as CSV), with each line recording the 3D coordinates of a measured point, facilitating data import and export.
[0056] The data processing device executes the three-dimensional arc line measurement method to achieve the fitting and display of the three-dimensional arc curve.
[0057] The present disclosure provides a three-dimensional arc measurement method, including: Step S100: Determine the number n of target measurement points obtained. The number n of measurement points is read from the stored coordinate data.
[0058] If n is less than 3, it means that the number of measurement points is insufficient and arc fitting cannot be performed, and the process directly goes to step S400 to end the method. If n=3, go to step s200; If n>3, go to step s300.
[0059] Step S200, when the number of points is equal to 3, includes: Step S201, based on the three points input 、 and , check whether the three points are collinear.
[0060] Calculating vectors and .
[0061] Compute the cross product of two vectors: ,get
[0062] in,
[0063] Compute the cross product modulo squared , the formula is as follows:
[0064] like ( The tolerance parameter set for detecting the collinearity of three points can be set according to the actual situation), then it means that the three points in space are collinear, and the process goes to step S400; otherwise, it means that the three points are not collinear, and the process continues to the next step of calculation.
[0065] Step S202, calculating the center and radius of the circle, includes: Use vector cross product to get the normal vector of the plane , and to the plane equation Bring in Get the constant value ,Right now .
[0066] Build 、 The equation of the perpendicular bisector between the two circles ensures that the distance from the center of the circle to each point is equal, then:
[0067] in 、 and is the coordinate value of the center of the circle, simplifying it to get: ,Right now:
[0068] The same logic applies 、 The coefficients of the perpendicular bisector equation are:
[0069] The three equations combined form a linear equation system:
[0070] The three-dimensional coordinates of the center of the circle can be solved Then, use the distance formula between two points to calculate 、 and arrive Distance of points:
[0071] in, for point To the center The distance of the point.
[0072] And find the average distance from the three points to the center of the circle as the radius:
[0073] Get the three-dimensional coordinates of the center of the circle and radius , enter step S500.
[0074] Step S300, when the number of points is greater than 3, the three non-collinear points can uniquely determine the equation of the circle so that all three points are on the circle. When there are more than 3 points, the traditional method uses the fixed method of the first and last points to fit the equation of the best circle, ensuring that the sum of the squares of the differences between the distances of all fitting points to the center of the circle and the radius is minimized, but it cannot guarantee that all points are on the circle. Figure 1 In this embodiment, the first and last points are set as 、 , as a constraint condition, and use the method of determining the circle with 3 non-collinear points to obtain the equation of the circle, so as to ensure that the first and last points are on the circle, and the front and back and straight line segments are connected smoothly, refer to Figure 2 , compared to Figure 1 The arc joints obtained are smoother. The method specifically includes: Set incoming 、 、 There are n points in total, so determine the starting point for , end point for .
[0075] Recycling 、 and ,in , calculate the center of the circle according to step S200 and radius To fully utilize the effective information of n control points, the root mean square value (RMS) is used as the evaluation criterion to screen the optimal center and radius. First, the distance of all control points from the center of the circle is calculated and subtracted from the radius. Then, the sum of the squares of all the differences is calculated, and finally the square root is taken. The formula is as follows:
[0076] in, is the distance from the point to the center of the circle, It is the root mean square value for judging whether it is the best space circle.
[0077] choose The center and radius corresponding to the minimum value are the best fitting space circle. Get the three-dimensional coordinates of the center and radius , enter step S500.
[0078] In step S400, the circular curve cannot be fitted, and the method ends. If, in step S200 or step S300, the circular curve cannot be fitted due to some reason (such as the three points being collinear or an inability to find a suitable center and radius), the method ends immediately, and the application prompts the user that the measured point may not meet the requirements or needs to be remeasured.
[0079] Step S500, calculating the start and end angles and arc sweep direction, including Step S501: Select the plane basis vectors and determine the plane where the space circle is located by analyzing the distribution characteristics of all point coordinates. Calculate the sum of the absolute values of the X, Y, and Z coordinates of all points:
[0080] in, 、 and The sum of the absolute values of the X, Y, and Z coordinates of all points respectively.
[0081] Select the coordinate axis with the smallest absolute value as the normal axis. Minimum, then the basis vector is and ;like Minimum, then the basis vector is and ;like Minimum, then the basis vector is and .
[0082] Step S502: Calculate the vector from the center of the circle to the point and project it. For each point ,in , calculate the center of the circle to the point Vector: , And normalize: , Assume that the basis vectors are 、 ,use 、 ,Will Projecting a vector onto a plane coordinate system:
[0083] Calculating vectors Polar angle: , record the angle value of each point Then, the starting angle , end angle .
[0084] Step S503, determine the direction of the arc sweeping, the direction of the arc sweeping is based on and The size relationship is judged, if , then it is counterclockwise, if , it is clockwise.
[0085] Step S600, calculating the interpolation angle value and the three-dimensional coordinates of the arc point, includes: Step S601: The total angle of the arc is: ; In order to ensure the accuracy of the arc curve, the number of interpolation points is specified The minimum is 30.
[0086] when When , the number of interpolation points is , the interpolation point step size is , then the angle represented by each interpolation point is: .
[0087] Step S602, calculate the plane normal vector and the interpolated plane basis vectors. From step S200, we can know that: The plane equation is: , then the plane normal vector is .
[0088] By calculating the normal vector and a reference vector The cross product of . judge Is it a zero vector? If so, you need to recalculate the normal vector and another reference vector The cross product of .
[0089] If not, then the normal vector is and vector Cross product to get vector Unitization 、 Vectors, as two basis vectors in the plane where the arc lies:
[0090] According to the parametric equation of the point on the circle, the three-dimensional coordinates of the point on the circle corresponding to the interpolation angle can be calculated.
[0091]
[0092] in, is the center of the circle, is the radius, is the angle represented by each interpolation point, are the coordinates of the interpolation point.
[0093] A three-dimensional circular arc measurement system in this embodiment can execute the above-mentioned three-dimensional circular arc measurement method.
[0094] The present application also provides an electronic device 500 that utilizes the aforementioned three-dimensional arc measurement method. The device includes a memory, a processor, and a computer program stored in the memory and executable by the processor. When the processor executes the program, the steps of the aforementioned three-dimensional arc measurement method are implemented. In the present application, the processor serves as the control center of the computer method and can be a processor of a physical machine or a processor of a virtual machine.
[0095] Reference Figure 3 The electronic device 500 includes: at least one processor 501, at least one communication interface 502, at least one memory 503, and at least one bus 504. Bus 504 is used to implement communication between these components, communication interface 502 is used to communicate signaling or data with other node devices, and memory 503 stores machine-readable instructions executable by processor 501. When the electronic device 500 is running, processor 501 communicates with memory 503 via bus 504, and when the machine-readable instructions are called by processor 501, the steps of the three-dimensional circular arc measurement method described above are executed.
[0096] The present invention also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor of an electronic device, it can implement the steps of the three-dimensional arc measurement method as described above.
[0097] Those skilled in the art will understand that all or part of the process of implementing a three-dimensional circular arc measurement method can be completed by instructing related hardware through a computer program. The program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the process of each embodiment of a three-dimensional circular arc measurement method. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0098] The above contents are merely embodiments of the present invention. Common knowledge such as the known specific structures and characteristics in the scheme is not described in detail here. A person of ordinary skill in the art is aware of all common technical knowledge in the technical field to which the invention belongs before the filing date or priority date, is able to obtain all existing technologies in the field, and has the ability to apply conventional experimental means before that date. A person of ordinary skill in the art can, under the guidance of this application, improve and implement this scheme in combination with his or her own abilities. Some typical known structures or known methods should not become an obstacle for a person of ordinary skill in the art to implement this application. It should be pointed out that for a person of ordinary skill in the art, several variations and improvements can be made without departing from the structure of the present invention, which should also be regarded as the scope of protection of the present invention, and these will not affect the effect of the implementation of the present invention and the practicality of the patent. The scope of protection claimed in this application shall be based on the content of its claims, and the specific implementation methods and other records in the specification can be used to interpret the content of the claims.
Claims
1. A three-dimensional arc measurement method, characterized in that: include: Determine the number n of target measurement points obtained. If n is less than 3, terminate the measurement method. If n=3, then enter the three-point fitting step; if n>3, then enter the multi-point fitting step; The three-point fitting step includes detecting whether the three points are collinear. If so, the measurement method is terminated. Otherwise, the three-dimensional coordinates of the circle center and the radius are calculated. The multi-point fitting step includes fitting the equation of the best circle by the first and last point fixed method to obtain the three-dimensional coordinates of the circle center and the radius; Calculate the start and end angles and the arc sweep direction, including selecting the plane basis vectors, calculating the vector from the center of the circle to the point and projecting it, and determining the arc sweep direction; Calculate the interpolated angle value and the three-dimensional coordinates of the arc point, including determining the total angle of the arc and the number of interpolated points, calculating the plane normal vector and the basis vectors in the interpolated plane, and calculating the three-dimensional coordinates of the point on the circle corresponding to the interpolated angle based on the parametric equation of the point on the circle.
2. A three-dimensional arc measurement method according to claim 1, characterized in that: The steps to detect whether three points are collinear include: The three points passed in are 、 and Calculating vectors and ; Compute the cross product of two vectors: ,get in, Compute the cross product modulo squared , the formula is as follows: If the square of the cross product modulus is less than the preset tolerance parameter, the three points are considered collinear.
3. A three-dimensional arc measurement method according to claim 2, characterized in that: The steps to calculate the three-dimensional coordinates of the center and radius of the circle include: Use vector cross product to get the normal vector of the plane , and the plane equation Substitution Get the constant value : ; Build 、 The equation of the perpendicular bisector between the two points is as follows: get: 、 The coefficients of the perpendicular bisector equation are: The three equations combined form a linear equation system: Solve the three-dimensional coordinates of the center of the circle formed by three points ; Calculate the distance between two points using the distance formula 、 and arrive Distance of points: in, for point To the center distance of the points; Find the average distance from the three points to the center of the circle as the radius: in, is the radius.
4. A three-dimensional arc measurement method according to claim 1, characterized in that: In the multi-point fitting step, the center and radius of the circle are calculated by cyclically using the starting point, end point, and any intermediate point, and the root mean square value is calculated. The formula is as follows: in, is the distance from the point to the center of the circle, To determine whether it is the root mean square value of the optimal space circle; choose The center and radius corresponding to the minimum value are the best fitting spatial circle.
5. A three-dimensional arc measurement method according to claim 1, characterized in that: The steps to calculate the start and end angles and the arc sweep direction include: Select the plane basis vectors and determine the plane where the space circle is located by analyzing the distribution characteristics of all point coordinates; Calculate the vector from the center of the circle to the point and project it onto the plane coordinate system, and calculate the polar angle of the vector; The direction of the arc sweep is determined based on the magnitude of the polar angles.
6. A three-dimensional arc measurement method according to claim 1, characterized in that: Select the plane basis vectors and determine the plane where the space circle is located by analyzing the distribution characteristics of all point coordinates, including: Calculate the sum of the absolute values of the X, Y, and Z coordinates of all points: in, 、 and The sum of the absolute values of the X, Y, and Z coordinates of all points respectively; Select the coordinate axis with the smallest absolute value as the normal axis. Minimum, then the basis vector is and ;like Minimum, then the basis vector is and ;like Minimum, then the basis vector is and .
7. A three-dimensional arc measurement method according to claim 5 or 6, characterized in that: Calculate the vector from the center of the circle to the point and project it onto the plane coordinate system, and calculate the polar angle of the vector, including: Calculate the center of the circle to each point Vector: , And normalize: , Using basis vectors 、 ,Will Projecting a vector onto a plane coordinate system: Calculating vectors Polar angle: , record the angle value of each point ; The direction of the arc sweep depends on the starting point And the second point The size relationship is judged, if , then it is counterclockwise, if , it is clockwise.
8. A three-dimensional arc measurement method according to claim 2, characterized in that: The steps for calculating the interpolated angle value and the three-dimensional coordinates of the arc point include: Calculate the total angle of the arc: ; in, is the starting angle, is the ending angle; The number of interpolation points is , the interpolation point step size is , then the angle represented by each interpolation point is: ; Calculate the plane normal vector and interpolate the in-plane basis vectors; According to the parametric equation of the point on the circle, calculate the three-dimensional coordinates of the point on the circle corresponding to the interpolation angle. The equation is as follows: in, is the center of the circle; is the radius; is the angle represented by each interpolated point; are the coordinates of the interpolation point.
9. A three-dimensional arc measurement method according to claim 8, characterized in that: The steps to calculate the plane normal vector and interpolate the in-plane basis vectors are: The plane normal vector is , by calculating the normal vector and a reference vector The cross product of ; judge Is it a zero vector? If so, you need to recalculate the normal vector and another reference vector The cross product of ; If not, then according to the normal vector and vector Cross product to get vector Unitization 、 Vectors, as two basis vectors in the plane where the arc lies: According to the parametric equation of the point on the circle, calculate the three-dimensional coordinates of the point on the circle corresponding to the interpolation angle. The equation is as follows: in, is the center of the circle, is the radius, is the angle represented by each interpolation point, are the coordinates of the interpolation point.
10. A three-dimensional arc measurement system, characterized in that: A three-dimensional arc measurement method as described in any one of claims 1 to 9 is used.