^{1}

^{*}

^{1}

^{*}

^{1}

^{*}

^{1}

^{*}

Aiming at the problem of low accuracy of interpolation error calculation of existing NURBS curves, an approximate method for the distance between a point and a NURBS interpolation curve is proposed while satisfying the accuracy of the solution. Firstly, the minimum parameter interval of the node vector corresponding to the data point under test in the original data point sequence is determined, and the parameter interval is subdivided according to the corresponding step size, and the corresponding parameter value is obtained. Secondly, the distance from the measured point to the NURBS curve is calculated, and the nearest distance is found out. The node interval is subdivided again on one side of the nearest distance. Finally, the distance between the data point to be measured and each subdivision point is calculated again, and the minimum distance is taken as the interpolation error between the point and the NURBS curve. The simulation results of actual tool position data show that this method can more accurately obtain the error of spatial NURBS interpolation curve.

NURBS curve and surface interpolation technology has a broad application prospect in Computer-Aided Design, and has become the most popular mathematical expression as early as the 1980s [

The interpolation error is an important basis for measuring the distance between the spatial uninvolved interpolation data points and the NURBS interpolation curves. The above scholars have given corresponding interpolation error calculation models for the interpolation error calculation problem, and the quality of the error calculation model directly affects the number of iterations of the NURBS interpolation curve and the number of interpolation data points, and finally affects the efficiency in the actual processing process. In addition to the above scholars, Hu et al. [

Based on the above analysis, this article will elaborate on the following four parts. In the first part, the method steps of interpolating the global curve of a given data point are introduced in detail. In the second part, this paper proposes a new method for calculating spatial NURBS curve interpolation error, and explains the calculation process of this method in detail. In the third part, the error calculation method is compared with the existing method to show the superiority of accuracy in error calculation. The fourth part summarizes the whole paper and explains the application value of the NURBS curve error calculation method.

A p-degree NURBS curve is defined as [

C ( u ) = ∑ i = 0 n N i , p ( u ) ω i P i ∑ i = 0 n N i , p ( u ) ω i , u ∈ [ 0 , 1 ] (1)

In Equation (1), { P i } is the control point of NURBS curve. The number of control points is n + 1, and the lines of all control points { P i } constitute the control polygon of NURBS curve. { ω i } is the weight factor value of the corresponding control point { P i } ; N i , p ( u ) is the pth B-spline basis function.

The B-spline basis function is defined in the node vector

U = ( u 0 , u 1 , ⋯ , u m )

(where: m = n + p + 1 , and the number of nodes is m + 1). B-spline basis function can be obtained by de Boor-Cox recurrence formula

{ N i , 0 ( u ) = { 1 , if u i ≤ u ≤ u i + 1 0 , else N i , p ( u ) = u − u i u i + p − u i N i , p − 1 ( u ) + u i + p + 1 − u u i + p + 1 − u i + 1 N i + 1 , p − 1 ( u ) let 0 0 = 0 . (2)

For the data point set of NURBS curve interpolation, the following interpolation calculation method can be used to calculate the NURBS curve interpolation.

First, we need to parameterize the set of data points participating in the interpolation. In this paper, the most commonly used string length parameterization method is used to parameterize the feature data points.

For data point set { Q j } ( j = 0 , 1 , 2 , ⋯ , n ) , let the total chord length be D, then there will be

D = ∑ j = 1 n | Q j − Q j − 1 | (3)

Then, the parameters corresponding to each data point { Q j } ( j = 0 , 1 , 2 , ⋯ , n ) can be represented as

u ¯ 0 = 0 u ¯ j = u ¯ j − 1 + | Q j − Q j − 1 | D , j = 1 , 2 , ⋯ , n − 1 u ¯ n = 1 . (4)

Let the node vector be U = ( u 0 , u 1 , ⋯ , u m ) . In order to make the node vector reflect the distribution of u ¯ j well, this paper adopts the method of taking the average value, namely

u 0 = ⋯ = u p = 0 u i + p = 1 p ∑ j = i i + p − 1 u ¯ j ( i = 1 , 2 , ⋯ , n − p ) u m − p = ⋯ = u m = 1 (5)

where U is equal to ( 0 , ⋯ , 0 ︸ p + 1 , u p + 1 , ⋯ , u m − p − 1 , 1 , ⋯ , 1 ︸ p + 1 ) .

In order to simplify the calculation, all the weight factor values ω i are set as 1 in this paper, and ∑ i = 0 n N i , p ( u ) = 1 can be known from the normalization of the NURBS curve. At this point, Equation (1) can be simplified to

C ( u ) = ∑ i = 0 n N i , p ( u ) P i (6)

Establish the following system of linear Equations for the control point P i

Q j = C ( u ¯ j ) = ∑ i = 0 n N i , p ( u ¯ j ) P i ( j = 0 , 1 , ⋯ , n ) (7)

In Equation (7), ∑ i = 0 n N i , p ( u ¯ j ) is the matrix of ( n + 1 ) × ( n + 1 ) coefficients. The parameter u ¯ j and the node vector U can be obtained by using Equations (3)-(5). The B-spline basis function can be obtained by using Equation (2), and the following linear equations can be obtained by substituting into Equation (7)

[ 1 0 0 ⋯ 0 N 0 , 3 ( u ¯ 1 ) N 1 , 3 ( u ¯ 1 ) N 2 , 3 ( u ¯ 1 ) ⋯ N n , 3 ( u ¯ 1 ) N 0 , 3 ( u ¯ 2 ) N 1 , 3 ( u ¯ 2 ) N 2 , 3 ( u ¯ 2 ) ⋯ N n , 3 ( u ¯ 2 ) ⋮ ⋮ ⋮ ⋱ ⋮ 0 0 0 ⋯ 1 ] ⋅ [ P 0 P 1 P 2 ⋮ P n ] = [ Q 0 Q 1 Q 2 ⋮ Q n ] (8)

After solving the control point set { P i } ( i = 0 , 1 , 2 , ⋯ , n ) in Equation (8), A NURBS interpolation curve about the feature data point { Q j } ( j = 0 , 1 , 2 , ⋯ , n ) participating in the interpolation can be uniquely determined.

An initial NURBS interpolation curve is constructed according to the calculation method of the NURBS interpolation curve calculated in Section 2. However, for data point set { Q s } ( s = 0 , 1 , ⋯ , t − n − 1 ) in the original data point set { Q i } ( i = 0 , 1 , ⋯ , t ) that does not belong to interpolation data point set { Q j } ( j = 0 , 1 , ⋯ , n ) and does not participate in NURBS curve interpolation, interpolation error ε s at all data points Q s should be calculated to verify whether the constraint condition that ε s is not greater than the preset interpolation error ε is satisfied. In order to calculate the interpolation error ε s at each data point Q s , an approximate solution method for the distance from the following point to the NURBS interpolation curve is proposed in this paper.

The first step is to determine the minimum parameter node interval ( u a , u b ) of the node vector corresponding to the data point Q s in the original data point sequence, as shown in

The parameter node interval ( u a , u b ) is divided by step h for R (where R is the number of data points not involved in interpolation between two adjacent characteristic data points), and u r = u a + r h ( r = 0 , 1 , 2 , ⋯ , R ) is taken, where the calculation formula of step h is

h = u b − u a R (9)

Calculate the distance between Q s and C ( u r ) , ε r , take the minimum value in ε r as ε c , and the point on the curve corresponding to ε c as C ( u c ) , as shown in

ε r = | Q s − C ( u r ) | , u a ≤ u r ≤ u b (10)

ε c = min 0 ≤ r ≤ R | Q s − C ( u r ) | (11)

Take parameter u c as the center, and take parameter u c − and u c + on each side (where u c − = u c − h , u c + = u c + h ). Calculate the distance L c − and L c + from data points Q s to two points C ( u c − ) and C ( u c + ) respectively, and take the smaller value of the two as L min .

On the side where L min is obtained (may as well be set as C ( u c + ) ), W parameter nodes are taken to form the parameter interval of ( u c , u c + W ) (The satisfactory accuracy can be obtained if W is 3). The data point Q s is projected to the NURBS curve segment from C ( u c ) to C ( u c + 3 ) , and the projection point is set as C ( u w ) ( w = 0 , 1 , 2, ⋯ ), calculate the distance ε w between Q s and C ( u w ) , take the minimum value in ε w as ε s , and the point on the curve corresponding to ε s as C ( u d ) , as shown in

In the parameter node interval ( u c , u c + W ) , R ′ ( R ′ = 10 W ) is divided by step h ′ , and u w = u c + w h ( w = 0 , 1 , 2 , ⋯ , R ′ ) is taken, where the calculation formula of step h ′ is

h ′ = u c + W − u c R ′ (12)

The calculation formulas of the distance between data point Q s and C ( u w ) , ε w and ε s can be respectively calculated as

ε w = | Q s − C ( u w ) | , u c ≤ u w ≤ u c + W (13)

ε s = min 0 ≤ w ≤ R ′ | Q s − C ( u w ) | (14)

Now, the specific algorithm steps of the approximate solution method for interpolation error can be summarized as follows:

l Search the minimum parameter node interval ( u a , u b ) in the node vector corresponding to the data point Q s in the original data point sequence, divide the parameter interval by the step length h calculated by Equation (9) into R equal parts, and obtain the value of each parameter at the equal point respectively.

l The distance ε r between Q s and various points on the curve corresponding to parameter u r is calculated by using Equation (10), and the minimum distance ε c is obtained by combining Equation (11). Meanwhile, the point C ( u c ) and parameter u c on the curve corresponding to ε c are determined.

l Taking parameter u c as the center, one parameter u c − and u c + are taken on each side before and after, to calculate the distance L c − and L c + between Q s and two points C ( u c − ) and C ( u c + ) , and to determine the smaller value L min .

l On the side where L min is obtained, the parameter interval ( u c , u c + W ) is obtained, and the R ′ bisection is performed by using Equation (12), and the value u w ( w = 0 , 1 , 2 , ⋯ , R ′ ) at the same bisection point of each parameter is obtained, respectively. ε w and ε s are calculated by using Equation (13) and Equation (14).

In order to verify the accuracy and feasibility of the interpolation error calculation method proposed in this paper, firstly, { Q j } set of data points to be interpolated and a measurement point Q outside the data points are given in this paper. The coordinate of the measurement point Q outside the data points is Q = ( 11 .3929,5 .6180,6 .8010 ) , and the spatial position coordinates of each point are shown in

The NURBS curve interpolation method in Section 2 is used to interpolate { Q j } , and the relationship between the interpolated NURBS curve, the interpolated data point { Q j } and the measured point Q is shown in

Using the interpolation error calculation method proposed in this paper, the distance between the measured point Q and the NURBS interpolation curve is calculated by using the existing neighborhood comparison method [

The serial number | Interpolate the data point { Q j } | ||
---|---|---|---|

x | y | z | |

1 2 3 4 5 6 7 8 9 10 11 12 | 0 1.9743 3.9680 5.9108 7.7814 9.5064 11.3929 12.9686 14.7736 16.7677 18.5153 20.0000 | 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 5.6180 | 4.9750 4.7900 4.9110 5.3927 6.0500 5.6537 4.8011 3.8485 3.0845 3.2558 4.1447 5.3626 |

Methods | Theoretical minimum distance: 1.1871 mm | |
---|---|---|

The minimum distance (mm) | Time (seconds) | |

Stepwise scanning method Neighborhood comparison method The proposed method | 1.7986 1.7881 1.7878 | 9.3167 10.4256 12.3928 |

As can be seen from

Solution space for NURBS curve point to the curve of minimum distance problem, this paper puts forward a new type of computing space discrete data points to NURBS curve distance method, and the correctness of the method through examples, and compared with other existing methods, the calculation precision of the method is higher, to reflect the NURBS curve interpolation error and improve the efficiency of iteration has good application value.

The authors declare no conflicts of interest regarding the publication of this paper.

Chen, L.J., Gao, F., Zhao, B. and Ma, L.F. (2020) Calculation of Space NURBS Curve Interpolation Error. Journal of Computer and Communications, 8, 1-9. https://doi.org/10.4236/jcc.2020.86001