Curve interpolation method, system and storage medium for a numerical control machine tool

Through the node vector division based on control points and the calculation of high bow errors, the interpolation point set and maximum feed speed are determined, which solves the problem of low interpolation accuracy of traditional NURBS curves, and achieves higher machining accuracy and smoothness.

CN114815743BActive Publication Date: 2025-07-22CENT SOUTH UNIV
View PDF -1 Cites 0 Cited by

Patent Information

Application Number
CN202210486505.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-06
Publication Date
2025-07-22
Estimated Expiration
2042-05-06

AI Technical Summary

Technical Problem

During the interpolation process of traditional NURBS curve interpolation, there is a problem that the control point has a low accuracy in controlling the NURBS curve.

Method used

By determining the node vector based on the control points of the curve to be interpolated, dividing the curve into N-segment lines, and determining the target interpolated point set based on the bow height error, calculating the coordinates of each interpolated point, calculating the bow height error using the midpoint method, solving the interpolated point with the recursive dichotomy method, recording the maximum feed speed and interpolation step length to meet the bow height error and velocity constraints.

Benefits of technology

The accuracy of interpolation point coordinates is improved, and the accuracy of control points control the NURBS curve is reduced, which reduces the amount of calculation, ensures that the processing curve is smoother, approaches the ideal NURBS curve, and improves the processing accuracy and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114815743B_ABST
    Figure CN114815743B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of motion control of numerical control machine tools, and discloses a curve interpolation method, system and storage medium for a numerical control machine tool. The method first determines the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, and divides the curve to be interpolated into N line segments based on the knot vector. Then, the target interpolation point set of the N line segments is determined based on the chord height error; the coordinates of each interpolation point of the curve to be interpolated are calculated according to the target interpolation point set. All interpolation points can meet the requirements of the chord height error, making the machining curve smoother and approaching the ideal NURBS curve. In this way, by using the method of determining the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, the coordinates of the interpolation points can be made more accurate, improving the accuracy of the control of the NURBS curve by the control points, and at the same time, the calculation amount can be controlled within the linear range.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of motion control of numerical control machine tools, and particularly to a curve interpolation method, system and storage medium for a numerical control machine tool. Background Art

[0002] Motion control systems such as numerical control machine tools use interpolation methods to control the tool along a given trajectory and speed to achieve workpiece contour machining. The interpolation operation, combined with requirements such as accuracy and process, determines some intermediate points between the control points of the ideal trajectory according to a certain mathematical method, thereby forming the machining trajectory of the tool. The higher the accuracy requirement, the more the machining trajectory is required to approximate the ideal workpiece contour as much as possible. Currently, in traditional Non-Uniform Rational B-Splines (NURBS curve) interpolation, in each interpolation cycle, according to the planned feed speed, the position of the next interpolation point is determined, and the increment of the NURBS curve parameter u is calculated according to this step size. The NURBS curve is "non-uniform", that is, the distribution of its knot parameters is not equidistant, and the basis functions corresponding to different knot parameters are different. Therefore, if the parameter value corresponding to the next interpolation point is not calculated, the subsequent calculation process cannot be carried out. So the key to the traditional interpolation algorithm lies in the calculation of the increment of parameter u. Currently, in the process of solving the NURBS curve parameters using the Newton iteration method, the solution of the derivative of the corresponding point on the curve is involved, which increases the amount of calculation and the calculation time. In addition, this method is affected by the initial value. When the initial value is not selected appropriately, the final result obtained may not converge, or the data points of reverse interpolation may be obtained instead of the correct solution.

[0003] It can be seen that in the traditional NURBS curve interpolation method, there is a problem of low accuracy in the control of the NURBS curve by the control points during the interpolation process. Summary of the Invention

[0004] The present invention provides a curve interpolation method, system and storage medium for a numerical control machine tool to solve the problem of low accuracy in the control of the NURBS curve by the control points during the interpolation process of the existing NURBS curve interpolation method.

[0005] To achieve the above object, the present invention is realized by the following technical solutions:

[0006] In the first aspect, the present invention provides a curve interpolation method for a numerical control machine tool, including:

[0007] Determine the curve to be interpolated according to the motion line of the numerical control machine tool;

[0008] Determine the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, and divide the curve to be interpolated into N line segments based on the knot vector, where N is a positive integer;

