C1 NURBS representations of G1 composite rational Bézier curves

Report 0 Downloads 24 Views
Computing (2009) 86:257–268 DOI 10.1007/s00607-009-0057-4

C 1 NURBS representations of G 1 composite rational Bézier curves Jianmin Zheng

Received: 28 June 2009 / Accepted: 13 July 2009 / Published online: 4 August 2009 © Springer-Verlag 2009

Abstract This paper is concerned with the re-representation of a G 1 composite rational Bézier curve. Although the rational Bézier curve segments that form the composite curve are G 1 continuous at their joint points, their homogeneous representations may not be even C 0 continuous in the homogeneous space. In this paper, an algorithm is presented to convert the G 1 composite rational Bézier curve into a NURBS curve whose nonrational homogeneous representation is C 1 continuous in the homogeneous space. This re-representation process involves reparameterization using Möbius transformations, smoothing multiplication and parameter scaling transformations. While the previous methods may fail in some situations, the method proposed in this paper always works. Keywords Piecewise rational Bézier curves · C 1 continuity · NURBS · Reparameterization · Smoothing multiplication · Parameter scaling transformation Mathematics Subject Classification (2000)

65D17 · 65D18 · 68U07

1 Introduction A G 1 composite rational Bézier curve is formed by several rational Bézier curve segments subject to the first order geometric continuity at the joints of the segments. Due to the generality and capability of rational Bézier representations, composite rational Bézier curves have become fundamental elements in geometry modeling [1,9,10].

Communicated by C.H. Cap. J. Zheng (B) School of Computer Engineering, Nanyang Technological University, Singapore, Singapore e-mail: [email protected]

123

258

J. Zheng

In many engineering design applications, for example, straight line segments, arcs and rational Bézier curve segments are stitched, forming a composite rational Bézier curve. For a G 1 composite Bézier curve, it is always possible to make the curve be C 1 by an appropriate choice of knot spacing and thus represent the curve as a B-spline curve defined over a knot vector in which all the interior knots have multiplicity of one less than the degree of the curve [2]. However, for a G 1 composite rational Bézier curve, its homogeneous representation may not be even C 0 continuous [5]. Though we can scale the weights to make the scaled homogeneous representation be C 0 continuous, it may still not be C 1 even by carefully choosing the knot spacing. Figure 1 shows a G 1 composite rational Bézier curve and its control polygon. Obviously its homogeneous curve is only C 0 . This phenomenon will cause problems in applications such as skinning piecewise rational Bézier curves to construct a surface [4,6,11,12]. For example, in the downstream surface creation using skinning or lofting techniques, when the generator curves are G 1 (or even C 1 ) composite rational Bézier curves but with only C 0 continuity in the homogeneous space, the skinned surface will be C 0 continuous. This is not acceptable in practice. This paper therefore investigates the fundamental problem, which is how to convert a G 1 composite rational Bézier curve into a homogeneously C 1 continuous NURBS representation. It has been shown that simply r eparameterizing the curves does not solve the problem in general [7,11]. Joe et al. presented an algorithm that first converts a degree n composite curve into a NURBS curve with knots of multiplicity n and then reduces the multiplicity of some knots to n − 1 using reparameterization [7]. It was shown that for some composite curves, the algorithm could not reduce the multiplicity of all knots to n −1, which means the resulting NURBS curve is still C 0 at some knots. Tokuyama and Konno proposed a similar idea for reducing the multiplicity of each interior knot to make the curve segments be C 1 continuous in the homogeneous space [11]. Their method involves solving a system of nonlinear equations and there do exist cases where the nonlinear system has no solution. Hohmeyer and Barsky proposed to use a smoothing function to improve the continuity of a rational spline curve in the homogenous space for surface skinning, but there is no general method for generating a satisfactory smoothing function [6]. Instead of considering general rational curves, Fang focused on conics and integral Bézier curves [3]. He presented a simple method to convert conics into a rational quartic Bézier representation, which always possibly re-represents G 1 continuous conics and integral Bézier curves in such a way that the new representation is C 1 continuous in the homogeneous space.

Fig. 1 A G 1 composite curve consisting of three rational Bézier segments: the first two elements of each triple represent the Cartesian coordinates of the control points and the third element represents the weight

(2.5,3.5; 1) (1,3; 4)

(5,3.5; 2)

(3.5,3.5; 1)

(6,3; 1)

