Curve velocity planning method, device, and numerical control machining route data processing method thereof
10768602 ยท 2020-09-08
Assignee
Inventors
Cpc classification
G05B19/416
PHYSICS
G05B19/19
PHYSICS
International classification
G05B19/19
PHYSICS
G05B19/416
PHYSICS
Abstract
A method and a device for curve velocity planning based on NURBS (non-uniform rational B-splines) curve interpolation as well as a numerical control machining route data processing method using NURBS curve interpolation velocity planning are provided. The method includes: obtaining numerical control machining route data with a NURBS curve; obtaining an acceleration within a parameter step length on the NURBS curve; comparing each the acceleration with a maximum allowable acceleration to determine an acceleration sensitive point and an acceleration sensitive interval; determining an intermediate point of the acceleration sensitive interval as a demarcation point of the acceleration and the deceleration; calculating a velocity value of the intermediate point as a target velocity; and planning the acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve.
Claims
1. A numerical control machining route data processing method, comprising: obtaining numerical control machining route data with a NURBS (non-uniform rational B-splines) curve; obtaining an acceleration within a parameter step length on the NURBS curve; comparing the acceleration of everywhere of the NURBS curve with a maximum allowable acceleration to determine an acceleration sensitive point and determining an acceleration sensitive interval based on the determined acceleration sensitive point; determining an intermediate point of the acceleration sensitive interval as a demarcation point of the acceleration and the deceleration within the sensitive interval; calculating a velocity value of the intermediate point as a target velocity; and planning the acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve; wherein the comparing the acceleration of everywhere of the NURBS curve with the maximum allowable acceleration to determine the acceleration sensitive point and determining the acceleration sensitive interval based on the determined acceleration sensitive point comprises: calculating a curvature 1/.sub.i of everywhere of the NURBS curve and determining a maximum allowable velocity curve based on a constraint condition of a chord height error .sub.max and a constraint condition of a centripetal acceleration a.sub.max; and calculating the acceleration a.sub.i within each parameter step length u.sub.i, determining an end point of the parameter step length corresponding to the acceleration with a minimum difference from the maximum allowable acceleration as the acceleration sensitive point when the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration, and determining the acceleration sensitive interval based on the determined acceleration sensitive point.
2. The method of claim 1, wherein the planning the acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve comprises: determining whether one or more parameters corresponding to an interpolation point has entered the acceleration sensitive interval; and accelerating from a side point of the acceleration sensitive interval taken as a start point to the intermediate point, and decelerating from the intermediate point to another side point of the acceleration sensitive interval taken as an end point when the one or more parameters corresponded by the interpolation point are determined to have entered the acceleration sensitive interval.
3. A velocity control method based on NURBS (non-uniform rational B-splines) curve interpolation, comprising: calculating a curvature 1/.sub.i of everywhere of the NURBS curve and determining a curve of a maximum allowable velocity based on a constraint condition of a chord height error .sub.max and a constraint condition of a centripetal acceleration a.sub.max; calculating an acceleration a.sub.i within each parameter step length u.sub.i and determining an end point of the parameter step length u.sub.i corresponding to the acceleration a.sub.i with a minimum difference from a maximum allowable acceleration as the acceleration sensitive point when the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration; dividing the curve of the maximum allowable velocity into a plurality of segments at a minimum value, determining a corresponding parameter value u.sub.mid according to an intermediate point of an acceleration sensitive interval of each of the velocity curve segments, and calculating a velocity value of the intermediate point; determining whether a parameter u corresponding to an interpolation point has entered the acceleration sensitive interval; and accelerating from a side point of the acceleration sensitive interval taken as a start point to the intermediate point, and decelerating from the intermediate point to another side point of the acceleration sensitive interval taken as an end point when the parameter u corresponded by the interpolation point is determined to have entered the acceleration sensitive interval, wherein an acceleration of the intermediate point is 0.
4. The method of claim 3, wherein the acceleration a.sub.i within the parameter step length u.sub.i is calculated through the following formula: first formula:
5. The method of claim 3, wherein the velocity value of the intermediate point is calculated using the following formulas:
V.sub.min=V.sub.m+a.sub.m(u.sub.midu.sub.m);second formula:
V.sub.mid=V.sub.m+n+a.sub.m+n(u.sub.midu.sub.m+n);third formula: wherein a.sub.m and a.sub.m+n are respectively the acceleration of two end points of the acceleration sensitive interval of the velocity curve, and u.sub.m and u.sub.m+n are respectively the corresponding parameters of the two end points; the value of v.sub.mid is the minimum value among a value calculated through the second and the third formulas and the maximum allowable velocity.
6. The method of claim 3, wherein the velocity value of the intermediate point is set as the maximum allowable velocity when the velocity value of the intermediate point is greater than the maximum allowable velocity.
7. The method of claim 5, wherein when the velocity value of the intermediate point is set as the maximum allowable velocity when the velocity value of the intermediate point is greater than the maximum allowable velocity.
8. The method of claim 3, wherein the acceleration of the start point is a slope value of the start point of the acceleration sensitive interval, an initial acceleration from the intermediate point to decelerate to another end point is 0, and an end acceleration is a slope value of an end point of the acceleration sensitive interval.
9. A numerical control machine, comprising a numerical control system, a servo motor, and an execution component, the numerical control system is configured to: obtain numerical control machining route data with a NURBS (non-uniform rational B-splines) curve; obtain an acceleration a.sub.i within a parameter step length u.sub.i on the NURBS curve; compare the acceleration a.sub.i of everywhere of the NURBS curve with a maximum allowable acceleration to determine an acceleration sensitive point and determine an acceleration sensitive interval based on the determined acceleration sensitive point; determine an intermediate point of the acceleration sensitive interval as a demarcation point of the acceleration and the deceleration within the sensitive interval; calculate a velocity value of the intermediate point as a target velocity; plan acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve; and receive the numerical control machining route data with the planned NURBS curve and control the execution component to perform numerical control machining according to the received numerical control machining route data through the servo motor; wherein the comparing the acceleration of everywhere of the NURBS curve with the maximum allowable acceleration to determine the acceleration sensitive point and determining the acceleration sensitive interval based on the determined acceleration sensitive point comprises: calculating a curvature 1/.sub.i of everywhere of the NURBS curve and determining a maximum allowable velocity curve based on a constraint condition of a chord height error .sub.max and a constraint condition of a centripetal acceleration a.sub.max; and calculating the acceleration a.sub.i within the parameter step length u.sub.i, determining an end point of the parameter step length corresponding to the acceleration with a minimum difference from the maximum allowable acceleration as the acceleration sensitive point when the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration, and determining the acceleration sensitive interval based on the determined acceleration sensitive point.
10. The numerical control machine of claim 9, wherein the calculating the velocity value of the intermediate point comprises: dividing the curve of the maximum allowable velocity into a plurality of segments at a minimum value, determining a corresponding parameter value u.sub.mid according to an intermediate point of an acceleration sensitive interval of each of the velocity curve segments, and calculating a velocity value of the intermediate point.
11. The numerical control machine of claim 10, wherein the acceleration within the parameter step length u.sub.i is calculated through the following formula: first formula:
V.sub.min=V.sub.m+a.sub.m(u.sub.midu.sub.m);second formula:
V.sub.mid=V.sub.m+n+a.sub.m+n(u.sub.midu.sub.m+n);third formula: wherein a.sub.m and a.sub.m+n are respectively the acceleration of two end points of the acceleration sensitive interval of the velocity curve, and u.sub.m and u.sub.m+n are respectively the corresponding parameters of the two end points; the value of v.sub.mid is the minimum value among a value calculated through the second and the third formulas and the maximum allowable velocity.
12. The numerical control machine of claim 9, wherein the planning the acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the planned numerical control machining route data with the NURBS curve comprises: determining whether one or more parameters corresponding to an interpolation point has entered the acceleration sensitive interval; and accelerating from a side point of the acceleration sensitive interval taken as a start point to the intermediate point, and decelerating from the intermediate point to another side point of the acceleration sensitive interval taken as an end point when the one or more parameters corresponded by the interpolation point are determined to have entered the acceleration sensitive interval.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1)
(2)
(3)
(4)
(5)
(6)
(7)
DETAILED DESCRIPTION
(8) In order to give a detailed description of the technical content, structural features, purpose and effect of the present disclosure, the present disclosure is described in detail in conjunction with the drawings and embodiments.
(9) Firstly, the basic principles of a NURBS curve interpolation algorithm are described as follows.
(10) 1. NURBS curve is a piecewise polynomial curve, usually written as a form of one variable function with respect to an argument u:
(11)
(12) where, p is the order (the highest power of the polynomial), Pi is the control point (the Cartesian coordinates of the polygon which limits the shape of the curve), w.sub.i is the weight (the extent to which the curve is attracted by the control point), u.sub.i is the node (the parameter value of the start and end point in the segmented interval), and u is the independent variable of the NURBS curve called the node vector, where U={U.sub.1, U.sub.2, . . . , U.sub.n+1}. N.sub.i, p(u) is a non-uniform rational B-spline basis function, which is determined by the node vector U and satisfies Cox-de Boor recursive relation expressions (2) and (3):
(13)
(14) 2. The velocity control of NURBS curve interpolation:
(15) the NURBS curve is set as: P(u)=(x(u), y(u), z(u))
(16) wherein, the time function u is the curve parameter, which is denoted by u(t.sub.i)=u.sub.i, u(t.sub.i+1)=u.sub.i+1. Each parameter u corresponds to a point on the NURBS curve. Hence, the NURBS curve interpolation is to select a series of u in the parameter field and calculate the points on the curve corresponded by the u (i.e., the machining section in the machining path of the machining tool).
(17) The parameter value of the current point is u(t.sub.i), hence the corresponding parameter u(t.sub.i+1) of the interpolation point which after an interpolation cycle T satisfies the following Taylor expansion:
(18)
(19) 3. the impact of chord height error on the feed rate and feed step length:
(20) the NURBS curve interpolation is usually realized by using a chord segment between two interpolation points u.sub.i and u.sub.i+1 to close an arc segment, and the maximum distance between the chord segment and the arc segment is a maximum interpolation string high error. In a fixed periodic numerical control interpolation, in order to ensure that the interpolation trajectory to satisfy a certain accuracy requirement, it is necessary to limit the maximum feed rate.
(21) The arc approximation method can be used to obtain the chord height error:
(22)
(23) where, .sub.i is the radius of curvature at u.sub.i, V is the programmed feed rate, and T is the interpolation period. Through formula (5), it can be obtained that:
(24)
(25) Assuming that the maximum chord height error is .sub.max, then it can be obtained through formula (6) that:
(26)
(27) where, L.sub.i is the feeding step length of the i-th segment. From the above equation, it can be seen that each segment of the feeding step length must meet the limit condition of the maximum chord height error. At the same time, in order to satisfy the requirements of the machining accuracy of a numerical control machine, the feeding step length of the NURBS curve in each interpolation period must also consider the constraints of the acceleration and deceleration as well as the maximum normal acceleration, that is:
L=min(L.sub.i1,{square root over (8.sub.i.sub.max)},T{square root over (a.sub.max)})(8)
(28) where, L.sub.i1 is the feeding step length under the constraint of acceleration and deceleration, a.sub.max is the maximum normal acceleration, and:
a.sub.max=V(u.sub.i).sup.2.sub.i(9)
(29) Therefore, according to the above formula and as shown in
(30) Referring to
(31) At S10: obtaining numerical control machining route data with a NURBS curve.
(32) At S11: obtaining an acceleration a.sub.i within a parameter step length u.sub.i on the NURBS curve.
(33) At S12: comparing the acceleration of everywhere of the NURBS curve with a maximum allowable acceleration to determine an acceleration sensitive point and determining an acceleration sensitive interval based on the determined acceleration sensitive point.
(34) In this embodiment, a maximum allowable acceleration is determined based on a curvature 1/.sub.i of everywhere of the NURBS curve, a constraint condition of a chord height error .sub.max, and a constraint condition of a centripetal acceleration a.sub.max. When the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration, an end point of the parameter step length corresponding to the acceleration with a minimum difference from the maximum allowable acceleration is determined as the acceleration sensitive point.
(35) At S13: determining an intermediate point of the acceleration sensitive interval as a demarcation point of the acceleration and the deceleration within the sensitive interval.
(36) At S14: calculating a velocity value of the intermediate point as a target velocity.
(37) At S15: planning the acceleration and deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve.
(38) In one embodiment, when the parameter(s) corresponded by the interpolation point have entered the acceleration sensitive interval, it accelerates from a side point of the acceleration sensitive interval which is taken as a start point to the intermediate point, and decelerates from the intermediate point to another side point of the acceleration sensitive interval which is taken as an end point, thereby realizing planning the acceleration and deceleration of the acceleration sensitive interval.
(39) Referring to
(40) At S20: calculating a curvature 1/.sub.i of everywhere of the NURBS curve and determining a curve of a maximum allowable velocity (i.e., the maximum allowable velocity V.sub.max of everywhere of the NURBS curve) based on a constraint condition of a chord height error .sub.max (formula (5)) and a constraint condition of a centripetal acceleration a.sub.max (formula (9)).
(41) At S21: calculating an acceleration within each parameter step length u.sub.i and comparing with a maximum allowable acceleration. When the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration, it determines an end point of the parameter step length corresponding to the acceleration with a minimum difference from a maximum allowable acceleration as the acceleration sensitive point.
(42) Where, the value of the parameter step length u is set as a minimum value such as u=10.sup.5, hence the acceleration process within the parameter step length u can be regarded as an even acceleration process.
(43) Specifically, the acceleration in each parameter step length u.sub.i is calculated using the following equation (10)
(44)
(45) Where, u.sub.i is the parameter value of the current interpolation point, the numerator represents the velocity value, and the denominator represents using a chord segment between two of the interpolation points on the NURBS curve to replace an arc segment. Since the length of the chord segment is smaller than that of the arc segment, the calculated value of the acceleration is larger than the real value. If the larger acceleration value is to be restricted to smaller than the maximum allowable acceleration, the real value of the acceleration at all positions will certainly not exceed the limitation of the maximum allowable acceleration.
(46) Furthermore, through comparing the acceleration value of the end point of each parameter step length u.sub.i and the maximum allowable acceleration value, the acceleration sensitive point such as star mark point as shown in
(47) At S22: dividing the curve of the maximum allowable velocity determined in step S20 into a plurality of segments at a minimum value (each segment of the curve of the maximum allowable velocity is hereinafter referred to as a velocity curve segment), that is, the velocity curve between two velocity wave troughs is a segment (the start point and the end point of a complete curve are also considered as a velocity wave trough). The acceleration sensitive point of a velocity curve segment is determined, the corresponding acceleration sensitive interval (hereinafter referred to as the sensitive interval) and a parameter value u.sub.mid corresponded by the intermediate point of the sensitive interval are determined, and the velocity value of the intermediate point is calculated.
(48) Specifically, two end points of the sensitive interval are respectively extended with a line and intersected at a point according to the current slope, and the intersected point is called an intermediate point, and the parameter value u.sub.mid corresponded by the intermediate point is the end point of the acceleration interpolation phase of the velocity curve segment, and is simultaneously the start point of the deceleration interpolation phase. When the intermediate point velocity is greater than the maximum allowable velocity, then the maximum allowable velocity is used.
(49) Where, the velocity value of the intermediate point is calculated using the following formulas (11) and (12):
V.sub.mid=V.sub.m+a.sub.m(u.sub.midu.sub.m)(11)
V.sub.midV.sub.m+n+a.sub.m+n(u.sub.midu.sub.m+n)(12)
(50) Where, a.sub.m and a.sub.m+n are respectively the accelerations of two end points of the acceleration sensitive interval of the velocity curve segment, and u.sub.m and u.sub.m+n are respectively the corresponding parameters of the two end points.
(51) As shown in
(52) Through calculating the accelerations a.sub.3, a.sub.6 of the points 3 and 6 to take as the slope, straight line equations l.sub.1 and l.sub.2 which pass through 3 points (u3, v3) and 6 points (u6, v6) can be obtained, respectively:
l.sub.1:v=v.sub.3+a.sub.3(uu.sub.3)
l.sub.2:v=v.sub.6+a.sub.6(uu.sub.6)
(53) The coordinates (u.sub.mid, v.sub.mid) of the intersection (i.e., the midpoint) can be obtained by taking the above equations as simultaneous equations. Where, the value of v.sub.mid is the minimum value between the calculated value and the maximum allowable velocity. It should be noted that, since the slope a.sub.3 and a.sub.6 are the maximum allowable acceleration in the acceleration and the deceleration phase, as long as the re-planned velocity curve is below the two lines, it should satisfy the limitation of the system acceleration. The intermediate point obtained through this way will be enclosed below the two straight lines. That is, it can ensure that the end point and the start point of the acceleration and the deceleration are within the scope satisfying the limitation of the acceleration, therefore the coordinate of the middle point is reasonable and acceptable.
(54) At S23: initialing a real-time interpolation, determining the parameter u corresponded to the interpolation point according to the formula (4) and determining whether the parameter u has entered the determined sensitive interval. If so, enter step S24; otherwise, enter step S25.
(55) At S24: accelerating from a side (e.g., the left side) point of the sensitive interval to the intermediate point, and decelerating toward the other side (e.g., the right side) point of the sensitive interval, where the acceleration is 0 in the intermediate point. Then, the process ends.
(56) Where, the acceleration of the start point is the slope value of the point, the acceleration and the jerk should be maintained as the requirement of equation (8), and the initial acceleration is 0, and the end acceleration is the slope value of the side point of the other side (the right side).
(57) Specifically, the acceleration from the left side of the sensitive interval to the intermediate point is an S-like type acceleration process. The initial acceleration is not 0 and the end acceleration is 0. The end velocity should not exceed v.sub.mid and the end point of the acceleration should not exceed u.sub.mid. It is used as the acceleration condition, each cycle in the acceleration process is utilized as a basis for whether or not to use positive jerk, and ultimately to accelerate to the intermediate point softly. The process of decelerating from the intermediate point is also an S-like type deceleration process, where the initial acceleration is 0, the end acceleration is not 0, the end velocity as close as possible to v.sub.6, and the end point of the acceleration should not exceed u.sub.6.
(58) Since the user has specified the feed rate limitation such that the curve of the maximum allowable velocity emerges an even velocity segment (for example, the interval of point 4 to point 5 in
(59) As shown in
(60) At S25: calculating the interpolation point based on the maximum allowable velocity according to the formula (8), and then the process ends.
(61) Referring to
(62) a maximum allowable velocity curve confirm unit 31 configured to determine a curve of a maximum allowable velocity based on a curvature 1/.sub.i of everywhere of the NURBS curve, a constraint condition of a chord height error .sub.max and a constraint condition of a centripetal acceleration a.sub.max;
(63) an acceleration sensitive point confirm unit 32 configured to calculate an acceleration within each parameter step length u.sub.i and determine an end point of the parameter step length corresponding to the acceleration with a minimum difference from a maximum allowable acceleration as the acceleration sensitive point when the acceleration a.sub.i within the parameter step length u.sub.i is greater than the maximum allowable acceleration and the acceleration a.sub.i+n within the parameter step length u.sub.i+n is smaller than the maximum allowable acceleration;
(64) an intermediate point velocity confirm unit 33 configured to determine a corresponding parameter value u.sub.mid according to an intermediate point of an acceleration sensitive interval of each velocity curve segment obtained by dividing the curve of the maximum allowable velocity at a minimum value, and calculate a velocity value of the intermediate point; and
(65) an interpolation point calculating unit 34 configured to determine whether a parameter u corresponding to an interpolation point has entered the acceleration sensitive interval, and accelerate from a side point of the acceleration sensitive interval taken as a start point to the intermediate point and decelerate from the intermediate point to another side point of the acceleration sensitive interval taken as an end point when the parameter u corresponded by the interpolation point is determined to have entered the acceleration sensitive interval, wherein an acceleration of the intermediate point is 0.
(66) Referring to
(67) The numerical control system 71 is configured to obtain numerical control machining route data with a NURBS curve; obtain an acceleration a.sub.i within a parameter step length u.sub.i on the NURBS curve; compare the acceleration a.sub.i of everywhere of the NURBS curve with a maximum allowable acceleration to determine an acceleration sensitive point and determine an acceleration sensitive interval based on the determined acceleration sensitive point; determine an intermediate point of the acceleration sensitive interval as a demarcation point of the acceleration and the deceleration within the sensitive interval; calculate a velocity value of the intermediate point as a target velocity; and plan the acceleration and the deceleration of the acceleration sensitive interval based on the target velocity to obtain the numerical control machining route data with the planned NURBS curve and transmit the numerical control machining route data with the planned NURBS curve to the servo motor 72.
(68) In particular, the numerical control system 71 may plan the numerical control machining route data using the embodiment of
(69) The servo motor 72 receives the numerical control machining route data with the planned NURBS curve, and controls the execution component 73 to perform numerical control machining according to the received numerical control machining route data, such that the execution component 73 performs the machining according to the planned numerical control machining route. Where, the execution component 73 can be an industrial robot, a machining tool, and the like for machining.
(70) The present disclosure provides a method and device for planning curve velocity based on NURBS curve interpolation as well as a numerical control machining route data processing method using NURBS curve interpolation velocity planning, which redo S type velocity planning by predicting the acceleration sensitive points using a maximum acceleration allowed by the system in the acceleration sensitive interval. As a result, NURBS interpolation can be accelerated and decelerated in strict accordance with the new velocity curve while there is no necessary to worry about the velocity and the acceleration to beyond limits. In addition, since the new velocity curve deviates from the original maximum allowable velocity curve only at the acceleration sensitive point, the machining efficiency is maximized under the constraints of the velocity and the acceleration. At the same time, the algorithm can interpolate at one time without backtracking and without necessary to wait for the interpolation results of any side, hence the computation is light and the real-time performance of interpolation is guaranteed.
(71) The foregoing is merely an embodiment of the present disclosure, which is not for limiting the scope of the present disclosure. Any equivalent structure or process transformation based on the specification and the drawings of the present disclosure, or direct or indirect applications in other related arts, are all included in the protection scope of the present disclosure.