[0009] Determine the target interpolation point set of the N line segments based on the chord height error;

[0010] Calculate the coordinates of each interpolation point of the curve to be interpolated according to the target interpolation point set, and perform interpolation based on the interpolation point coordinates.

[0011] In a second aspect, the present application provides a curve interpolation system for a numerically controlled machine tool, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the steps of the method in the first aspect are implemented.

[0012] In a third aspect, the present application provides a computer-readable storage medium, on which a computer program is stored. When the program is executed by a processor, the method steps described in the first aspect are implemented.

[0013] Advantageous effects:

[0014] The curve interpolation method for a numerically controlled machine tool provided by the present invention first determines the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, divides the curve to be interpolated into N line segments based on the knot vector, and then determines the target interpolation point set of the N line segments based on the chord height error; calculates the coordinates of each interpolation point of the curve to be interpolated according to the target interpolation point set. This enables all interpolation points to meet the requirements of the chord height error, making the processed curve smoother and approaching the ideal NURBS curve. In this way, by using the method of determining the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, the interpolation point coordinates can be made more accurate, improving the accuracy of the control points for controlling the NURBS curve, and at the same time, the computational amount can be controlled within the linear range.

[0015] In a preferred embodiment, the specific position of the interpolation point on the NURBS curve is determined during the interpolation stage, and the maximum feed rate of each point under the normal acceleration and jerk limits is recorded, simplifying the purpose of the look-ahead speed planning. Description of the drawings

[0016] Figure 1 One of the flowcharts of a curve interpolation method for a numerically controlled machine tool according to a preferred embodiment of the present invention;

[0017] Figure 2 Another flowchart of a curve interpolation method for a numerically controlled machine tool according to a preferred embodiment of the present invention;

[0018] Figure 3 Schematic diagram of a quadratic cubic NURBS curve according to a preferred embodiment of the present invention;

[0019] Figure 4 It is the interpolation recursion flowchart based on the bow height error of the preferred embodiment of the present invention;

[0020] Figure 5 It is the schematic diagram of calculating the NURBS bow height error by the midpoint method of the preferred embodiment of the present invention. Specific embodiments

[0021] The technical solutions of the present invention will be described clearly and completely below. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without making creative efforts shall fall within the protection scope of the present invention.

[0022] Unless otherwise defined, the technical terms or scientific terms used in the present invention shall have the ordinary meanings understood by those of ordinary skill in the art to which the present invention belongs. The "first", "second" and similar terms used in the present invention do not denote any order, quantity or importance, but are only used to distinguish different components. Similarly, the terms such as "a" or "one" do not denote a quantity limitation, but mean that there is at least one. The terms such as "connected" or "coupled" are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The terms such as "upper", "lower", "left" and "right" are only used to represent relative positional relationships, and when the absolute position of the object to be described changes, the relative positional relationship also changes accordingly.

[0023] Please refer to Figure 1 , the embodiment of the present application provides a curve interpolation method for a numerically controlled machine tool, including:

[0024] Determine the curve to be interpolated according to the motion path of the numerically controlled machine tool;

[0025] Determine the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, and divide the curve to be interpolated into N line segments based on the knot vector, where N is a positive integer;

[0026] Determine the target interpolation point set of the N line segments based on the bow height error;

[0027] Calculate the coordinates of each interpolation point of the curve to be interpolated according to the target interpolation point set, and perform interpolation based on the interpolation point coordinates.

[0028] The curve interpolation method of the above-mentioned numerical control machine tool first divides the curve to be interpolated into N line segments, and then determines the target interpolation point set of the N line segments based on the chord height error; calculates the coordinates of each interpolation point of the curve to be interpolated according to the target interpolation point set. All interpolation points can meet the requirements of the chord height error, making the machining curve smoother and approaching the ideal NURBS curve. In this way, by determining the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, the coordinates of the interpolation points can be made more accurate, improving the accuracy of the control points in controlling the NURBS curve, and at the same time, the calculation amount can be controlled within the linear range.

[0029] Optionally, when dividing the curve to be interpolated into N line segments based on the knot vector, the K + 1 knots at the start end of the curve to be interpolated are regarded as knots with repeated parameters, and the parameter value is 0. The K + 1 knots at the end of the curve to be interpolated are regarded as knots with repeated parameters, and the parameter value is 1, where k represents the curve degree.