(5,2; 2)

(4,1; 1) (0.5,0.5; 8)

123

(6,0.8; 1)

(8,2; 2)

C 1 NURBS representations of G 1 composite rational Bézier curves

259

This paper is inspired by the work of Joe et al. [7] and Tokuyama and Konno [11]. In their methods, the Möbius transformation is the main tool. Noticing that their methods may not work, in this paper we present a new algorithm based on three processes: Möbius transformations, smoothing multiplication and parameter scaling transformations. Different from the previous methods, our algorithm is guaranteed to be able to re-represent a G 1 piecewise rational Bézier curve so that the new representation is C 1 continuous in the homogeneous space. Section 2 describes the technical details of how the three processes are combined to make two rational Bézier curve segments be C 1 in the homogeneous space. In Sect. 3 we extend the technique to deal with more than two curve segments, providing a complete algorithm for converting a G 1 composite rational Bézier curve into a homogeneously C 1 NURBS representation.

2 Joining two segments with C 1 continuity in the homogeneous space Consider a degree m rational Bézier curve

P1 (t) =

R1 (t) = w1 (t)

m

m i=0 w1,i P1,i Bi



m

m i=0 w1,i Bi



t−t1 t2 −t1

t−t1 t2 −t1



 , t ∈ [t1 , t2 ]

and a degree n rational Bézier curve R2 (t) = P2 (t) = w2 (t)

n

n i=0 w2,i P2,i Bi

n

n i=0 w2,i Bi





t−t2 t3 −t2

t−t2 t3 −t2



 , t ∈ [t2 , t3 ]

where P1,i and P2,i are the control points in Rd , w1,i and w2,i are the weights, and   t j+1 −t k−i t−t j i t−t ( t j+1 −t j ) are degree k Bernstein polynomials. Let Bik ( t j+1 −tj j ) = ki ( t j+1 −t j )

Q 1 (t) = (R1 (t), w1 (t)) =

m 

 Q1,i Bim

i=0

t − t1 t2 − t1



and Q 2 (t) = (R2 (t), w2 (t)) =

n  i=0

 Q2,i Bin

t − t2 t3 − t2



where Qk,i = (wk,i Pk,i , wk,i ), k = 1, 2, are the control points in Rd+1 . Then Q 1 (t) and Q 2 (t) are degrees m and n Bézier curves in Rd+1 . They are nonrational homogeneous representations of P1 (t) and P2 (t).

123

260

J. Zheng

Curves P1 (t) and P2 (t) are said to be G 1 continuous at t = t2 if there exists a positive number λ such that P1 (t2 ) = P2 (t2 ), P1 (t2 ) = λP2 (t2 ).

(1)

In particular, if λ = 1, P1 (t) and P2 (t) are C 1 continuous at t = t2 . Since P1 (t2 ) = w P1,m −P1,m−1 w2,1 P2,1 −P2,0 1 m w1,m−1 and P2 (t2 ) = n w2,0 t2 −t1 t3 −t2 , if P1 (t) and P2 (t) are G at t = t2 , 1,m we have λ=

m w1,m−1 w2,0 t3 − t2 P1,m − P1,m−1  . n w1,m w2,1 t2 − t1 P2,1 − P2,0 

(2)

Using Pk (t) = Rk (t)/wk (t) and Pk (t) = (Rk (t)wk (t) − Rk (t)wk (t))/wk2 (t), we can verify that the G 1 continuity condition (1) is equivalent to the following [5]: Q 1 (t2 ) = c0 Q 2 (t2 ),   Q 1 (t2 ) = λ c1 Q 2 (t2 ) + c0 Q 2 (t2 )

(3)

where c0 = w   1,m /w2,0 , w1,m − w1,m−1 w2,1 − w2,0 (λw2,0 ). c1 = m − c0 λn t2 − t1 t3 − t2

(4)

It is thus observed that if P1 (t) and P2 (t) are G 1 (or even C 1 ) continuous in Rd , their homogeneous counterparts Q 1 (t) and Q 2 (t) are not necessarily G 1 in Rd+1 . In fact, there exist several possible situations for Q 1 (t) and Q 2 (t). Specifically, if c0 = 1, Q 1 (t) and Q 2 (t) are even not continuous at t = t2 . If c0 = 1 and c1 = 0, Q 1 and Q 2 are only C 0 at t = t2 . If c0 = 1 and c1 = 0, Q 1 and Q 2 are G 1 for λ = 1 and C 1 for λ = 1. Our goal is to re-express P2 (t) such that the homogeneous representation of the new P2 (t) has the same position and the first order derivative as Q 1 (t) at t = t2 . We accomplish this by performing three processes: a Möbius transformation, smoothing multiplication and a parameter scaling transformation. The details are explained in the following subsections. 2.1 Möbius transformation Our first attempt is to re-parameterize P2 (t) using the Möbius transformation: t = tα (s) =

