[go: up one dir, main page]

CN101907876B - Command point shaping, compressing and interpolating method suitable for numerical control device - Google Patents

Command point shaping, compressing and interpolating method suitable for numerical control device Download PDF

Info

Publication number
CN101907876B
CN101907876B CN 201010185807 CN201010185807A CN101907876B CN 101907876 B CN101907876 B CN 101907876B CN 201010185807 CN201010185807 CN 201010185807 CN 201010185807 A CN201010185807 A CN 201010185807A CN 101907876 B CN101907876 B CN 101907876B
Authority
CN
China
Prior art keywords
interpolation
points
point
mrow
interpolation point
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN 201010185807
Other languages
Chinese (zh)
Other versions
CN101907876A (en
Inventor
于东
张晓辉
耿聪
洪海涛
郑飂默
韩文业
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenyang Zhongke Cnc Technology Co ltd
Original Assignee
SHENYANG HIGH-END COMPUTER NUMERICAL CONTROL TECHNOLOGY Co Ltd
Shenyang Institute of Computing Technology of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by SHENYANG HIGH-END COMPUTER NUMERICAL CONTROL TECHNOLOGY Co Ltd, Shenyang Institute of Computing Technology of CAS filed Critical SHENYANG HIGH-END COMPUTER NUMERICAL CONTROL TECHNOLOGY Co Ltd
Priority to CN 201010185807 priority Critical patent/CN101907876B/en
Publication of CN101907876A publication Critical patent/CN101907876A/en
Application granted granted Critical
Publication of CN101907876B publication Critical patent/CN101907876B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Numerical Control (AREA)

Abstract

The invention relates to a command point shaping, compressing and interpolating method suitable for a numerical control device. The method comprises the following steps of: inserting an arc which has a distance with the middle point of a tolerance set by the numerical control device and is tangential with segments of adjacent command points to the middle point of every three adjacent command points when a numerical control processing procedure judges that any three adjacent command points on a processed curve surface meet a continuous processing condition, wherein the tangential points are used as interpolation points; trimming the interpolation points to reduce calculation errors and rounding errors in the process of reckoning the interpolation points; selecting a characteristic interpolation point through judging the bending directions of processing paths of all the interpolation points; fitting by using a continuous polynomial spline curve with a second derivative to generate a smooth curve; approximately calculating the interpolation points of a current interpolation period and sending the positions of the interpolation points to a servo system of the numerical control device; and driving a servo motor to move. The invention furthest improves the processing efficiency and reduces the influences of the calculation errors and the rounding errors on the processing precision and the processed surface smoothness.

Description

Instruction point shaping, compressing and interpolating method suitable for numerical control device
Technical Field
The invention relates to a numerical control machining technology of a complex molded surface, in particular to an instruction point shaping, compressing and interpolating method suitable for a numerical control device.
Background
Complex surfaces are widely used in the design of mold cavities, automotive coverings and aerospace components, however, high speed, high precision and high surface quality machining of complex surfaces has been a difficult point of research. In the numerical control machining, in order to mill a complete complex surface and detect collision in real time, a cam (computed tomography) system generally uses a large number of micro-planes to approximate the complex surface generated by the design of a cad (computer aided design) system, as shown in fig. 1, and covers the polyhedrons with a series of tool paths within a specific tolerance range, so as to finally generate a numerical control machining program consisting of a large number of command points.
When the numerical control device adopts a traditional interpolation method, namely interpolation is carried out on a straight line segment formed by adjacent instruction points, frequent jump of acceleration and extension of processing time are inevitably caused. In addition, in the conventional interpolation method, the command points obtained by the numerical control device are all assumed to be exactly located on the tool path curve (hereinafter, referred to as a desired curve) desired by the CAM system, and are processed. In practice, however, in order for a CAM system to increase the step size and avoid successive over-or under-cut points, the command points typically are not all exactly on the desired tool path curve, but rather are within the inner and outer tolerance bands of the desired curve, as shown in FIG. 2. In addition, the CAM system has a calculation error and a rounding error in the process of generating the instruction point, so that the high-speed and high-precision machining of a complex profile is difficult to realize by adopting the conventional interpolation method.
Disclosure of Invention
Aiming at the problem that the prior art cannot meet the high-speed and high-precision machining requirements of a complex profile, the invention aims to provide the instruction point shaping, compressing and interpolating method which is high in machining efficiency and machining precision and is suitable for the numerical control device.
In order to solve the technical problems, the invention adopts the technical scheme that:
the invention relates to an instruction point shaping, compressing and interpolating method suitable for a numerical control device, which comprises the following steps of:
identification of continuous tiny line segment processing area: judging whether any three adjacent instruction points on the processed curved surface meet continuous processing conditions according to the read numerical control processing program;
estimation of interpolation point: when any adjacent three instruction points on the processed curved surface meet the continuous processing condition, inserting an arc which has a distance with the middle point which is a set tolerance of the numerical control device and is tangent with a line segment between the adjacent instruction points into the middle point of every adjacent three instruction points, wherein the tangent point is used as an interpolation point which is closer to the expected curve than the instruction point;
trimming of interpolation points: trimming the interpolation points obtained in the steps to reduce the calculation error and the rounding error in the interpolation point presumption process and enable the processing path to be smoother;
selecting characteristic interpolation points: selecting characteristic interpolation points by judging the bending direction of the processing path at each interpolation point of the processing path;
fitting of spline curve: fitting a continuous polynomial spline curve having a second derivative to the characteristic interpolation points to generate a smooth curve;
interpolation of spline curve: and (4) approximately calculating the interpolation point of the current interpolation period on the smooth curve, and sending the position of the interpolation point to a servo system of the numerical control device to drive a servo motor to move.
The method for judging whether any three adjacent instruction points on the processed curved surface meet the continuous processing condition adopts a double-chord high error method, which specifically comprises the following steps:
calculating the distance between any three adjacent instruction points on the processed curved surface;
calculating the double-chord height error according to the arc segment and the distance between the adjacent command points;
if the calculated double-chord height error is smaller than the maximum chord height error set by the numerical control device, the three instruction points meet continuous processing conditions;
and if the calculated double-chord height error is not smaller than the maximum chord height error set by the numerical control device, the continuous processing conditions are not satisfied among the three instruction points.
And (3) trimming the interpolation point by adopting a least square method, wherein the formula is as follows:
<math><mrow> <mfenced open='{' close=''> <mtable> <mtr> <mtd> <mfenced open='' close=''> <mtable> <mtr> <mtd> <msub> <mi>O</mi> <mi>k</mi> </msub> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msub> <mi>Q</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msub> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msub> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>k</mi> <mo>&prime;</mo> </msubsup> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msubsup> <mi>O</mi> <mi>i</mi> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>k</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msubsup> <mi>O</mi> <mi>i</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> </mtd> <mtd> <mfenced open='' close=''> <mtable> <mtr> <mtd> <mrow> <mo>(</mo> <mn>1</mn> <mo>&le;</mo> <mi>i</mi> <mo>&le;</mo> <mi>n</mi> <mo>-</mo> <mn>4</mn> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <mo>(</mo> <mn>4</mn> <mo>&le;</mo> <mi>k</mi> <mo>&le;</mo> <mi>n</mi> <mo>-</mo> <mn>4</mn> <mo>)</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>9</mn> <mo>)</mo> </mrow> </mrow></math>
wherein:
Qi(u)=aiu3+biu2+ciu+di (ui≤u≤ui+4) (5)
ai、bi、ci、difor successive interpolation points Qi、Qi+1、Qi+2、Qi+3And Qi+4Curve Q obtained by fitting with least squares penaltyiCoefficient vector of (u), uiAnd ui+4Are respectively interpolated points QiAnd Qi+4Corresponding parameter value, OkIs an interpolation point OkThe corrected value.
The selection process of the characteristic interpolation point comprises the following steps:
marking the initial interpolation point O1For the characteristic interpolation point in the current continuous tiny line segment processing area, and calculating the initial interpolation point O1And an interpolation point O adjacent thereto2Is processed to a pilot vector O'1And O'2Cross product between to obtain vector v12
Judging the subscript j of the interpolation point to be calculated and the number n of the interpolation points, if j is less than n, calculating the interpolation point Oj-1And OjIs processed to a pilot vector O'j-1And O'jCross product between to obtain vector vj-1j
Calculating the vector vj-2j-1And vj-1jAngle alpha therebetweenjIf α isjIf j is less than 90 degrees, j is j +1, and the size step of judging the subscript j of the interpolation point to be calculated currently and the number n of the interpolation points is carried out;
if α isjNot less than 90 DEG, an interpolation point O is markedjAs a characteristic interpolation point, j is j +1, and interpolation point O is set asj-1As a new initial interpolation point, switching to a step of marking the initial interpolation point O1 as a characteristic interpolation point in the processed curved surface meeting the continuous processing condition;
if j is n, mark point OjFor the feature interpolation point, the feature interpolation point selection is ended.
The method also comprises a machining precision control step between the spline curve fitting step and the spline curve interpolation step, and the process is as follows:
inputting interpolation points between two adjacent characteristic interpolation points and a spline curve formed by fitting;
calculating an interpolation point O between two adjacent characteristic interpolation pointsmThe distance L between the corresponding spline curve is not greater than the distance L of the numerical control systemWhen the maximum profile deviation is set, the spline curve is explained at the interpolation point OmThe requirement of processing precision is met;
taking and interpolating point OmAdjacent next interpolation point Om+1Judging whether all interpolation points are completely taken;
if all the interpolation points are taken out, judging all the interpolation points Om+1Whether the requirements of machining precision are met;
if the distance L does not meet the machining precision requirement, finding out an interpolation point O corresponding to the maximum value in the distance LsTaking the interpolation point as a new characteristic interpolation point between the two adjacent characteristic interpolation points;
fitting a new spline curve by using the new characteristic interpolation points to replace the original spline curve, and continuously inputting interpolation points between two adjacent characteristic interpolation points and the spline curve to be synthesized;
if the interpolation points are not completely taken, the calculation is switched to the calculation of the interpolation point O between two adjacent characteristic interpolation pointsmA distance L step from the corresponding spline curve;
when L is larger than the maximum contour deviation preset by the numerical control system, the spline curve is shown at the interpolation point OmIf the position does not meet the machining precision requirement, recording the serial number of the current interpolation point and the distance from the current interpolation point to the spline curve, and continuously taking the interpolation point OmAdjacent next interpolation point Om+1And (5) carrying out the following steps.
The invention has the following beneficial effects and advantages:
1. the processing efficiency is high. The calculation of the interpolation points of the method is carried out on the smooth curve, so that the switching speed between the adjacent interpolation points is greatly improved, the time required by processing is greatly shortened, and the processing efficiency is improved to the maximum extent.
2. The processing precision is high. The method of the present invention can reduce the influence of the tolerance between the command point and the desired curve on the machining accuracy by presuming the interpolation point closer to the desired curve than the command point, and can reduce the influence of the calculation error and the rounding error on the machining accuracy and the machined surface finish by trimming the interpolation point.
3. The surface processing quality is high. The method can fit the instruction points in the continuous tiny line segment processing area into a smooth curve with C2 continuity, thereby eliminating the break angle between adjacent line segments and improving the processing quality of the surface of the workpiece.
Drawings
FIG. 1 is a schematic diagram illustrating the conversion of an original curved surface and an approximate curved surface in the prior art;
FIG. 2 is a diagram illustrating a desired curve and internal and external tolerances in the prior art;
FIG. 3 is a flow chart of the method of the present invention;
FIG. 4 is a schematic diagram of double chord height error determination;
FIG. 5 is a schematic diagram of interpolation point estimation;
FIG. 6 is a schematic diagram illustrating interpolation point crossing;
FIG. 7 is a diagram of feature interpolation point selection;
FIG. 8 is a flow chart of a feature interpolation point selection process;
FIG. 9 is a schematic radial plot of a fit of feature interpolated points;
FIG. 10 is a flow chart of machining accuracy control;
FIG. 11 is a path diagram of a curved surface to be processed;
FIG. 12a is a velocity map of a process using a conventional interpolation method;
FIG. 12b is a velocity map of a process using a smooth interpolation algorithm;
FIG. 12c is a graph of processing speed using the method of the present invention;
FIG. 13a is a comparison of a conventional interpolation method with an original model;
FIG. 13b is a comparison of the original model with the smooth interpolation algorithm;
FIG. 13c is a graph comparing the method of the present invention with the original model;
FIG. 14a is a diagram illustrating the surface effect of a sample machined by a conventional interpolation method;
FIG. 14b is a drawing of the effect of the machined surface of the sample using the smooth interpolation algorithm;
FIG. 14c is a diagram showing the surface effect of the sample workpiece processed by the method of the present invention.
Detailed Description
The method of the present invention will be described in further detail with reference to the accompanying drawings.
As shown in fig. 3, the command point shaping, compressing and interpolating method for a numerical control device according to the present invention includes the steps of:
identification of continuous tiny line segment processing area: judging whether any three adjacent instruction points on the processed curved surface meet continuous processing conditions according to the read numerical control processing program;
estimation of interpolation point: when any adjacent three instruction points on the processed curved surface meet the continuous processing condition, inserting an arc which has a distance with the middle point which is a set tolerance of the numerical control device and is tangent with a line segment between the adjacent instruction points into the middle point of every adjacent three instruction points, wherein the tangent point is used as an interpolation point which is closer to the expected curve than the instruction point;
trimming of interpolation points: trimming the interpolation points obtained in the steps to reduce the calculation error and the rounding error in the interpolation point presumption process and enable the processing path to be smoother;
selecting characteristic interpolation points: selecting characteristic interpolation points by judging the bending direction of the processing path at each interpolation point of the processing path;
fitting of spline curve: fitting the n characteristic interpolation points by using an n-1 section polynomial spline curve with continuous second derivative to generate a smooth curve;
interpolation of spline curve: and (4) approximately calculating the interpolation point of the current interpolation period on the smooth curve, and sending the position of the interpolation point to a servo system of the numerical control device to drive a servo motor to move.
Step one, the specific process of analyzing the processing path is as follows:
for a given numerical control machining program, whether continuous machining conditions are met between any three adjacent instruction points is judged through a double-chord height error method, and therefore the instruction points in the numerical control machining program are divided into a discontinuous micro-line segment machining area and a continuous micro-line segment machining area. As shown in FIG. 4, for three instruction points P in arbitrary orderi-1、PiAnd Pi+1,Li-1iAnd Lii+1Are respectively an instruction point Pi-1And PiAnd PiAnd Pi+1Distance between, δ1And delta2Are respectively over-command points Pi-1、PiAnd Pi+1Arc segment and line segment Pi-1PiAnd PiPi+1The generated double chord height error is R which is three command points Pi-1、PiAnd Pi+1The radius of the determined circle is determined,
Figure GSA00000119639600051
is three instruction points Pi-1、PiAnd Pi+1Two command points P on the determined circlei-1、PiHalf of the central angle corresponding to the middle minor arc,
Figure GSA00000119639600052
is three instruction points Pi-1、PiAnd Pi+1Two command points P on the determined circlei、Pi+1Half of central angle corresponding to middle minor arc, theta is vector
Figure GSA00000119639600053
Andthe included angle therebetween. The value can be calculated by the following formula:
Figure GSA00000119639600055
if the calculated double chord height error delta1And delta2Are all smaller than the maximum chord height error delta set by the numerical control devicecmaxThen, the instruction point P is describedi-1、PiAnd Pi+1The continuous processing condition is met; if the calculated double chord height error delta1And delta2One is larger than the maximum chord height error delta set by the numerical control devicecmaxThen, the instruction point P is describedi-1、PiAnd Pi+1The condition of continuous processing is not satisfied. Therefore, the instruction points in the numerical control machining program can be divided into a discontinuous micro-line segment machining area and a continuous micro-line segment machining area by judging every three adjacent instruction points.
Step two, the specific process of estimating the interpolation point is as follows:
for any one continuous micro-line segment processing area, at the middle point formed by continuous three instruction points, an arc which has a tolerance set for the numerical control system and is tangent to two line segments with the adjacent instruction points is inserted to estimate an interpolation point which is closer to the expected curve than the instruction point. As shown in fig. 5, from the instruction point Pi-1、PiAnd Pi+1Two adjacent small line segments Pi-1PiAnd PiPi+1At the corner of which a distance corner command point P is insertediTo a tolerance deltatmaxSize and line segment Pi-1PiAnd PiPi+1Tangent to point QiAnd Qi+1After the arc, the following equation can be obtained according to the geometrical knowledge:
<math><mrow> <mfenced open='{' close=''> <mtable> <mtr> <mtd> <mi>L</mi> <mo>=</mo> <mfrac> <mrow> <mi>sin</mi> <mfrac> <mi>&beta;</mi> <mn>2</mn> </mfrac> </mrow> <mrow> <mn>1</mn> <mo>-</mo> <mi>cos</mi> <mfrac> <mi>&beta;</mi> <mn>2</mn> </mfrac> </mrow> </mfrac> <msub> <mi>&delta;</mi> <mrow> <mi>t</mi> <mi>max</mi> </mrow> </msub> </mtd> </mtr> <mtr> <mtd> <mi>R</mi> <mo>=</mo> <mfrac> <mrow> <mi>cos</mi> <mfrac> <mi>&beta;</mi> <mn>2</mn> </mfrac> </mrow> <mrow> <mn>1</mn> <mo>-</mo> <mi>cos</mi> <mfrac> <mi>&beta;</mi> <mn>2</mn> </mfrac> </mrow> </mfrac> <msub> <mi>&delta;</mi> <mrow> <mi>t</mi> <mi>max</mi> </mrow> </msub> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>2</mn> <mo>)</mo> </mrow> </mrow></math>
wherein L is a tangent point and an instruction point PiBeta is a vector of
Figure GSA00000119639600062
Andthe included angle therebetween. Under the condition that the set tolerance of the numerical control system is certain, the tangent point Q can be found by combining the graph 2 and the graph 5iAnd Qi+1Ratio instruction point PiCloser to the desired curve. Therefore, after the numerical control system sets the tolerance, the point Q can be taken offiAnd Qi+1As a point of instruction PiThe corresponding interpolation point. At this time, tangent point QiAnd Qi+1The coordinates of (a) can be written as:
Q i = L L i - 1 i P i - 1 + L i - 1 i - L L i - 1 i P i Q i + 1 = L ii + 1 - L L ii + 1 P i + L L ii + 1 P i + 1 - - - ( 3 )
wherein L isi-1iAnd Lii+1Are respectively line segment Pi-1PiAnd PiPi+1Length of (2)And a point P of instructioni-1、PiAnd Pi+1The coordinates of (a) can be obtained from a numerical control machining program. As shown in FIG. 6, to prevent the intersection of the interpolation points corresponding to the adjacent command points due to the too short line segment, the tangent point and the command point PiThe distance L between the adjacent line segments should be constrained by the length of the adjacent line segments, in addition to the tolerance set by the system:
<math><mrow> <mi>L</mi> <mo>&le;</mo> <mi>min</mi> <mrow> <mo>(</mo> <mfrac> <msub> <mi>L</mi> <mrow> <mi>i</mi> <mo>-</mo> <mn>1</mn> <mi>i</mi> </mrow> </msub> <mn>2</mn> </mfrac> <mo>,</mo> <mfrac> <msub> <mi>L</mi> <mrow> <mi>ii</mi> <mo>+</mo> <mn>1</mn> </mrow> </msub> <mn>2</mn> </mfrac> <mo>)</mo> </mrow> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>4</mn> <mo>)</mo> </mrow> </mrow></math>
at this time, the interpolation point corresponding to each of the remaining instruction points except the first and last instruction points in the continuous minute line segment processing area can be calculated by the above-described method, and the first and last instruction points can take themselves as the interpolation points corresponding thereto.
Step three, the trimming of the interpolation point specifically comprises the following steps:
the interpolation points are estimated from the tolerances set by the command points and numerical control system, and therefore, the distance from each interpolation point to a desired curve is much larger than the distances from other interpolation points to desired curves. Therefore, it is obviously undesirable to generate a smooth curve machining path directly by fitting the interpolated points. In order to reduce the calculation error and rounding error in the interpolation point estimation process and to make the curve fitted to the interpolation points smoother, the present embodiment uses a least square method based on cubic polynomial to trim every five consecutive interpolation points.
Before trimming the interpolation points, each interpolation point needs to be parameterized to ensure that each interpolation point has a corresponding parameter value. In order to enable the parameter value corresponding to each interpolation point to reflect the turning condition of the line segment formed by the interpolation points, the method adopts a centripetal parameterization method to parameterize the interpolation points.
After parameterizing each interpolation point, take u3,u2U, 1 as a set of orthogonal basis functions of a cubic polynomial space, at which arbitrary five successive interpolation points Q are presenti、Qi+1、Qi+2、Qi+3And Qi+4Fitted curve Q betweeni(u) can be written as:
Qi(u)=aiu3+biu2+ciu+di(ui≤u≤ui+4) (5)
wherein a isi、bi、ci、diIs a fitted curve QiCoefficient vector of (u) (vector dimension is same as number of motion axes), uiAnd ui+4Interpolation of points QiAnd Qi+4The corresponding parameter value. At this time, the point Q is interpolatedi、Qi+1、Qi+2、Qi+3、Qi+4To QiHaving a parameter value u on (u)i、ui+1、ui+2、ui+3、ui+4Point Q ofi(ui)、Qi(ui+1)、Qi(ui+2)、Qi(ui+3) The sum of the squares Ji of the distances between can be written as:
<math><mrow> <msub> <mi>J</mi> <mi>i</mi> </msub> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>k</mi> <mo>=</mo> <mi>i</mi> </mrow> <mrow> <mi>i</mi> <mo>+</mo> <mn>4</mn> </mrow> </munderover> <msup> <mrow> <mo>|</mo> <msub> <mi>Q</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <msub> <mi>Q</mi> <mi>k</mi> </msub> <mo>|</mo> </mrow> <mn>2</mn> </msup> <mo>=</mo> <msub> <mi>J</mi> <mi>ix</mi> </msub> <mo>+</mo> <msub> <mi>J</mi> <mi>iy</mi> </msub> <mo>+</mo> <msub> <mi>J</mi> <mi>iz</mi> </msub> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>6</mn> <mo>)</mo> </mrow> </mrow></math>
wherein,
<math><mrow> <mfenced open='{' close=''> <mtable> <mtr> <mtd> <msub> <mi>J</mi> <mi>ix</mi> </msub> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>k</mi> <mo>=</mo> <mi>i</mi> </mrow> <mrow> <mi>i</mi> <mo>+</mo> <mn>4</mn> </mrow> </munderover> <msup> <mrow> <mo>|</mo> <msub> <mi>Q</mi> <mi>ix</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <msub> <mi>X</mi> <mi>k</mi> </msub> <mo>|</mo> </mrow> <mn>2</mn> </msup> </mtd> </mtr> <mtr> <mtd> <msub> <mi>J</mi> <mi>iy</mi> </msub> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>k</mi> <mo>=</mo> <mi>i</mi> </mrow> <mrow> <mi>i</mi> <mo>+</mo> <mn>4</mn> </mrow> </munderover> <msup> <mrow> <mo>|</mo> <msub> <mi>Q</mi> <mi>iy</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <msub> <mi>Y</mi> <mi>k</mi> </msub> <mo>|</mo> </mrow> <mn>2</mn> </msup> </mtd> </mtr> <mtr> <mtd> <msub> <mi>J</mi> <mi>iz</mi> </msub> <mo>=</mo> <munderover> <mi>&Sigma;</mi> <mrow> <mi>k</mi> <mo>=</mo> <mi>i</mi> </mrow> <mrow> <mi>i</mi> <mo>+</mo> <mn>4</mn> </mrow> </munderover> <msup> <mrow> <mo>|</mo> <msub> <mi>Q</mi> <mi>iz</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>-</mo> <msub> <mi>Z</mi> <mi>k</mi> </msub> <mo>|</mo> </mrow> <mn>2</mn> </msup> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>7</mn> <mo>)</mo> </mrow> </mrow></math>
in the formula, Qix(uk)、Qiy(uk)、Qix(uk) Are respectively QiHaving a parameter value u on (u)kPoint Q ofi(uk) Coordinate values in the X, Y, Z directions, Xk、Yk、ZkAre respectively interpolated points QkCoordinate values in the X, Y, Z directions, Jix、Jiy、JizAre respectively interpolated points Qi、Qi+1、Qi+2、Qi+3、Qi+4To curve with parameter value ui、ui+1、ui+2、ui+3、ui+4Point Q ofi(ui)、Qi(ui+1)、Qi(ui+2)、Qi(ui+3) The sum of the squares of the distances in the X, Y, Z directions. It can be found from equations (6) and (7) that J is to be expressediTo minimize, J should beix、JiyAnd JizAre all minimal. To this end, Jix、JiyAnd JizThe partial derivatives of (c) must satisfy the following condition:
<math><mrow> <mfenced open='{' close=''> <mtable> <mtr> <mtd> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>ix</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>a</mi> </mrow> <mi>ix</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>ix</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>b</mi> </mrow> <mi>ix</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>ix</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>c</mi> </mrow> <mi>ix</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>ix</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>d</mi> </mrow> <mi>ix</mi> </msub> </mfrac> <mo>=</mo> <mn>0</mn> </mtd> </mtr> <mtr> <mtd> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iy</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>a</mi> </mrow> <mi>iy</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iy</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>b</mi> </mrow> <mi>iy</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iy</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>c</mi> </mrow> <mi>iy</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iy</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>d</mi> </mrow> <mi>iy</mi> </msub> </mfrac> <mo>=</mo> <mn>0</mn> </mtd> </mtr> <mtr> <mtd> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iz</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>a</mi> </mrow> <mi>iz</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iz</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>b</mi> </mrow> <mi>iz</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iz</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>c</mi> </mrow> <mi>iz</mi> </msub> </mfrac> <mo>=</mo> <mfrac> <msub> <mrow> <mo>&PartialD;</mo> <mi>J</mi> </mrow> <mi>iz</mi> </msub> <msub> <mrow> <mo>&PartialD;</mo> <mi>d</mi> </mrow> <mi>iz</mi> </msub> </mfrac> <mo>=</mo> <mn>0</mn> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>8</mn> <mo>)</mo> </mrow> </mrow></math>
interpolating point Qi、Qi+1、Qi+2、Qi+3And Qi+4And a parameter value u corresponding to the coordinate valuei、ui+1、ui+2、ui+3And ui+4After substituting equation (8), the calculation is performedCurve Qi(u) coefficient vectors in the X, Y and Z directions, respectively. In calculating QiAfter the expression (u), there is a parameter value ui、ui+1、ui+2、ui+3And ui+4And the first and second derivatives at that point can be written as:
<math><mrow> <mfenced open='{' close=''> <mtable> <mtr> <mtd> <mfenced open='' close=''> <mtable> <mtr> <mtd> <msub> <mi>O</mi> <mi>k</mi> </msub> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msub> <mi>Q</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msub> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msub> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> </msub> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>k</mi> <mo>&prime;</mo> </msubsup> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msubsup> <mi>O</mi> <mi>i</mi> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> <mo>&prime;</mo> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>k</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mo>=</mo> <mfrac> <mn>1</mn> <mn>3</mn> </mfrac> <mrow> <mo>(</mo> <msubsup> <mi>O</mi> <mi>i</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>O</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>1</mn> </mrow> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>+</mo> <msubsup> <mi>Q</mi> <mrow> <mi>i</mi> <mo>+</mo> <mn>2</mn> </mrow> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> <mrow> <mo>(</mo> <msub> <mi>u</mi> <mi>k</mi> </msub> <mo>)</mo> </mrow> <mo>)</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> </mtd> <mtd> <mfenced open='' close=''> <mtable> <mtr> <mtd> <mrow> <mo>(</mo> <mn>1</mn> <mo>&le;</mo> <mi>i</mi> <mo>&le;</mo> <mi>n</mi> <mo>-</mo> <mn>4</mn> <mo>)</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <mo>(</mo> <mn>4</mn> <mo>&le;</mo> <mi>k</mi> <mo>&le;</mo> <mi>n</mi> <mo>-</mo> <mn>4</mn> <mo>)</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>9</mn> <mo>)</mo> </mrow> </mrow></math>
in the formula, OkIs an interpolation point OkThe corrected value. If there are n interpolation points in the current continuous tiny line segment processing area, divide the first three interpolation points Q1、Q2、Q3And the last three interpolation points qn-2、Qn-1QnThe trimmed new interpolation point and the first and second derivative vectors at the point need to be considered separately, and the trimmed new interpolation points and the first and second derivative vectors at the point of the rest interpolation points can be taken as the average values of the point with the parameter value corresponding to the interpolation point and the first and second derivative vectors at the point on the middle three of the five curves approximating the interpolation point.
Step four, selecting the characteristic interpolation points specifically comprises the following steps:
for the same continuous tiny line segment processing area, if the processing path designated by a plurality of interpolation points is bent along the same direction, the requirement of processing precision can be met only by an expected curve formed by fitting the geometric information of the first and last interpolation points of the processing path. Therefore, for the purpose of compressing the number of interpolation points and reducing the number of times of fitting, it is possible to find an interpolation point where the bending direction of the processing path changes in advance before fitting the interpolation points, and define such an interpolation point as a characteristic interpolation point.
As shown in fig. 7 and 8, n corrected interpolation point values O1、O2...、On-1And OnAnd finding out a characteristic interpolation point where the bending direction of the processing path changes by the constructed continuous tiny line segment processing area through the following steps:
(1) marking the initial interpolation point O1For the characteristic interpolation point in the current continuous tiny line segment processing area, and calculating the initial interpolation point O1And an interpolation point O adjacent thereto2Is processed to a pilot vector O'1And O'2Cross product between to obtain vector v12
(2) Judging the subscript j of the interpolation point to be calculated and the number n of the interpolation points, if j is less than n, calculating the interpolation point Oj-1And OjIs processed to a pilot vector O'j-1And O'jCross product between to obtain vector vj-1j
(3) Calculating the vector vj-2j-1And vj-1jAngle alpha therebetweenjIf α isjIf j is less than 90 degrees, j is j +1, and the step (2) is carried out to judge the size of the subscript j of the interpolation point to be calculated currently and the number n of the interpolation points;
(4) if α isjNot less than 90 DEG, an interpolation point O is markedjAs a characteristic interpolation point, j is j +1, and interpolation point O is set asj-1As a new initial interpolation point, go to step (1) to mark the initial interpolation point O1Characteristic interpolation points in the processed curved surface which meet continuous processing conditions;
(5) if j is n, mark point OjFor the feature interpolation point, the feature interpolation point selection is ended.
Step five, the fitting process of the characteristic interpolation points is as follows:
for N characteristic interpolation points in any continuous tiny line segment processing area, fitting can be carried out by using an N-1-segment quintic polynomial spline curve with continuous second derivative so as to achieve the purpose of generating a smooth curve. As shown in FIG. 9, the point O is interpolated for any two adjacent featuresiAnd OjBetween them by an interpolated point Oi+1、...、Oj-1Specified broken lineMachining path and passing feature interpolation point OiAnd OjSmooth curve O formed by fitting geometric informationk(u) wherein the curve O is smoothedkThe expression of (u) can be written as:
Ok(u)=Aku5+Bku4+Cku3+Dku2+Eku+Fk(u∈[ui,uj]) (10)
wherein A isk、Bk、Ck、Dk、EkAnd FkIs OkCoefficient vector of (u) (vector dimension equals number of motion axes), uiAnd ujRespectively being characteristic interpolation points OiAnd OjThe corresponding parameter value. O isk(u) there are 6 coefficient vectors, so 6 boundary conditions are needed to determine these coefficient vectors. To ensure Ok(u) passing the characteristic interpolation point OiAnd OjAnd satisfies C2 continuity with adjacent curves at the characteristic interpolation point, optionally the characteristic interpolation point OiAnd OjThe coordinate value and the first and second lead vectors are used as a spline curve Ok(u) boundary conditions, these boundary conditions being taken into Ok(u) the following equation is obtained:
<math><mrow> <mfenced open='[' close=']'> <mtable> <mtr> <mtd> <msubsup> <mi>u</mi> <mi>i</mi> <mn>5</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>i</mi> <mn>4</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>i</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>i</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <msub> <mi>u</mi> <mi>i</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> </mtr> <mtr> <mtd> <mn>5</mn> <msubsup> <mi>u</mi> <mi>i</mi> <mn>4</mn> </msubsup> </mtd> <mtd> <msubsup> <mrow> <mn>4</mn> <mi>u</mi> </mrow> <mi>i</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <msubsup> <mrow> <mn>3</mn> <mi>u</mi> </mrow> <mi>i</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <mn>2</mn> <msub> <mi>u</mi> <mi>i</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> <mtd> <mn>0</mn> </mtd> </mtr> <mtr> <mtd> <mn>20</mn> <msubsup> <mi>u</mi> <mi>i</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <mn>12</mn> <msubsup> <mi>u</mi> <mi>i</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <mn>6</mn> <msub> <mi>u</mi> <mi>i</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> <mtd> <mn>0</mn> </mtd> <mtd> <mn>0</mn> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>u</mi> <mi>j</mi> <mn>5</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>j</mi> <mn>4</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>j</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <msubsup> <mi>u</mi> <mi>j</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <msub> <mi>u</mi> <mi>j</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> </mtr> <mtr> <mtd> <mn>5</mn> <msubsup> <mi>u</mi> <mi>j</mi> <mn>4</mn> </msubsup> </mtd> <mtd> <msubsup> <mrow> <mn>4</mn> <mi>u</mi> </mrow> <mi>j</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <msubsup> <mrow> <mn>3</mn> <mi>u</mi> </mrow> <mi>j</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <mn>2</mn> <msub> <mi>u</mi> <mi>j</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> <mtd> <mn>0</mn> </mtd> </mtr> <mtr> <mtd> <mn>20</mn> <msubsup> <mi>u</mi> <mi>j</mi> <mn>3</mn> </msubsup> </mtd> <mtd> <mn>12</mn> <msubsup> <mi>u</mi> <mi>j</mi> <mn>2</mn> </msubsup> </mtd> <mtd> <msub> <mrow> <mn>6</mn> <mi>u</mi> </mrow> <mi>j</mi> </msub> </mtd> <mtd> <mn>1</mn> </mtd> <mtd> <mn>0</mn> </mtd> <mtd> <mn>0</mn> </mtd> </mtr> </mtable> </mfenced> <mfenced open='[' close=']'> <mtable> <mtr> <mtd> <msub> <mi>A</mi> <mi>k</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msub> <mi>B</mi> <mi>k</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msub> <mi>C</mi> <mi>k</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msub> <mi>D</mi> <mi>k</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msub> <mi>E</mi> <mi>k</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msub> <mi>F</mi> <mi>k</mi> </msub> </mtd> </mtr> </mtable> </mfenced> <mo>=</mo> <mfenced open='[' close=']'> <mtable> <mtr> <mtd> <msub> <mi>O</mi> <mi>i</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>i</mi> <mo>&prime;</mo> </msubsup> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>i</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> </mtd> </mtr> <mtr> <mtd> <msub> <mi>O</mi> <mi>j</mi> </msub> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>j</mi> <mo>&prime;</mo> </msubsup> </mtd> </mtr> <mtr> <mtd> <msubsup> <mi>O</mi> <mi>j</mi> <mrow> <mo>&prime;</mo> <mo>&prime;</mo> </mrow> </msubsup> </mtd> </mtr> </mtable> </mfenced> <mo>-</mo> <mo>-</mo> <mo>-</mo> <mrow> <mo>(</mo> <mn>11</mn> <mo>)</mo> </mrow> </mrow></math>
interpolating features by a point OiAnd OjCoordinate value of (d), corresponding parameter value uiAnd ujAnd a calculated first derivative vector O'iAnd O'jAnd a second derivative vector O ″)iAnd O ″)jWith the formula (11), the spline curve O can be calculatedkCoefficient of (u).
Step six, the calculation of the interpolation points comprises the following specific processes:
for the fitted curve O (u), a second-order Taylor expansion method is adopted to approximately calculate a parameter value u corresponding to the interpolation point of the ith interpolation periodiAt this time uiThe formula of (c) can be expressed by the following formula:
Figure GSA00000119639600102
wherein u isi-1The parameter value corresponding to the interpolation point of the i-1 th interpolation period, T is the interpolation period of the numerical control system, Vi-1And Ai-1The machining speed and acceleration, O' (u), planned for the i-1 th interpolation period, respectivelyi-1) And O' (u)i-1) Are each O (u) at ui-1The first and second derivative vectors of (c) can be calculated by their expressions. Introducing the planned processing speed and accelerationThe formula (12) can calculate the parameter value corresponding to the interpolation point of the current interpolation period, and the calculated parameter value is substituted into the expression of the expected curve to obtain the interpolation point of the current interpolation period.
In order to improve the processing precision, the method of the invention designs a processing precision control step between the step 5) and the step 6), and the specific process is as follows:
the method judges whether the spline curve formed by fitting meets the requirement of machining precision at the interpolation point by calculating the distance between the interpolation point and the corresponding curve point (the point of the expected curve with the parameter value corresponding to the interpolation point) in real time. And for the interpolation points which do not meet the machining precision requirement, the curve segment shape of the spline curve at the interpolation points is adjusted by adding new characteristic interpolation points, so that the fitted spline curve meets the machining precision requirement at all the interpolation points.
Interpolation points O for two adjacent features shown in FIG. 9iAnd OjThe processing precision of the spline curve at the interpolation point can be controlled by the following process, and the specific flow is shown in fig. 10:
(1) calculating a characteristic interpolation point OiAnd OjInterpolation point O betweenm(m starting from i + 1) to the corresponding spline Ok(um) A distance L between umIs an interpolation point OmThe corresponding parameter value. When L is less than or equal to emaxWhen (e)maxThe maximum profile deviation preset for the system) is transferred to the process (2); when L > emaxWhen the process is finished, the process (3) is switched to;
(2)L≤emaxillustrates a spline curve Ok(u) at the interpolation point OmMeets the requirement of processing precision. Judging the sizes of m and j, if m is less than j, describing the characteristic interpolation point OiAnd OjIf all interpolation points between the m and the m are not judged completely, adding 1 to the m and then switching to the process (1); if m is j, the characteristic interpolation point O is describediAnd OjAfter all interpolation points are judged, the process is switched to the process (4);
(3)L>emaxdescription curve segment Ok(u) at the interpolation point OmThe processing precision requirement is not met. And recording the value of m and the distance L, and judging the sizes of m and j. If m < j, the characteristic interpolation point O is specifiediAnd OjIf all interpolation points between the m and the m are not judged completely, adding 1 to the m and then switching to the process (1); if m is j, the characteristic interpolation point O is describediAnd OjAfter all interpolation points are judged, the process is switched to the process (4);
(4) and judging whether an m value is recorded. If no m value is recorded, curve segment O is illustratedk(u) at a characteristic interpolation point OiAnd OjAll the interpolation points between the two points meet the requirement of the processing precision, and the processing precision control is finished; if m is recorded, the curve segment O is illustratedk(u) at a characteristic interpolation point OiAnd OjFinding out the interpolation point O corresponding to the maximum value in L when the interpolation point does not meet the processing precisions(and curve segment O)k(u) interpolation point farthest away) and takes the interpolation point as a characteristic interpolation point OiAnd OjInterpolating points with new features, and going to the process (5);
(5) by interpolation of points O by featuresiAnd OsAnd OsAnd OjFitting a new spline curve Os-1(u) and Os(u) instead of Ok(u) as a characteristic interpolation point OiAnd OjThe new curve segment is formed, and the machining precision control is carried out again according to the process until the characteristic interpolation point OiAnd OjThe curve segment between meets the machining precision requirement at all the interpolation points.
The invention has the following execution effects:
the executing mechanism of the method adopts an Anduan Mechatolin-III bus and a sigma-2 servo and motor, the control machine tool is a three-axis numerical control milling machine, and the main parameters of the device are as follows:
CPU Pentium M-1.6GHz memory 512M hard disk 40G
The feed rate F is 3000m/min
Interpolation period T1 ms
Maximum acceleration Amax=500mm/s-2
Chord height error deltacmax=0.01mm
Tolerance deltatmax=0.01mm
Error of contour emax=0.01mm
In order to verify the effectiveness of the method, the complex profile shown in fig. 11 is actually processed by respectively adopting a traditional interpolation method, a smooth interpolation algorithm and the method, a processing path is generated by CAD/CAM software UG under the condition that the internal and external tolerance is set to be 0.03mm, as shown in fig. 11, and comparison and analysis are respectively carried out on the processing speed, the processing precision and the surface processing quality. Fig. 12a, 12b, and 12c show comparison graphs of the processing speeds of the above three methods, and fig. 13a, 13b, and 13c show comparison graphs of interpolation points and original models generated in the actual processing process of the above three methods; FIGS. 14a, 14b, and 14c are comparative graphs showing the machined surfaces of the sample pieces in the above three methods.
From the three figures above, it can be seen that:
1. compared with the traditional interpolation method, the method can greatly reduce the time required by the complex profile processing, and the processing time required by adopting the text algorithm and the smooth interpolation algorithm is not greatly different, as shown in fig. 12a, 12b and 12 c. The invention is mainly characterized in that when the method and the smooth interpolation algorithm are adopted, the calculation of interpolation points is carried out on a smooth curve, so that the switching speed between adjacent interpolation points is greatly improved, and the time required by processing is greatly shortened.
2. Compared with the traditional interpolation method and the smooth interpolation algorithm, the method can greatly reduce the number of over-cut points and under-cut points, as shown in fig. 13a, 13b and 13c, wherein the points with darker color gray levels are the over-cut points, and the points with lighter color gray levels are the under-cut points, and can effectively eliminate break angles between adjacent line segments and make the processed surface smoother, as shown in fig. 14a, 14b and 14 c. This is because the method generates a smooth curve by fitting an interpolation point closer to the CAM expected curve than the command point, thereby reducing the influence of the deviation between the command point and the expected curve on the machining accuracy and improving the workpiece surface machining accuracy.