[0030] In this optional embodiment, the first k + 1 and the last k + 1 knot parameters are 0 and 1 respectively to ensure that the curve passes through the first and last endpoints. For the middle n - k knot vectors, a knot vector selection method based on the distance between control points is adopted. Different from the traditional equal-distance selection method, the present invention determines the value of the knot parameter according to the ratio of the distance between the control points of each NURBS curve segment to the sum of the distances of all control segments. First, it is judged which control points the points on the current curve segment are constrained by. Secondly, the sum of the ratio of the distance between the current relevant control points to the total control segment distance and the value of the previous knot parameter is used as the value of the current knot parameter. Finally, the knot vector value is obtained. The knot vector of the NURBS curve obtained by this method ensures that the NURBS curve passes through the first and last endpoints, and at the same time, the calculation amount can be controlled within the linear range. In addition, since this method makes the internal knots of the NURBS curve distributed according to the above rules, rather than the traditional equal distance, the control of the control points on the NURBS curve can be made more accurate.

[0031] Optionally, determining the target interpolation point set of the N line segments based on the chord height error includes:

[0032] Calculating the first chord height error between the first segmentation point at the first end of the target line segment and the second segmentation point at the second end. If the first chord height error is within the threshold range, add the first segmentation point and the second segmentation point to the interpolation point set. If the first chord height error is not within the threshold range, use the point corresponding to the median value of the parameter values of the first segmentation point and the second segmentation point as the new segmentation point;

[0033] Calculate the second sag error between the first segmentation point and the new segmentation point, and the third sag error between the second segmentation point and the new segmentation point, and continue to make the same judgment on the second and third sag errors as the first sag error. If it is within the specified threshold range, add the new segmentation point to the interpolation point set in sequence. Otherwise, continue to determine the new segmentation point in the same way, and iterate in this way until the sag errors of all new segmentation points meet the requirements of the threshold range. After traversing N line segments in sequence, determine the target interpolation point set; the target line is any one of the N line segments.

[0034] In this alternative embodiment, in order to make the length of the interpolation line segment as long as possible under the condition of meeting the limit condition of the sag error, the recursive bisection method is used to solve the interpolation points. The interpolation process is carried out by segments. For the current segment, since the segmentation point must be used as an interpolation point, the previous segmentation point of the current segment is first added to the interpolation point set, and the sag error of the line connecting the previous segmentation point and the subsequent segmentation point is calculated. Determine whether the current sag error is within the specified threshold range. If it meets the requirement, add the subsequent segmentation point to the interpolation point set. If it does not meet the requirement, use the midpoint corresponding to the median of the node parameter values of the two points as the new segmentation point, and calculate the sag error values of the lines connecting the two previous points and the new segmentation point respectively. Then, determine again whether the sag errors of the previous and subsequent segments are within the specified threshold range. If it is within the specified threshold range, add the new segmentation point to the interpolation point set in sequence. Otherwise, continue to segment the new segment whose sag error is not within the specified threshold range in the same way until the sag errors of all new segments meet the specified threshold. After traversing each curve in the same way, generate the final interpolation point set. The sag error of this method is calculated using the midpoint method. Since the interpolation algorithm of the present invention directly uses the sag error to determine the interpolation step size and does not involve the feed speed, the midpoint method is selected to calculate the sag error. By calculating the distance between the midpoint of two adjacent interpolation points and the interpolation point on the curve corresponding to the median of the node parameters of these two interpolation points to approximately replace the sag error, it is simpler than the traditional circular arc approximation method and reduces the calculation amount.

[0035] Optionally, the interpolation based on the interpolation point coordinates includes:

[0036] When interpolating based on the interpolation point coordinates, calculate the maximum feed speed of the interpolation point under the comprehensive constraints, and record the interpolation step size and the total arc length of the current interpolation point at the same time. The interpolation step size is determined by solving through the point-to-point distance formula according to the coordinates obtained by solving adjacent interpolation points, and the total arc length is determined by accumulating the step sizes of all interpolation points.