123

t2 (t3 − s) + αt3 (s − t2 ) , s ∈ [t2 , t3 ] (t3 − s) + α(s − t2 )

(5)

C 1 NURBS representations of G 1 composite rational Bézier curves Fig. 2 The curve on the right is the result of applying a Möbius transformation t2 (s) to the curve on the left

261

w2 =1

w2 =4

w1 =4

w1 =8 w3 =1

w0 =8

w3 =8 w0 =8

where α > 0 is a constant. tα (s) is a family of parameter transformations that map interval [t2 , t3 ] to itself with tα (t2 ) = t2 and tα (t3 ) = t3 . When α = 1, tα (s) = s is an identity transformation. After the reparameterization using the Möbius transformation, P2 (t) becomes n P¯2 (s) = P2 (t (s)) =

i=0 α

n

iw

n 2,i P2,i Bi

n i i=0 α w2,i Bi





s−t2 t3 −t2

s−t2 t3 −t2



 , s ∈ [t2 , t3 ]

(6)

That is, the control points P2,i remain unchanged and the weights w2,i become α i w2,i [8]. The reparameterization changes how the curve is traced (see Fig. 2 for an illustration). Also, the homogeneous representation of P¯2 (s) satisfies Q¯ 2 (s) = Q 2 (tα (s))((t3 − s) + α(s − t2 ))n /(t3 − t2 )n .

(7)

Computing Q¯ 2 (s) and its derivative at s = t2 gives Q¯ 2 (t2 ) = Q 2 (t2 ) and Q¯ 2 (t2 ) = α Q 2 (t2 ) + n(α−1) t3 −t2 Q 2 (t2 ), from which we have Q 2 (t2 )

=

Q¯ 2 (t2 ) −

n(α−1) t3 −t2 Q 2 (t2 )

α

.

Thus Q 1 (t2 ) =

λ α



 nc0 (1 − α) ¯ c1 α + Q 2 (t2 ) + c0 Q¯ 2 (t2 ) . t3 − t2

(8)

A necessary condition for Q 1 (t) and Q¯ 2 (s) to be C 1 is c1 α + nct03(1−α) = 0 which −t2 gives α = nc0 −cnc1 (t0 3 −t2 ) . However, the value of α computed in this way may sometimes be negative. In that case, Q¯ 2 (s) is not the final solution. Therefore here we look for further processes that help to always be able to deliver the correct solution. 2.2 Smoothing multiplication The second process we will use is called smoothing multiplication, which multiplies both the denominator and numerator of the rational Bézier curve by a common factor.

123

262

J. Zheng

The process is so named because an appropriate factor may improve the smoothness of the corresponding homogeneous curve in Rd+1 [6]. Now let the denominator and numerator of P¯2 (s) of (6) be multiplied by a factor c(s). The homogeneous representation Q¯ 2 (s) of P¯2 (s) becomes c(s) Q¯ 2 (s). This process does not change the shape and parameter range of the curve, but it raises the degree of the curve. Since we try to keep the degree of the re-expressed curve as low as possible, we let c(s) be a linear function. Notice that (c(s) Q¯ 2 (s)) = c (s) Q¯ 2 (s) + c(s) Q¯ 2 (s). Comparing this with the expression within the square bracket of (8) suggests   nc0 (1 − α) (s − t2 ). c(s) = c0 + c1 α + t3 − t2 This makes Q 1 (t2 ) = c(t2 ) Q¯ 2 (t2 ) and Q 1 (t2 ) = αλ (c(s) Q¯ 2 (s)) |s=t2 , implying that Q 1 (t) and c(s) Q¯ 2 (s) are G 1 continuous at t = s = t2 . In general, we assume that the weights of a rational Bézier curve are positive or at least nonnegative. Therefore we require that the rational Bézier curve after smoothing multiplication should also have positive or nonnegative weights. Rewrite c(t) in Bézier form: c(s) = c0