Claims (4)

1. A command point shaping, compressing and interpolating method suitable for a numerical control device is characterized by comprising the following steps:
identification of continuous tiny line segment processing area: judging whether any three adjacent instruction points on the processed curved surface meet continuous processing conditions according to the read numerical control processing program;
estimation of interpolation point: when any three instruction points on the processed curved surface meet the continuous processing condition, inserting an arc which has a distance with the middle point which is a set tolerance of the numerical control device and is tangent with a line segment between the adjacent instruction points into the middle point of every adjacent three instruction points, wherein the tangent point is an interpolation point which is closer to the expected curve than the instruction point;
trimming of interpolation points: trimming the interpolation points obtained in the steps, reducing calculation errors and rounding errors in the interpolation point presumption process, and enabling the machining path to be smoother;
selecting characteristic interpolation points: selecting characteristic interpolation points by judging the bending direction of the processing path at each interpolation point of the processing path;
fitting of spline curve: fitting a continuous polynomial spline curve having a second derivative to the characteristic interpolation points to generate a smooth curve;
interpolation of spline curve: calculating the interpolation point of the current interpolation period approximately to the smooth curve, and sending the position of the interpolation point to a servo system of the numerical control device to drive a servo motor to move;
the method for judging whether any three adjacent instruction points on the processed curved surface meet the continuous processing condition or not adopts a double-chord height error method, which specifically comprises the following steps:
calculating the distance between any three adjacent instruction points on the processed curved surface;
calculating the double-chord height error according to the arc segment and the distance between the adjacent command points;
if the calculated double-chord height error is smaller than the maximum chord height error set by the numerical control device, the three instruction points meet continuous processing conditions;
if the calculated double-chord height error is not smaller than the maximum chord height error set by the numerical control device, the three instruction points meet continuous processing conditions;
and (3) trimming the interpolation point by adopting a least square method, wherein the formula is as follows:
Figure FDA0000086471410000011
wherein:
Qi(u)=aiu3+biu2+ciu+di(ui≤u≤ui+4) (5)
ai、bi、ci、difor successive interpolation points Qi、Qi+1、Qi+2、Qi+3And Qi+4Curve Q obtained by fittingiCoefficient vector of (u), uiAnd ui+4Are respectively interpolated points QiAnd Qi+4Corresponding parameter value, OkTo an interpolation point QkA corrected value;
the selection process of the characteristic interpolation point comprises the following steps:
marking the initial interpolation point O1For the characteristic interpolation point in the current continuous tiny line segment processing area, and calculating the initial interpolation point O1And always adjacent interpolation point O2Is processed to a pilot vector O'1And O'2Cross product between to obtain vector v12
Judging the subscript of the interpolation point to be calculated at present as j and the number n of the interpolation points, if j is less than n, calculating the interpolation point Oj-1And OjIs processed to a pilot vector O'j-1And O'jCross product between to obtain vector vj-1j
Calculating the vector vj-2j-1And vj-1jAngle alpha therebetweenjIf α isjIf j is less than 90 degrees, j is j +1, and the size step of judging the subscript j of the interpolation point to be calculated currently and the number n of the interpolation points is carried out;
if α isjNot less than 90 DEG, an interpolation point O is markedjAs a characteristic interpolation point, j is j +1, and interpolation point O is set asj-1As a new initial interpolation point, the mark is shifted to the initial interpolation point O1Interpolating points for the features in the processed curved surface satisfying the continuous processing conditions;
if j is n, mark point OjFor the feature interpolation point, the feature interpolation point selection is ended.
2. The command point shaping, compressing and interpolating method for a numerical control device as set forth in claim 1, wherein: the method also comprises a machining precision control step between the kernel of the spline curve and the interpolation step of the spline curve, and the process is as follows:
inputting interpolation points between two adjacent characteristic interpolation points and a spline curve formed by fitting;
calculating an interpolation point O between two adjacent characteristic interpolation pointsmThe distance between the point and the corresponding spline curve is L, and when L is not more than the maximum contour deviation preset by the numerical control system, the interpolation point O with the spline curve is indicatedmThe requirement of processing precision is met;
taking and interpolating point OmAdjacent next interpolation point Om+1Judging whether all interpolation points are completely taken;
if all the interpolation points are taken out, judging all the next interpolation points Om+1Whether the requirements of machining precision are met;
if the distance L does not meet the machining precision requirement, finding out an interpolation point O corresponding to the maximum value in the distance LsTaking the interpolation point as a new characteristic interpolation point between the two adjacent characteristic interpolation points;
and fitting a new spline curve by using the new characteristic interpolation points to replace the original spline curve, and continuously inputting interpolation points between two adjacent characteristic interpolation points and the spline curve formed by fitting.
3. The command point shaping, compressing and interpolating method for a numerical control device as set forth in claim 2, wherein: if the interpolation points are not completely taken, the calculation is switched to the calculation of the interpolation point O between two adjacent characteristic interpolation pointsmAnd L, distance between the corresponding spline curves.
4. The command point shaping, compressing and interpolating method for a numerical control device as set forth in claim 2, wherein:
when L is larger than the maximum profile difference preset by the numerical control system, the spline curve is shown at the interpolation point OmIf the position does not meet the machining precision requirement, recording the serial number of the current interpolation point and the distance from the current interpolation point to the spline curve, and continuously taking the interpolation point OmAdjacent next interpolation point Om+1And (5) carrying out the following steps.
CN 201010185807 2010-05-28 2010-05-28 Command point shaping, compressing and interpolating method suitable for numerical control device Active CN101907876B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201010185807 CN101907876B (en) 2010-05-28 2010-05-28 Command point shaping, compressing and interpolating method suitable for numerical control device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201010185807 CN101907876B (en) 2010-05-28 2010-05-28 Command point shaping, compressing and interpolating method suitable for numerical control device