[0037] In this alternative embodiment, calculate and save the maximum feed speed and interpolation step size of each interpolation point. The NURBS curve generates normal acceleration and jerk at the turning point, which also restricts the speed. In order to enable the processing process to meet the maximum normal acceleration A specified by the equipmentnmax and the maximum normal jerk J nmax With the constraint of, the feed rate when passing through this point must be limited. Otherwise, if passing through a point with a large curvature at a very high feed rate, it may exceed the device driving ability, cause the motor to lose steps, and finally lead to low machining accuracy. Since the method proposed in the present invention has determined the position of the interpolation point on the NURBS curve during the interpolation process, the maximum feed rate of this point under the comprehensive constraint can be calculated while interpolating, and at the same time, the step length of the current interpolation point and the total arc length can be recorded.

[0038] In this way, compared with the traditional interpolation algorithm that selects the next interpolation point according to the hardware interpolation cycle, the interpolation process cannot determine the interpolation step length and chord height error, and it is necessary to ensure that the chord height error and feed rate of the interpolation point meet the hardware limitations through look-ahead speed planning. The present invention determines the specific position of the interpolation point on the NURBS curve during the interpolation stage and records the maximum feed rate of each point under the acceleration and jerk limitations, simplifying the purpose of look-ahead speed planning.

[0039] In a complete example, please refer to Figure 2 , first linearly calculate the NURBS curve knot vector based on the distance between control points, and segment according to the knot vector. Solve and save the knot parameters and coordinate values of the interpolation point using the recursive bisection method according to the chord height error, and at the same time calculate and save the maximum feed rate and interpolation step length under the curvature constraint during the interpolation process. Complete the interpolation algorithm process based on the chord height error.