t3 − s s − t2 + cˆ1 t3 − t2 t3 − t2

(9)

where cˆ1 = (n + 1)c0 + (c1 (t3 − t2 ) − nc0 )α. If the original P¯2 (s) has nonnegative weights, a sufficient condition for c(s) Q¯ 2 (s) to have nonnegative weights is that the two Bézier coefficients of c(t) are nonnegative. Since c0 has already been positive, we only need to let cˆ1 ≥ 0. If c1 (t3 − t2 ) − nc0 ≥ 0, then α can take any positive value; otherwise, α should satisfy 0≤α≤

(n + 1)c0 . nc0 − c1 (t3 − t2 )

(10)

This actually gives out a valid range for the Möbius transformation parameter α. Any value within the valid range would work. Finally, we would like to point out that we may apply the smoothing multiplication to the original Bézier curve P2 (t) (instead of P¯2 (t)). This can also make Q 1 (t) and c(t)Q 2 (t) be G 1 continuous at t = t2 , but sometimes some of the weights of c(t)Q 2 (t) become negative, which we try to avoid. This explains why we choose to perform the Möbius transformation first and then to perform smoothing multiplication. 2.3 Parameter scaling transformation After the Möbius transformation and smoothing multiplication, we have re-expressed Q 2 (t), t ∈ [t2 , t3 ] as c(s) Q¯ 2 (s), s ∈ [t2 , t3 ]. After some calculations, we can write c(s) Q¯ 2 (s) as

123

C 1 NURBS representations of G 1 composite rational Bézier curves

c(s) Q¯ 2 (s) =

263

  n+1  s − t2 , s ∈ [t2 , t3 ] (w¯ 2,i P¯ 2,i , w¯ 2,i )Bin+1 t3 − t2

(11)

i=0

where   i i α i−1 w2,i−1 + c0 1 − α i w2,i , w¯ 2,i = cˆ1 n+1 n+1   ¯P2,i = cˆ1 i α i−1 w2,i−1 P2,i−1 + c0 (1 − i )α i w2,i P2,i w¯ 2,i . n+1 n+1 Homogeneous curves Q 1 (t) and c(s) Q¯ 2 (s) are G 1 continuous at t = s = t2 . They can be made C 1 continuous by a parameter scaling transformation. Since Q 1 (t2 ) = λ  ¯ α (c(s) Q 2 (s)) |s=t2 , we introduce the parameter scaling transformation

t3 − t2 s = sµ (t) = t2 + µ(t − t2 ), t ∈ t2 , t2 + µ

(12)

where µ = λ/α. Applying sµ (t) to c(s) Q¯ 2 (s), we get c(sµ (t)) Q¯ 2 (sµ (t)) =

n+1 

(w¯ 2,i P¯ 2,i , w¯ 2,i )Bin+1

i=0

t3 − t2 t ∈ t2 , t2 + . µ



 t − t2 , (t3 − t2 )/µ (13)

It is easy to check that Q 1 (t2 ) = (c(sµ (t)) Q¯ 2 (sµ (t))) |t=t2 and Q 1 (t2 ) = c(sµ (t2 )) Q¯ 2 (sµ (t2 )). Thus we have found the desired new representation for P2 (t). That is c(sµ (t)) Q¯ 2 (sµ (t)). 3 Algorithm for multiple curve segments Note that in the proposed method described in the preceding section only the second curve segment is processed. This property makes it easy to extend the method to handle several curve segments, producing a general algorithm for converting a G 1 composite rational Bézier curve into a C 1 NURBS representation. Suppose a G 1 composite curve P(t) consists of m degree n rational Bézier curve segments Pi (t), i = 1, . . . , m: n Pi (t) =

n j=0 wi, j Pi, j B j

n

n j=0 wi, j B j





t−ti ti+1 −ti

t−ti ti+1 −ti



 , t ∈ [ti , ti+1 ].

Our strategy is to begin with the first segment as the current segment and to process the second segment as the next one to make it C 1 continuous with the current one.

123

264

J. Zheng

Then we let the processed second segment be the current one and process the third segment as the next one to make it C 1 with the current one. This procedure continues until the last segment is processed. By appropriate adaption, we can summarize the steps of the algorithm as follows, after which brief explanations are also given: Step 1. Degree-elevate P1 (t) and denote the weights and control points of the degree-elevated P1 (t) by w¯ 1, j and P¯ 1, j , j = 0, . . . , n + 1, where   j j w1, j−1 + 1 − w1, j n+1 n+1     j j w¯ 1, j . w1, j−1 P1, j−1 + 1 − w1, j P1, j = n+1 n+1