Publications (2)

Publication Number Publication Date
CN101907876A CN101907876A (en) 2010-12-08
CN101907876B true CN101907876B (en) 2012-01-04

Family

ID=43263356

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201010185807 Active CN101907876B (en) 2010-05-28 2010-05-28 Command point shaping, compressing and interpolating method suitable for numerical control device

Country Status (1)

Country Link
CN (1) CN101907876B (en)

Families Citing this family (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102393679B (en) * 2011-10-14 2013-07-24 华中科技大学 Method for obtaining relative dynamic stiffness of multi-axis processing system and application thereof
CN102490083A (en) * 2011-11-15 2012-06-13 上海三一精机有限公司 Real-time display method for space profile track errors of numerical control device
CN102566500B (en) * 2011-11-24 2013-09-18 山东理工大学 Straight line segment approximation node-based numerical control system contour error control method
CN102837163B (en) * 2012-09-26 2014-08-06 卧龙电气集团股份有限公司 Manufacturing method of backward inclined fan blade of high efficiency motor
CN102929211B (en) * 2012-11-22 2014-06-18 南京航空航天大学 Optimized post-processing method for conic curve processing
CN103176428B (en) * 2013-04-16 2015-01-21 易兴 CNC (computerized numerical control) system interpolating algorithm based on spherical coordinates and device for realizing same
JP6068414B2 (en) * 2014-10-23 2017-01-25 ファナック株式会社 Numerical control device that can specify the shape of arcs and curved surfaces with small curvature
JP5926358B1 (en) 2014-11-28 2016-05-25 ファナック株式会社 Tool path curving method and curving device for ensuring shape error
JP6672702B2 (en) * 2015-10-29 2020-03-25 ブラザー工業株式会社 Control device, machine tool, control method, and computer program
CN108062073B (en) * 2016-11-08 2020-06-23 沈阳高精数控智能技术股份有限公司 Circular arc smooth compression interpolation method for high-quality machining
CN108073138B (en) * 2016-11-08 2020-08-11 沈阳高精数控智能技术股份有限公司 Elliptical arc smooth compression interpolation algorithm suitable for high-speed high-precision machining
CN109521731B (en) * 2017-09-19 2021-07-30 沈阳高精数控智能技术股份有限公司 G2 continuous Bezier tool path smoothing algorithm based on tolerance zone
CN107966953B (en) * 2017-11-24 2020-04-03 上海维宏电子科技股份有限公司 Method for processing turn-back line segment in numerical control machining track
CN108170094B (en) * 2017-12-12 2020-05-15 烟台大学 Method for smoothly compressing cutter path
CN109270892B (en) * 2018-08-31 2020-10-02 天津大学 Least square spiral line approximation algorithm of non-circular curve in numerical control machining
TWI716127B (en) * 2019-10-01 2021-01-11 東元電機股份有限公司 Robot and system for generating path interpolation command thereof
CN112621739B (en) * 2019-10-08 2022-03-15 东元电机股份有限公司 Robot and its path interpolation planning command generation system
CN112305994B (en) * 2020-11-05 2021-11-16 广东三维家信息科技有限公司 Straight line segment smoothing method, device and equipment based on average filtering and storage medium
CN115906298A (en) * 2021-08-27 2023-04-04 中信戴卡股份有限公司 Curve fitting method, device and equipment based on drawing tool
CN116441204A (en) * 2023-02-28 2023-07-18 西门子(中国)有限公司 Glue removal method, system, medium and electronic equipment with three-axis linkage
CN118732612A (en) * 2024-05-29 2024-10-01 北京立迈胜控制技术有限责任公司 Speed planning control method, device, equipment, and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5726896A (en) * 1995-08-30 1998-03-10 University Of Utah Research Foundation Method and system for spline interpolation, and their use in CNC
CN1255681A (en) * 1998-12-03 2000-06-07 财团法人工业技术研究院 Computer numerical control curve path speed control method and device
CN101178594A (en) * 2007-11-30 2008-05-14 上海奈凯电子科技有限公司 Method for realizing interpolation control in numerically controlled machine system
CN101539769A (en) * 2009-04-28 2009-09-23 中国科学院数学与系统科学研究院 Method for fitting and interpolating G01 code based on quadratic B spline curve

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6782306B2 (en) * 1999-12-16 2004-08-24 Siemens Energy & Automation Motion control system and method utilizing spline interpolation
JP2006072695A (en) * 2004-09-02 2006-03-16 Matsushita Electric Ind Co Ltd Numerical controller
JP2007058748A (en) * 2005-08-26 2007-03-08 Mazda Motor Corp Interpolation path generation method in nc processing of curved surface

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5726896A (en) * 1995-08-30 1998-03-10 University Of Utah Research Foundation Method and system for spline interpolation, and their use in CNC
CN1255681A (en) * 1998-12-03 2000-06-07 财团法人工业技术研究院 Computer numerical control curve path speed control method and device
CN101178594A (en) * 2007-11-30 2008-05-14 上海奈凯电子科技有限公司 Method for realizing interpolation control in numerically controlled machine system
CN101539769A (en) * 2009-04-28 2009-09-23 中国科学院数学与系统科学研究院 Method for fitting and interpolating G01 code based on quadratic B spline curve

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
JP特开2006-72695A 2006.03.16
JP特开2007-58748A 2007.03.08
张园 等.高速加工中连续微小线段的前瞻自适应插补算法.《机床与液压》.2008,第36卷(第6期),第1-4页. *
陶佳安 等.数控系统高性能微段插补技术研究与应用.《仪器仪表学报》.2009,第30卷(第9期),第1923-1929页. *

Also Published As

Publication number Publication date
CN101907876A (en) 2010-12-08

Similar Documents

Publication Publication Date Title
CN101907876B (en) Command point shaping, compressing and interpolating method suitable for numerical control device
CN109571473B (en) Error-controllable small line segment trajectory fairing method
Lai et al. On the development of a parametric interpolator with confined chord error, feedrate, acceleration and jerk
CN101556472B (en) Small straight-line section interpolation method of numerical control system on basis of multicycle optimal corner
CN101493687B (en) NURBS curve self-adaptive subsection interpolation method for real-time forward-looking full acceleration and deceleration control
CN102722140B (en) Multi-period corner small straight-line segment interpolation method based on S curve acceleration/deceleration control
Zhang et al. The transition algorithm based on parametric spline curve for high-speed machining of continuous short line segments
CN110471368A (en) A kind of prediction interpolating method that High Speed NC Machine Tools process velocity is adaptive
CN103048953B (en) Segmented interpolation method of NURBS (Non-Uniform Rational B-Spline) curve based on ARM9 (Advanced RISC Machines) embedded system and FPGA (Field Programmable Gate Array)
CN104281099B (en) A kind of NURBS direct interpolation method and devices for considering processing characteristics
CN101539769A (en) Method for fitting and interpolating G01 code based on quadratic B spline curve
CN111966047B (en) Triaxial micro-line segment direct speed transition method based on trigonometric function acceleration and deceleration control
CN101976060A (en) NURBS (Non-Uniform Rational B-Spline) interpolation method based on machine tool dynamics and curve characteristics
CN103064344A (en) Non uniform rational B spline (NURBS) interpolation based speed smooth control method
JP5615377B2 (en) Tool path generation method and generation apparatus
CN104597847A (en) Akima spline fitting based look-ahead interpolation method
CN102298358A (en) NURBS tool path speed planning method for five-axis numerical control machining
Bosetti et al. Feed-rate and trajectory optimization for CNC machine tools
CN102436216A (en) Method for generating spiral grinding tool locus for blade
CN110900612A (en) Pose-synchronous six-axis industrial robot track smoothing method
Zhang et al. Curve fitting and optimal interpolation on CNC machines based on quadratic B-splines
CN108062073A (en) A kind of circular arc smooth compression interpolation algorithm for high quality processing
CN102707671A (en) Processing path optimization method applied to machine tool
CN113433889A (en) Tool path planning method for five-axis machine tool machining based on three-section type cavel curve
Qin et al. A real-time adaptive look-ahead speed control algorithm for FDM-based additive manufacturing technology with Hbot kinematic system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
ASS Succession or assignment of patent right

Free format text: FORMER OWNER: SHENYANG INSTITUTE OF COMPUTING TECHNOLOGY, CHINESE ACADEMY OF SCIENCES

Effective date: 20150805

C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20150805

Address after: 110171 Liaoning Province, Shenyang Hunnan New District Nanping Road No. 16

Patentee after: Shenyang High-End Computer Numerical Control Technology Co., Ltd.

Address before: 110171 Liaoning Province, Shenyang Hunnan New District Nanping Road No. 16

Patentee before: Shenyang High-End Computer Numerical Control Technology Co., Ltd.

Patentee before: Shenyang Institute of computing technology, Chinese Academy of Sciences

C56 Change in the name or address of the patentee
CP03 Change of name, title or address

Address after: Nanping Road in Dongling District of Shenyang city of Liaoning Province, No. 110171 16-2

Patentee after: SHENYANG GAOJING NUMERICAL CONTROL INTELLIGENT TECHNOLOGY CO., LTD.

Address before: 110171 Liaoning Province, Shenyang Hunnan New District Nanping Road No. 16

Patentee before: Shenyang High-End Computer Numerical Control Technology Co., Ltd.

CP01 Change in the name or title of a patent holder

Address after: Nanping Road in Dongling District of Shenyang city of Liaoning Province, No. 110171 16-2

Patentee after: Shenyang Zhongke CNC Technology Co.,Ltd.

Address before: Nanping Road in Dongling District of Shenyang city of Liaoning Province, No. 110171 16-2

Patentee before: SHENYANG GOLDING NC & INTELLIGENCE TECH. Co.,Ltd.

CP01 Change in the name or title of a patent holder