[0040] First, linearly calculate the NURBS curve knot vector based on the control point distance. n + 1 represents the number of control points of the NURBS curve, and k represents the curve degree, where 2 ≤ k ≤ n. The knot vector U = [u0, u1,..., u n+k+1 , the number of knot vectors is n + k + 2, and the first k + 1 and the last k + 1 knot parameters are 0 and 1 respectively to ensure that the curve passes through the start and end points. The middle n - k knot parameters adopt the knot vector selection method based on the control point distance. Different from the traditional equal-distance selection method, the present invention determines the value of the knot parameter according to the ratio of the distance of each NURBS curve control point to the sum of the distances of all control segments, that is, first judge which control points the points on the current segment of the curve are constrained by, and then use the sum of the ratio of the distance between the current relevant control points to the total control segment distance and the value of the previous knot parameter as the value of the current knot parameter. Taking Figure 3 as an example, Figure 3 is a schematic diagram of a 2nd-degree 3rd-order NURBS curve, with a total of 7 control points. P0P1P2 determines the first segment of the NURBS curve P0K1, P1P2P aDetermines the second - segment NURBS curve K1K2, and so on. Therefore, the values of the knot parameters are determined according to the ratio of the distance between the control points of each NURBS curve segment to the sum of the distances of all control segments. The distance between the control points of the first - segment curve is the distance of P0P1 plus the distance of P1P2, the distance between the control points of the second - segment curve is the distance of P1P2 plus the distance of P2P3, and so on. The total sum of the distances between the control points, L, can be obtained. c As follows:

[0041]

[0042] Since k = 2, the first three knot parameter values are 0, and the last three knot parameter values are 1. The value of the fourth knot parameter is calculated according to the following formula:

[0043]

[0044] Similarly, the value of the fifth knot parameter is:

[0045]

[0046] Similarly, the values of each intermediate knot parameter can be obtained. By this method, the knot vector of the NURBS curve is obtained, ensuring that the NURBS curve passes through the start and end points, and at the same time, the computational complexity can be controlled within the linear range. In addition, since this method makes the internal knots of the NURBS curve distributed according to the above - mentioned rule instead of the traditional equal - distance distribution, the control of the control points over the NURBS curve is more accurate.

[0047] Before formal interpolation, the NURBS curve is reasonably segmented. The knot - vector calculation method of the present invention starts with all - multiple knots and ends with all - multiple knots, that is, the first k + 1 and the last k + 1 knot parameters are repeated, being 0 and 1 respectively, ensuring that the NURBS curve passes through the start and end points. Therefore, the start and end points can be used as the start and end segmentation points first. Secondly, the corresponding simple knots in the knot vector, that is, the knots corresponding to the non - repeated knot parameter values, are selected as the intermediate segmentation points. The De Boor recurrence method is used to solve the coordinate values of each segmentation point. The De Boor recurrence formula is:

[0048]

[0049]

[0050]

[0051] In the formula, C(u) represents the point on the curve to be interpolated, i represents the position subscript of the previous segmentation point of the current interpolation interval in the knot vector, 1 represents the current iteration count, represents an intermediate variable in the recursive process, k represents the degree of the curve, N j,k-1 Nj,k-1(u) represents the j-th (k-1)-th B-spline basis function of the curve to be interpolated, represents the intermediate control point obtained by converting the coordinate solution of the corresponding point on the curve, u i represents the i-th parameter knot value, u i+1 represents the (i+1)-th parameter knot value, represents the variable parameter in the recursive calculation process, u represents the parameter value of the point to be solved, d j represents the j-th control point, u j+1 represents the (j+1)-th parameter knot value, u j+k+1 represents the (j+k+1)-th parameter knot value.

[0052] The interpolation process is carried out on the basis of this segmentation, so the determined segmentation points are also the initial interpolation points. This kind of segmentation is simple and clear, and the simple knots are used as the boundaries on the curve. When the points on the NURBS curve transition on this boundary, one control point loses its influence on the points on a continuous curve segment, and the other control point gains influence. Therefore, it is more appropriate to select simple knots as the segmentation points.

[0053] Still taking Figure 3 as an example, the knot vector U of this curve is U = [u0, u1,..., u9], where u0, u1, u2 correspond to fully repeated knots, and the knot parameter values are 0. The NURBS curve passes through the starting control point P0. u7, u8, u9 correspond to fully repeated knots, and the knot parameter values are 1. The NURBS curve passes through the ending control point P6. P0 and P6 are used as the head and tail segmentation points respectively. The simple knots K1, K2, K3, K4 corresponding to u3, u4, u5, u6 respectively are used as the intermediate interpolation points. It can be seen from the solid and dashed line marks in the figure that this NURBS curve is divided into 5 segments. Using the de Boor recursive method to solve the coordinate values of each segmentation point, taking the K1 knot as an example, substituting the knot parameter u3 into the de Boor recursive formula, we get:

[0054]

[0055]

[0056]

[0057] Similarly, calculate and save the coordinates of each initial interpolation point, and then perform the interpolation operation.

[0058] The interpolation process is as Figure 4Flowchart. In order to maximize the length of the interpolation line segment while satisfying the constraint of the sag error, the present invention uses the recursive bisection method to solve the interpolation points. The calculation process is carried out in segments. For the current segment, since the segmentation point must be used as an interpolation point, the previous segmentation point of the current segment is first added to the interpolation point set, and the sag error of the line connecting the previous segmentation point and the subsequent segmentation point is calculated. It is judged whether the current sag error is within the range specified by the threshold. If it meets the requirement, the subsequent segmentation point is added to the interpolation point set. If it does not meet the requirement, the point corresponding to the median value of the node parameter values of the two points is used as a new segmentation point, and the sag error values of the lines connecting the two previous points and the new segmentation point are calculated respectively. Then it is judged again whether the sag errors of the front and rear segments are within the range specified by the threshold. If they are within the range specified by the threshold, the new segmentation points are sequentially added to the interpolation point set. Otherwise, the new segment with the sag error not within the range specified by the threshold is segmented in the same way until the sag errors of all new segments meet the threshold requirements. After traversing each curve in the same way, the final interpolation point set is generated. The sag error of this method is calculated using the midpoint method. Since the interpolation algorithm of the present invention directly uses the sag error to determine the interpolation step size and does not involve the feed speed, the midpoint method is selected to calculate the sag error.

[0059] Figure 5 The method for calculating the sag error by the midpoint method approximates the sag error by calculating the distance between the midpoint of two adjacent interpolation points and the interpolation point on the curve corresponding to the median value of the node parameters of these two interpolation points. Compared with the traditional circular arc approximation method, the calculation is simpler and the amount of calculation is reduced. The midpoint method calculation formula is:

[0060]

[0061] In the formula, δ i represents the curve sag error between the points corresponding to the parameter values u i and u i+1 , M i represents the midpoint of the line connecting the points corresponding to u i and u i+1 , and N i represents the point on the curve corresponding to the median value of the parameter values u i and u i+1 ((u i +u i+1 ) / 2).

[0062] Similarly, taking Figure 3 as an example, for the interpolation of the first curve segment P0K1, first add C(u2) to the interpolation set, and use the midpoint method to calculate the sag error of P0K1 It is judged that δ0 does not satisfy the arc height error threshold range, and binary division is performed. The arc height errors δ1 and δ2 of P0N0 and N0K1 are calculated respectively, and then it is judged again whether the arc height error threshold range is satisfied. And so on until the arc height error of each interpolation segment of the current curve segment P0K1 meets the requirements. The interpolation points on the curve corresponding to each interpolation segment are added to the interpolation point set, and then the interpolation of the next curve segment K1K2 is carried out. Until the interpolation of the entire NURBS curve is completed, it is ensured that the arc height error between each interpolation point meets the threshold requirements, making the drawn motion trajectory smoother and closer to the ideal NURBS curve.

[0063] Calculate and save the maximum feed rate and interpolation step length of each interpolation point. In addition to the constraint of the arc height error on the interpolation point speed, since the NURBS curve is not a straight line, the normal acceleration and jerk generated at the turning point will also impose constraints on the speed.

[0064] In order to meet the given maximum normal acceleration A nmax and maximum normal jerk J nmax constraints during the machining process, it is necessary to limit the feed rate when passing through this point. Otherwise, if a large feed rate is used to pass through a point with a large curvature, it may exceed the device driving ability, cause the motor to lose steps, and finally lead to low machining accuracy. Since the method proposed in the present invention has determined the position of the interpolation point on the NURBS curve during the interpolation process, the maximum feed rate under the comprehensive constraints of this point can be calculated while interpolating. At the same time, the step length of the current interpolation point and the total arc length can be recorded, and the total arc length is obtained by accumulating the step lengths of all interpolation points.

[0065] First, solve the interpolation points of the NURBS curve. The present invention uses the de Boor recurrence method to solve the coordinate values, first-order and second-order derivative vectors of the interpolation points. The NURBS curve is a special B-spline curve, and its definition formula contains B-spline basis functions. Therefore, the solution process of the NURBS curve can draw on the B-spline curve, and the de Boor recurrence is used to reduce the computational complexity of the solution. The recurrence formula of this method is:

[0066]

[0067]

[0068]

[0069]

[0070] In the formula, C (r) (u) represents the r-th derivative vector of the point C(u) on the curve, r represents the order of differentiation, represents the r-th order differentiation of C(u) with respect to u, Denotes the intermediate variable in the derivative recurrence process using the de Boor recurrence formula, N j,k N(u) represents the j-th k-th order B-spline curve basis function of the curve to be interpolated, N j,k-r N(u) represents the j-th (k-r)-th order B-spline curve basis function of the curve to be interpolated.

[0071] Assume the current interpolation point is C(u i ), and the curvature K(u i ) of the current interpolation point is:

[0072]

[0073] Obtain the maximum feed rate v limitAn (u i ) and v limitJn (u i ) as follows:

[0074]

[0075]

[0076] From this, the maximum feed rate at the interpolation point C(u i ) of the NURBS curve under curvature constraint can be obtained as:

[0077]

[0078] Similarly, taking Figure 3 as an example, calculate the maximum feed rate at the interpolation point N1. First, solve the coordinates, first-order and second-order derivative vectors at N1, and obtain the parameter value u n1 ∈[u2, u3] at this point during the interpolation process, and substitute it into the de Boor recurrence formula to get:

[0079]

[0080]

[0081]

[0082]

[0083] where d j represents the control vertex of the NURBS curve. After the solution, calculate the curvature value K(u n1 ) at N1:

[0084]

[0085] Obtain the maximum feed rate vlimitAn (u n1 ) and v limitJn (u n1 ) are as follows:

[0086]

[0087]

[0088] Thus, the maximum feed rate of the NURBS curve under curvature constraint at the interpolation point C(u n1 ) can be obtained as follows:

[0089] v limit (un1) = min(v limitAn (u n1 ), v limitJn (un1));

[0090] The curvature of the NURBS curve changes continuously, so the maximum feed rate under curvature constraint also changes continuously. Compared with the traditional interpolation algorithm that selects the next interpolation point according to the hardware interpolation cycle, the interpolation process cannot determine the interpolation step size and chord height error, and forward-looking speed planning is required to ensure that the chord height error and feed rate of the interpolation point meet the hardware limitations. In the interpolation stage of the present invention, the specific position of the interpolation point on the NURBS curve is determined, and the maximum feed rate of each point under the normal acceleration and jerk limitations is recorded, simplifying the purpose of forward-looking speed planning.

[0091] In summary, for the curve interpolation system of the numerical control machine tool provided in this application, the interpolation algorithm based on chord height error uses the distance between control points as the node vector selection method, making the control of the control points on the NURBS curve more accurate, thereby improving the machining accuracy. In addition, this algorithm does not perform interpolation operations based on the interpolation cycle, but searches for the maximum interpolation step size under the limitation of chord height error, reducing the number of discrete segments of the curve and improving the machining efficiency. Moreover, each interpolation point meets the chord height error requirement, making the machining curve smoother and approaching the ideal NURBS curve, improving the machining accuracy. At the same time, this algorithm determines the position of the interpolation point on the NURBS curve during the interpolation operation, and can calculate the maximum feed rate of the interpolation point under comprehensive constraints, as well as the step size and total arc length of the current segment during interpolation, which is helpful for forward-looking speed planning and reduces the computational complexity. Experiments prove that compared with the traditional interpolation algorithm, the curve interpolated by this algorithm is smoother, and the chord height error can meet the set requirements. Therefore, the present invention can maximize high machining accuracy, improve the smoothness of the curve, and improve the machining quality.

[0092] The preferred specific embodiments of the present invention have been described in detail above. It should be understood that those of ordinary skill in the art can make many modifications and variations based on the concept of the present invention without creative work. Therefore, all technical solutions that can be obtained by those skilled in the art in this technical field based on the concept of the present invention through logical analysis, reasoning, or limited experiments on the basis of the prior art shall fall within the protection scope determined by the claims.

Claims

1. A curve interpolation method for a numerically controlled machine tool, characterized in that Including: Determine the curve to be interpolated according to the motion path of the numerical control machine tool; Determine the knot vector corresponding to the curve to be interpolated according to the control points corresponding to the curve to be interpolated, and divide the curve to be interpolated into N line segments based on the knot vector, where N is a positive integer; Determine the target interpolation point set of the N line segments based on the chord height error; Calculate the coordinates of each interpolation point of the curve to be interpolated according to the target interpolation point set, and perform interpolation based on the interpolation point coordinates; When dividing the curve to be interpolated into N line segments based on the knot vector, regard the K+1 knots at the beginning end of the curve to be interpolated as knots with repeated parameters, with the parameter value being 0, and regard the K+1 knots at the end end of the curve to be interpolated as knots with repeated parameters, with the parameter value being 1, where k represents the curve degree; The determining the target interpolation point set of the N line segments based on the chord height error includes: Calculate the first chord height error between the first segmentation point at the first end of the target line segment and the second segmentation point at the second end. If the first chord height error is within the threshold range, add the first segmentation point and the second segmentation point to the interpolation point set. If the first chord height error is not within the threshold range, use the point corresponding to the median value of the parameter values of the first segmentation point and the second segmentation point as the new segmentation point; Calculate the second chord height error between the first segmentation point and the new segmentation point and the third chord height error between the second segmentation point and the new segmentation point, and continue to make the same judgment on the second chord height error and the third chord height error as the first chord height error. If it is within the range specified by the threshold, add the new segmentation points to the interpolation point set in sequence. Otherwise, continue to determine new segmentation points in the same way, and iterate in this way until the chord height errors of all new segmentation points meet the requirements of the threshold range. After traversing the N line segments in sequence, determine the target interpolation point set; the target line segment is any one of the N line segments.

2. The curve interpolation method of the numerical control machine tool according to claim 1, wherein The performing interpolation based on the interpolation point coordinates includes: While performing interpolation based on the interpolation point coordinates, calculate the maximum feed speed of the interpolation point under comprehensive constraints, and record the interpolation step length and total arc length of the current interpolation point at the same time. Among them, the interpolation step length is determined by solving the coordinates obtained from adjacent interpolation points through the point-to-point distance formula, and the total arc length is determined by accumulating the step lengths of all interpolation points.

3. A curve interpolation system for a numerically controlled machine tool, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of any one of the methods described in claims 1 to 2 above.

4. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method steps described in any one of claims 1-2.