w¯ 1, j = P¯ 1, j

¯ 1 = t2 − t1 . Step 2. Set iteration index k = 1 and knot spacing  Step 3. Set k+1 = tk+2 − tk+1 Step 4. Compute λ, c0 and c1 : n + 1 w¯ k,n wk+1,0 tk+2 − tk+1 P¯ k,n+1 − P¯ k,n  n w¯ k,n+1 wk+1,1 tk+1 − tk Pk+1,1 − Pk+1,0  w¯ k,n+1 c0 = wk+1,0 ¯ k − c0 λn(wk+1,1 − wk+1,0 )/k+1 (n + 1)(w¯ k,n+1 − w¯ k,n )/ c1 = λwk+1,0 λ=

Step 5. If k+1 c1 − nc0 > 0, then choose α from (0, +∞); Otherwise, choose α 0 ). Usually we choose such an α that is as close to one from (0, nc(n+1)c 0 −k+1 c1 as possible. Step 6. Compute cˆ1 = (n + 1)c0 + (k+1 c1 − nc0 )α. Step 7. Compute the new weights w¯ k+1,i and control points P¯ k+1,i , i = 0, . . . , n+1: w¯ k+1,i P¯ k+1,i

  i i i−1 α wk+1,i−1 + c0 1 − α i wk+1,i = cˆ1 n+1 n+1   i i cˆ1 n+1 α i wk+1,i Pk+1,i α i−1 wk+1,i−1 Pk+1,i−1 + c0 1 − n+1 = w¯ k+1,i

¯ k+1 = α k+1 Step 8. Update the knot spacing:  λ Step 9. Increase k: k ← k + 1. If k < m, then go to step 3. Step 10. Output the resulting degree n + 1 NURBS representation where the weights and the control points are w¯ 1,0 , w¯ 1,1 , . . . , w¯ 1,n , w¯ 2,1 , . . . , w¯ 2,n , . . . , w¯ m,1 , . . . , w¯ m,n , w¯ m,n+1 P¯ 1,0 , P¯ 1,1 , . . . , P¯ 1,n , P¯ 2,1 , . . . , P¯ 2,n , . . . , P¯ m,1 , . . . , P¯ m,n , P¯ m,n+1

123

C 1 NURBS representations of G 1 composite rational Bézier curves

265

and the knot vector is ⎧ ⎪ ⎨

⎫ ⎪ ⎬

t¯1 , t¯1 , t¯1 , . . . , t¯1 , t¯2 , . . . , t¯2 , . . . , t¯m , . . . , t¯m , t¯m+1 , . . . , t¯m+1 , t¯m+1 , t¯m+1           ⎪ ⎪ ⎩ ⎭ n+2

n

n

n+2

¯ j , j = 1, . . . , m. with t¯1 = t1 and t¯j+1 = t¯j +  In the above algorithm, step 1 just degree-elevates the first curve segment to make its degree match the degree of the final curve representation and step 2 is simply an initialization. Steps 3-9 form a loop. In particular, step 3 computes the knot spacing of the next segment before processing. Step 4 computes some coefficients describing the geometric continuity between the k th (current) and the (k+1)th (next) segments, which are the adaption of (2) and (4). Step 5 determines an appropriate α for the Möbius transformation and step 6 computes the second coefficient of the linear smoothing multiplication factor. The new weights, control points and knot spacing of the desired representation of the (k + 1)th segment are then computed in steps 7 and 8. After all the iterations end, we obtain a degree n + 1 piecewise rational Bézier curve that is C 1 continuous in the homogeneous space. Thus it can be represented as a degree n + 1 NURBS curve with knots of multiplicity n + 1. Since the curve is C 1 continuous in the homogeneous space, the multiplicity of each interior knot can be reduced to n and accordingly some control points and weights are removed [2]. As a result, we arrive at a degree n + 1 NURBS curve with mn + 2 control points and weights, and a knot vector with each interior knot having multiplicity n, which is outputted from step 10. Remark 1 Note that Sect. 2.2 or step 5 of the above algorithm actually provides a valid range for the Möbius transformation parameter α. In practice, we have to choose an appropriate value from the valid range. Different values of α result in different representations (see the example in Sect. 4). How to appropriately choose the α value depends on the applications. For example, in surface skinning applications, we expect that the skinned surface has a shape of high quality. This requires the generator curves to have good parameterization. How to choose α such that the new representation of the curve has good parameterization is usually a complicated problem. In general, if we assume that the given curves have good parameterization, then it is natural to expect that the good parameterization is preserved in the new representation, which can be achieved if Möbius transformation we perform happens to degenerate to the identity transformation. This thus suggests a heuristic approach that we choose a value for α, which is closest to one within the valid range. Remark 2 From the above description of the algorithm, we can see that our algorithm is a systematic approach that is always able to convert a G 1 composite rational Bézier curve into a spline which is C 1 continuous in the homogeneous space. The weights of the new representation are still positive and the degree is increased by one. However, for some G 1 composite rational Bézier curve, simpler algorithms may possibly be used for the re-representation process. For example, Joe et al’s method [7] or Tokuyama and Honno’s method [11] might be used, outputting a spline with the same degree.

123

266

J. Zheng

Fang’s method [3] can be used for conics, which produces the same weights for all control points excepting the middle one, but raises the degree of curves by 2. 4 An example In this section we provide an example to demonstrate the algorithm. The example serves two purposes. The first purpose is to present an example in which the methods proposed in [7,11] fail, but our method succeeds. The second purpose is to demonstrate the results of different choices of α. Figure 3 (left) shows a composite curve consisting of four circular arcs. These arcs are defined by quadratic rational Bézier curve segments. The control points and weights are 1 P1,0 = (1, 0), w1,0 = 1; P1,1 = (1, 1), w1,1 = √ ; P1,2 = (0, 1), w1,2 = 1 2 1 P2,0 = (0, 1), w2,0 = 1; P2,1 = (−1, 1), w2,1 = √ ; P2,2 = (−1, 0), w2,2 = 1 2 1 P3,0 = (−1, 0), w3,0 = 1; P3,1 = (−1, −1),w3,1 = √ ; P3,2 = (0, −1), w3,2 = 1 2 1 P4,0 = (0, −1), w4,0 = 1; P4,1 = (1, −1), w4,1 = √ ; P4,2 = (1, −2), w4,2 = 1. 2 The parameter intervals of these four curve segments are [1, 2], [2, 3], [3, 4], and [4, 5]. It has been shown that the methods proposed in [7,11] fail to convert this composite curve into a C 1 NURBS curve. Using our algorithm, we can convert the curve into a C 1 NURBS representation. We first process the second segment. The valid range of α is (0, 3.621). We let α = 1, which gives cˆ1 = 2.17 while c0 = 1. Then we process the third segment and the valid range of α is (0, 10.38) and c0 = 2.17. We also choose α = 1 and then cˆ1 = 5.887. Next we process the fourth segment. Now the valid range of α becomes (0, 15.2) and c0 = 5.9. Choosing α = 1 gives cˆ1 = 16.5. As a result, we obtain four cubic rational Bézier curve segments which are C 1 continuous in the homogeneous space. They can P21

P12

P11

P20 P10

P22 P30 P40 P31

P41

P32 P42

Fig. 3 Left a G 1 composite curve consisting of 4 quadratic rational Bézier segments, middle four cubic rational Bézier segments which are C 1 in the homogeneous space, right a C 1 cubic NURBS curve

123

C 1 NURBS representations of G 1 composite rational Bézier curves

267

Fig. 4 Left four cubic rational Bézier segments which are C 1 in the homogeneous space, right a C 1 cubic NURBS curve

be represented as a cubic NURBS curve with knots of multiplicity 3, which is shown in Figure 3 (middle). Finally we can reduce the multiplicity of the interior knots to 2. The resulting knot vector is [1, 1, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 5, 5], the weights are 1, 0.805, 0.805, 1.195, 1.357, 2.986, 3.5, 8.275, 9.74, 16.5, and the control points are (1, 0), (1, 0.586), (0.587, 1), (−0.471, 1.195), (−1, 0.754), (−1, −0.343), (−0.793, −1), (0.335, −1), (1, −1.2), (1, −2), which are shown in Fig. 3 (right). Note that in this solution, all α = 1, which implies that we actually do not perform the Möbius transformation and the re-representation process is accomplished just by the smoothing multiplication. For comparison, let us look at another possible solution with our algorithm. Since the valid range of α for the second segment is (0, 3.621), we can choose α = 2.414, which makes cˆ1 = c0 = 1, implying the smoothing multiplication factor c(t) is a constant. Then we process the third segment and the valid range of α becomes (0, +∞). In this case, we cannot make cˆ1 be equal to c0 , which means we have to use the smoothing multiplication. Thus we simply let α = 0.5. Finally we process the fourth segment and the valid range of α is (0, 2.64). We choose α = 1.376, which makes cˆ1 = c0 = 5.828. In this case, the smoothing multiplication becomes simple degree elevation. The cubic NURBS curve with knots of multiplicity 3 is shown on the left of Fig. 4 and the final cubic NURBS curve with reduced knots is shown on the right of Fig. 4. Now the resulting knot vector is [1, 1, 1, 1, 2, 2, 4.4, 4.4, 7.3, 7.3, 9.3, 9.3, 9.3, 9.3], the weights are 1, 0.805, 0.805, 1.47, 3.08, 9.145, 5.98, 5.72, 7.46, 11, and the control points are (1, 0), (1, 0.586), (0.586, 1), (−0.77, 1), (−1, 0.37), (−1, −0.15), (−0.92, −1), (0.66, −1), (1, −1.49), (1, −2). The difference of the above two solutions relies on the choices of α. While we get the first solution by trying to avoid performing the Möbius transformations, we get the second solution by trying to avoid performing smoothing multiplication as much as possible.

5 Conclusion We have described an algorithm for converting a G 1 composite rational Bézier curve into a NURBS curve that is C 1 continuous in its homogeneous space. The algorithm involves three processes: reparameterization using the Möbius transformation, smoothing multiplication and parameter scaling transformation. Though the degree of the resulting NURBS curve is one higher than that of the original rational Bézier

123

268

J. Zheng

curve, the algorithm is simple and always works. The C 1 continuity of the resulting curves in the homogeneous space enables the conventional skinning technique to yield a C 1 surface that is as smooth as the curves. Future work is to investigate how to re-represent a closed G 1 composite rational Bézier curve to achieve C 1 continuity at each joint point. In addition, since in our approach a valid range rather than a unique value is produced for the Möbius transformation parameter α, our approach actually provides many solutions. Therefore how to select an optimal solution with respect to a certain criterion is an interesting problem which warrants further study. In particular, formulating an optimal criterion specifically for the surface skinning application seems to be of practical value. Acknowledgments This work is supported by the ARC 9/09 Grant (MOE2008-T2-1-075) of Singapore. The author is grateful to the reviewers for their helpful suggestions and for pointing out reference [3] which he missed in the earlier version of the paper.

References 1. Farin G (1999) NURBS: from projective geometry to practical use, 2nd edn. AK Peters, Ltd. Natick. ISBN 1-56881-084-9 2. Farin G (2002) Curves and surfaces for computer aided geometric design, 5th edn. Morgan Kaufmann, San Francisco 3. Fang L (2002) A rational quartic Bézier representation for conics. Comput Aided Geom Des 19:297– 312 4. Filip D, Ball T (1989) Procedurally representing lofted surfaces. IEEE Comput Graph Appl 9(6):27–33 5. Hohmeyer M, Barsky B (1989) Rational continuity: parametric, geometric, and Frenet frame continuity of rational curves. ACM Trans Graph 8(4):335–359 6. Hohmeyer M, Barsky B (1991) Skinning rational B-spline curves to construct an interpolatory surface. CVGIP: Graph Models Image Process 53(6):511–521 7. Joe B, Wang W, Cheng F (1992) Reduced-knot NURBS representations of rational G 1 composite Bézier curves. Comput Aided Des 26(5):393–399 8. Patterson R (1986) Projective transformations of the parameter of a rational Bernstein-Bézier curve. ACM Trans Graph 4(4):276–290 9. Piegl L, Tiller W (1995) The NURBS book. Springer, Berlin 10. Tiller W (1983) Rational B-splines for curve and surface representation. IEEE Comput Graph Appl 3(6):61–69 11. Tokuyama Y, Konno K (2001) Reparameterization of piecewise rational Bézier curves and its applications. Vis Comput 17:329–336 12. Woodward C (1988) Skinning techniques for interactive B-spline surface interpolation. Comput Aided Des 20(8):441–457

123