G2 Pythagorean hodograph quintic transition between two circles with shape control

G2 Pythagorean hodograph quintic transition between two circles with shape control

Computer Aided Geometric Design 24 (2007) 252–266 www.elsevier.com/locate/cagd G2 Pythagorean hodograph quintic transition between two circles with s...

248KB Sizes 4 Downloads 108 Views

Computer Aided Geometric Design 24 (2007) 252–266 www.elsevier.com/locate/cagd

G2 Pythagorean hodograph quintic transition between two circles with shape control Zulfiqar Habib a,∗ , Manabu Sakai b a Department of Computer Science, COMSATS Institute of Information Technology, Lahore Campus, Raiwind Road, Off Defence Road,

Lahore, Pakistan b Department of Mathematics and Computer Science, Kagoshima University, Koorimoto 1-21-35, Kagoshima 890-0065, Japan

Received 25 March 2006; received in revised form 1 February 2007; accepted 12 March 2007 Available online 19 March 2007

Abstract In the highway and rail route designs, or a car-like robot path planning it is often desirable to have a method of joining a circle to a circle with an S-shaped or a broken back C-shaped spiral transition. This paper describes a transition between two such circles. It is shown that a single Pythagorean hodograph quintic curve can be used for blending or for a transition curve preserving G2 continuity with local shape control parameter and flexible constraints. Provision of a shape control parameter provides freedom to modify the shape in a stable manner. © 2007 Elsevier B.V. All rights reserved. Keywords: Quintic; Pythagorean hodograph; Bézier curve; Curvature extrema; Spiral; Computer graphics; Computer applications; CAGD

1. Introduction In curve and surface design it is often desirable to have a transition curve of G2 contact, composed of single spiral segment, between two circles. The purpose may be practical, e.g., in highway design, railway route, or aesthetic applications (Burchard et al., 1993; Gibreel et al., 1999; Sarfraz 2004, 2005). In the discussion about geometric design standards in AASHO (American Association of State Highway Officials), Hickerson (1964) (p. 17) states that “Sudden changes between curves of widely different radii or between long tangents and sharp curves should be avoided by the use of curves of gradually increasing or decreasing radii without, at the same time, introducing an appearance of forced alignment”. Importance of this design feature, which is highlighted in (Gibreel et al., 1999), links vehicle accidents to inconsistency in highway geometric design. In CAD/CAM and CAGD applications, Parametric polynomial cubic splines, because of their geometric and numerical properties, are usually used. The importance of using fair curves in the design process is well documented in the literature (Farin, 1997, Habib et al. 2004, 2005). Cubic curves are not always helpful since they may have unwanted inflection points and singularities (Sakai, 1999). Walton and Meek (Walton and Meek, 2002) lists the following unwanted features of a cubic segment. * Corresponding author. Tel./fax: +92 42 9203101.

E-mail addresses: [email protected] (Z. Habib), [email protected] (M. Sakai). 0167-8396/$ – see front matter © 2007 Elsevier B.V. All rights reserved. doi:10.1016/j.cagd.2007.03.004

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

253

• It may have unwanted curvature extrema. • It’s offset is neither a rational, nor a polynomial algebraic function of its parameter. • It’s arc-length is the integral part of the square root of the polynomial of its parameter. According to Farin (1997), curvature extrema of a fair curve “should occur only where explicitly desired by the designer”. Unwanted curvature extrema of a general parametric cubic curve are discussed in (Habib and Sakai, 2005a); some restrictions were imposed that allow the use of a single cubic Bézier curve as a G2 transition curve between two circles with a small number of curvature extrema. Pythagorean hodograph (PH) curves introduced by Farouki and Sakkalis (1990) do not suffer from the last two of the above mentioned unwanted features. The authors, in (Habib et al. 2005b, 2007), have already shown that the lowest degree PH curves that have enough flexibility for curve design and geometric modeling in general are the quintics. Unwanted curvature extrema can be removed when designing with spiral segments. The clothoid or Cornu spiral (non-polynomial) has been used in highway design for many years (Hartman, 1957). A major drawback with the clothoid is that it is neither polynomial nor rational; it is thus inconvenient to incorporate it into a CAD/CAM system. Fair curves had previously been formed using two curve segments, in particular, two clothoid spiral segments (Meek and Walton, 1989), two cubic spiral segments (Habib and Sakai, 2005a), and two PH quintic spiral segments (Habib and Sakai, 2005b). The transition curves of G2 contact have been considered for joining (i) straight line to circle, (ii) circle to circle with a broken back C transition, (iii) circle to circle with an S transition, (iv) straight line to straight line and (v) circle to circle where one circle lies inside the other with a C oval transition. Walton and Meek (2002) considered planar G2 transition between two circles with a single fair PH quintic Bézier curve. They showed that there is no curvature extremum in the case of an S-shaped transition, and that there is a curvature extremum in the case of C-shaped transition. Use of a single curve rather than two segments has the benefit that the designers have fewer entities to be concerned with. The main objectives of our paper are to • generalize and extend the analysis of Walton and Meek (2002). • obtain a fair G2 PH quintic transition between two circles with more flexible constraints than in (Walton and Meek, 2002). • introduce a parameter to control the transition curve while preserving its important shape features. • visualize the relationship between shape control parameter and numerical value of arc-length. The organization of our paper is as follows. Section 2 gives a brief discussion of the notations and conventions for the PH quintic Bézier spiral along with some theoretical background. Description of the method is given in Section 3. Section 4 contains the algorithm based on the analysis of the technique developed in Section 3. The method of Section 3 is illustrated by numerical examples in Section 5. Comparison, analysis, and concluding remarks are discussed in Section 6. 2. Background 2.1. Notations and conventions The usual Cartesian co-ordinate system is presumed. Boldface is used for points and vectors, e.g.,   ax . a= ay The Euclidean norm or length of a vector a is denoted by the notation a =



ax2 + ay2 ,

254

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

and ab means the vector a is parallel to vector b. The positive angle of a vector a is the counterclockwise angle from the vector (1, 0) to a. The derivative of a function f is denoted by f  . The symbol × is used to denote the two-dimensional scalar cross product, e.g., a × b = ax by − ay bx = ab sin θ, where θ is the counterclockwise angle from a to b. The expression a · b denotes the usual inner product. The signed curvature of a parametric curve P (t) in the plane is κ(t) =

P  (t) × P  (t) , P  (t)3

(2.1)

when P  (t) is non-zero. Positive curvature has the center of curvature on the left as one traverses the curve in the direction of increasing parameter. For non-zero curvature, the radius of curvature, positive by convention, is 1/|κ(t)|. The term ‘spiral’ refers to a curved line segment whose curvature varies monotonically with constant sign. A G2 point of contact of two curves is a point where the two curves meet and where their unit tangent vectors and signed curvatures match. Based on Kneser theorem (Guggenheimer, 1963), any circle of curvature of spiral encloses all smaller circles of curvature and is enclosed by all larger circles of curvature. So we cannot find the transition curve with a single spiral segment between the two tangent circles or the intersecting circles. 2.2. PH quintic Bézier curve The problem of finding a fair parametric transition curve between two circles Ω0 , Ω1 with centers C 0 , C 1 , radii r0 , r1 respectively and distance between the centers of two circles as r = C 1 − C 0 ,

(2.2)

λ), 0 < λ  1, can be solved in Hermite-like manner (Habib et al., 2005). Here we consider the with (r1 /r0 following problems. )1/3 (=

1. Find a family of an S-shaped transition curves between two non-intersecting circles Ω0 and Ω1 , satisfying r0 + r1 < r, which guarantee the absence of interior curvature extrema. 2. Find a family of C-shaped transition curves between two circles Ω0 and Ω1 , which have just one curvature extremum. transitions. A quintic Bézier curve is given by Farin (1997) as 5       5 P i (1 − t)5−i t i , z(t) = x(t), y(t) = i

0  t  1.

(2.3)

i=0

Assume that the control points P i , i = 0, . . . , 5, are distinct. Also assume that the initial curvature of the curve is positive, for if it is negative then a reflection about the x-axis will make it positive. Without any loss of generality we can translate, rotate and, if necessary, reflect the shape to normalize it as shown in Figs. 1 and 2 so that the given starting point P 0 is at the origin, P 1 is on the positive x-axis, the given center C 0 (= (0, r0 )) of the larger circle is on the positive y-axis, the ending point P 5 is above the x-axis and, for an S-shaped transition, P 5 − P 4 is parallel to x-axis. The curve z(t) is said to be a PH curve if x  (t)2 + y  (t)2 can be expressed as the square of a polynomial in t. To ensure this, x  (t) and y  (t) are defined by Farouki and Sakkalis (1990) as     2   z (t) = x  (t), y  (t) = u(t) + iv(t) = u2 (t) − v 2 (t), 2u(t)v(t) , 0  t  1, (2.4) where u(t) = u0 (1 − t)2 + 2u1 t (1 − t) + u2 t 2 , v(t) = v0 (1 − t)2 + 2v1 t (1 − t) + v2 t 2 ,

0  t  1.

(2.5)

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

255

Fig. 1. An S-shaped PH quintic Bézier spiral transition.

Fig. 2. A C-shaped PH quintic Bézier spiral transition.

The Bézier control polygon (Farouki and Sakkalis, 1990) thus becomes P 0 = (0, 0),  1 P 1 = P 0 + u20 − v02 , 2u0 v0 , 5 1 P 2 = P 1 + (u0 u1 − v0 v1 , u0 v1 + u1 v0 ), 5  1 2 P3 = P2 + 2u1 − 2v12 + u0 u2 − v0 v2 , 4u1 v1 + u0 v2 + u2 v0 , 15 1 P 4 = P 3 + (u1 u2 − v1 v2 , u1 v2 + u2 v1 ), 5  1 P 5 = P 4 + u22 − v22 , 2u2 v2 . 5

(2.6)

256

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

From (2.1), (2.3) and (2.4), the curvature κ(t) and its derivative κ  (t) of a PH quintic curve z(t) are (Farouki and Sakkalis, 1990) 2(uv  − u v) , (u2 + v 2 )2 2{(uv  − u v)(u2 + v 2 ) − 4(uv  − u v)(uu + vv  )} κ  (t) = , (u2 + v 2 )3 κ(t) =

(2.7) (2.8)

where, for brevity, the parameter t on the right-hand side is omitted. Let θ be the angle from P 1 − P 0 to P 2 − P 1 , as shown in Figs. 1 and 2, where 0 < θ < π/2. Since z (0) is parallel to x-axis, it is assumed that v0 = 0, without any loss of generality. 3. Description of method The steps of our analysis are first to derive the conditions for no curvature extrema and a single curvature extremum for a C-shaped and an S-shaped transitions respectively, and then find the angle θ for the given distance r between two circles. The results are expressed as Theorems 3.1 and 3.2. The two cases of an S-shaped and a C-shaped transition curves are then considered separately in the following sections. 3.1. S-shaped transition Here we consider an S-shaped transition curve z(t) of the form (2.3). The curvature of the transition curve changes sign to allow an inflection point. Let the angle from P 5 − P 4 to P 4 − P 3 be θ . Recall that P 1 − P 0 and P 5 − P 4 are parallel to x-axis. With reference to Fig. 1, we summarize the above discussion as   (ii) z (0), z (1)  (1, 0), (iii) κ(0), κ(1) = (1/r0 , −1/r1 ). (3.1) (i) P 0 = (0, 0), Since z (1) is parallel to x-axis, it is assumed that v2 = 0, without loss of generality. We introduce a shape control parameter m and impose the conditions as in (3.1) to obtain the following unknowns of (2.6).     u30 3m , λ , (v0 , v1 , v2 ) = 0, (u0 , u1 , u2 ) = u0 1, , 0 , u0 > 0. (3.2) 4 4r0 The following theorem guarantees the fairness of the desired single S-shaped transition curve with shape control parameter m. Theorem 3.1. If r > r0 + r1 and 0.3  λ  1, then each value of m( 1) determines a G2 quintic S-shaped transition curve z(t), defined by (2.3), having values as in (2.4), determined as in (3.2), which joins the two given circles with G2 contact and has no interior curvature extrema. Proof. Our method to obtain the single S-shaped transition curve without interior curvature extrema is based on showing that the derivative of the curvature, as defined in (2.8), does not change sign for 0 < t < 1. The derivative κ  (t), in (2.8), of the curvature, for t = s/(1 + s), s > 0, yields



 3  u40 2r0 (1 + s)5  2 z (t) κ (t) = b0 + b1 (m − 1) + b2 (m − 1) + 2 . (3.3) − 9r0 u60 The parameter s has been introduced to simplify subsequent algebraic expressions. The coefficients bi , 0  i  2, are given by

 b0 = s 12(1 − λ)λ2 s 4 + 2λ(9 − 2λ)s 3 + λ(27 + 8λ)s 2 + (44λ − 9)s + 2(10λ − 3)  0 for 0.3  λ  1,

 b1 = 6 2λ2 s 5 + 2λ(3 − 2λ)s 4 + 3λs 3 − 3s 2 (1 − 2λ) + 2s + 2 1  0 for λ  , 6

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

257

 b2 = 9s 2λs 3 − λs 2 − s + 2 √ √ 359 + 35 105 359 − 35 105 λ .  0 for 16 16 The range of λ in the expressions b1 and b2 is obtained with the aid of the symbolic manipulator MATHEMATICA. Since the derivative of curvature κ  (t) is non-negative for 0 < t < 1 so there are no interior curvature extrema in the PH quintic as defined. 2 3.1.1. Existence of a unique solution For a given distance r between the centers     C 0 = x(0), y(0) + r0 , C 1 = x(1), y(1) − r1 , of two circles Ω0 and Ω1 , the condition (2.2) determines a polynomial equation f (u0 ) = 0 in u40 given by

2  8

 2 2 u0 + r04 81m4 f (u0 ) = u12 0 + 2r0 9m + 28λ + 18m(1 + λ) − 6 1 + λ     + 324(1 + λ)m3 + 36 21 + 22λ + 21λ2 m2 − 576 1 − 2λ − 2λ2 + λ3  

 2  − 32 27 + 33λ − 38λ2 + 33λ3 + 27λ4 u40 − 14400r04 r 2 − r02 1 + λ3 .

(3.4)

z (t)

in (2.4). Recall that the start point is at the The end point z(1)(= (x(1), y(1))) is determined by integrating origin, i.e., z(0)(= (x(0), y(0))) = (0, 0). For m  1 and 0.3  λ  1, the signs of the coefficients of u4i 0 , 0  i  3 are (−, ?, +, +), where “+” and “−” include “0”, and “?” means either “+” or “−”. Therefore, using the Descartes rule of signs (Henrici, 1988, pp. 439– 443) and the intermediate value theorem, we determine the existence of a unique positive solution of (3.4). 3.2. C-shaped transition Here we consider a C-shaped transition curve z(t) of the form (2.3). Let the angles between P i − P i−1 and P i+1 − P i , 1  i  4, as shown in Fig. 2, be θ . Two sub-cases arise. 1. One of the circles is inside the other. In this case it is possible to have a transition curve with no interior curvature extrema. 2. One circle is not inside the other. The first sub-case has been discussed in (Walton and Meek, 1996; Walton et al., 2003; Habib and Sakai, 2007) for cubic and Pythagorean hodograph (PH) quintic transitions. We examine the second sub-case here. By Kneser’s theorem, the transition curve cannot be a “spiral” arc, so it has at least one interior curvature extremum. We prove that the transition curve has exactly one interior curvature extremum and does not have an inflection point, so the curvature has no change of sign. Now, with reference to Fig. 2, since P 1 − P 0 is parallel to x-axis, we note that, for the z (t), defined by (2.4), we have the following equations:   (ii) z (0)  (1, 0), (iii) κ(0), κ(1) = (1/r0 , 1/r1 ), (3.5) (i) P 0 = (0, 0), to obtain the following unknowns of (2.6) as  (u0 , u1 , u2 ) = 2 mr0 tan θ (1, m, λ cos 2θ ),  (v0 , v1 , v2 ) = 2 mr0 tan θ (0, m tan θ, λ sin 2θ ).

(3.6)

The desired single C-shaped transition curve with shape control parameter m, ensures fairness according to the following theorem. Theorem 3.2. If r > r0 − r1 , each value of m ( 1) determines a G2 quintic C-shaped transition curve z(t), defined by (2.3), having values as in (2.4), determined as in (3.6), which joins the two given circles with G2 contact and has a single interior curvature extremum. The curve begins with monotone decreasing curvature and ends with monotone increasing curvature.

258

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

Proof. Our method to obtain the single C-shaped transition curve with a single interior curvature extrema is based on showing that, for 0 < t < 1, the derivative of curvature, as defined in (2.8) changes its sign one time only. Differentiation of (2.7) and using (3.6) for t = s/(1 + s), s  0, yields

5   3    (1 + s)5 z (t) κ (t) = (3.7) ci s i = φ(s) . 2 2 2 16m r0 sec θ tan θ i=0 The parameter s has been introduced to simplify subsequent algebraic expressions. The coefficients ci , 0  i  5, are given by   c0 = −4 8m2 − 6m − 2λ cos2 θ sin2 θ,

 c1 = − 64m3 tan2 θ − 64m2 sin2 θ + 8mλ(1 + 6 cos 2θ) sin2 θ − 14λ sin2 2θ ,

  c2 = 32m3 − 96m2 λ + 80mλ − 12λ2 − λ 96m2 − 104m + 21λ cos 2θ  + 12λ(2m − λ) cos 4θ − 3λ2 cos 6θ tan2 θ,

  c3 = −λ 32m3 − 96m2 + 80mλ − 12λ − 96m2 − 104mλ + 21λ cos 2θ  + 12λ(2m − 1) cos 4θ − 3λ cos 6θ tan2 θ,

  c4 = λ 64m3 − 32m2 λ + 16mλ − 21λ2 − 4λ 8m2 − 7m + 7λ cos 2θ  + λ(12m − 7λ) cos 4θ tan2 θ,   c5 = 4λ2 8m2 − 6mλ − 2λ cos2 θ sin2 θ. By a simple calculation we notice that, for m  1, c0 , c1 < 0 and c4 , c5 > 0 . We then have any one of the following two cases. (1) c3  0: Descartes rule of signs implies that quintic φ(s) has a unique positive zero, i.e., the curvature has a unique relative minimum. (2) c3 < 0: This case has been discussed in Lemma A.1 and Lemma A.2 of Appendix A where we prove that φ(s) has upward opening. Also, using the fact that φ(0) < 0 and φ  (0) < 0, we also show the existence of the unique zero of κ  (s) for s  0. Hence the PH quintic defined in the statement of the theorem has exactly one curvature extremum for 0  t  1.

2

3.2.1. Existence of a unique solution First we need to simplify the procedure by letting q = tan2 θ . Then (3.6) can be expressed in q instead of angle θ as    1−q √ , (u0 , u1 , u2 ) = 2 mr0 q 1, m, λ 1+q  √   2 q √ √ (v0 , v1 , v2 ) = 2 mr0 q 0, m q, λ . (3.8) 1+q Above expression is required to find the end point z(1)(= (x(1), y(1))) by integrating z (t) in (2.4). Recall that the start point is at the origin, i.e., z(0)(= (x(0), y(0))) = (0, 0). Now the centers of two circles Ω0 and Ω1 are   C 0 = x(0), y(0) + r0 = (0, r0 ),   C 1 = x(1) − r1 sin 4θ, y(1) + r1 cos 4θ     √ 4 q(1 − q) 1−q 2 = x(1) − r1 , (3.9) , y(1) − r1 1 − 2 1+q (1 + q)2 For the given distance r the condition (2.2) determines a polynomial equation g(q) = 0 in q given by g(q) =

5  i=0

di q i ,

(3.10)

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

259

where d5 = 64m6 r02 ,

 d4 = 16m4 r02 −3 + 16m2 − 14λ − 3λ2 + 12m(1 + λ) ,

d3 = 8m2 r02 −27 + 48m4 + 33λ + 38λ2 + 33λ3 − 27λ4 + 72m3 (1 + λ)     + 6m2 5 − 2λ + 5λ2 − 24m 1 + 4λ + 4λ2 + λ3 ,

  d2 = −225r 2 + r02 256m6 + 576m5 (1 + λ) + 48m4 13 + 10λ + 13λ2 2      + 225 1 − λ3 − 240mλ 1 − 6λ − 6λ2 + λ3 − 384m3 1 + λ + λ2 + λ3   − 16m2 27 + 45λ + 106λ2 + 45λ3 + 27λ4 , 

  d1 = 2 −225r 2 + r02 32m6 + 96m5 (1 + λ) + 8m4 21 + 22λ + 21λ2     − 96m3 1 − 2λ − 2λ2 + λ3 − 120mλ 1 + 6λ + 6λ2 + λ3     − 4m2 27 + 123λ − 38λ2 + 123λ3 + 27λ4 + 225 1 + 6λ3 + λ6 ,  2 

d0 = −225 r 2 − r02 1 − λ3 . For m  1 and 0 < λ  1, it is easy to show that d5 , d4 , d3 > 0 and d0 < 0. In addition, since d2 − d1 /2 > 0, Descartes rule of signs and the intermediate value theorem imply the unique solution of g(q). 4. The algorithm Based on the above analysis, we have adopted the approach to construct the G2 PH quintic spiral transition between two circles described in the following algorithm. 1. Given the radii r0 , r1 of larger circle Ω0 and smaller circle Ω1 , respectively, and the distance r between two circles, we can find an S-shaped transition if both circles do not intersect and 0.3  λ  1. We can find a C-shaped transition if the smaller circle is not inside the larger circle. Take the given starting point P 0 on the larger circle with its center C 0 . 2. Normalize both the circles by translation, rotation and, if necessary, by reflection according to Fig. 1 or 2 for an S-shaped or C-shaped transition, respectively. 3. Find u0 from (3.4) for an S-shaped transition or find θ from (3.10) for a C-shaped transition. 4. Set the value of shape control parameter m( 1). 5. Find the required spiral transition from (2.3) by using (3.2) or (3.6) for an S-shaped or C-shaped transition, respectively. 6. If the shape of curve is not as required then change the value of m and repeat the above step. 7. Do the reverse transformation to bring the shape back to its original location. 5. Examples Fig. 3 is an S-shaped PH quintic transitions with no curvature extrema and Fig. 4 is a C-shaped transitions with a single curvature extremum. Figs. 3 and 4 indicate the G2 continuous joints of the circles with the transition curves and show the effect of shape preserving parameter m on arc-lengths of the transition curves. Fig. 5 is an example of a C-shaped transition with a single curvature extremum and for the distance between two circles equal to 4 times the larger radius. The method in (Walton and Meek, 2002) does not allow such transition due to the upper limit on the distance between two circles. Two examples from (Walton and Meek, 2002) are presented, controlled by shape parameter, having a family of transitions between two circles. Each transition is a single fair PH quintic curve, i.e., without extraneous curvature extrema, or inflection points. In the illustrations of the examples, the end points of S-shaped and C-shaped transition curves are indicated with circles and disks, respectively. One example, shown in Fig. 6, represents the cross-section of cam. It is composed of two circular arcs joined by an upper and a lower family of C-shaped curves. Other example,

260

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

Fig. 3. S-shaped circle to circle transitions for (r0 , r, λ) = (2, 4, 0.7).

shown in Fig. 7, represents the profile of vase. The side and base of the vase are represented by a family of S-shaped and C-shaped curves, respectively. The endpoints of the S-shaped and C-shaped transition curves are indicated with small circles and disks, respectively. 6. Comparison, analysis, and conclusion We extended the analysis of Walton and Meek (2002) on planar G2 transition between two circles with a fair PH quintic Bézier curve, by introducing a tension control and shape preserving parameter m ( 1). This parameter allows interactive alteration of the shape of the curve while preserving required geometric features, see Figs. 3 and 4. As m increases, the transition between two circles become tighter and tends to a straight line segment in the limit as marrow∞. Figs. 3(c) and 5(c) show how the arc-length of the transition curve decreases as m increases. Since the curvatures remain unchanged at the ends of the transition while the arc-length of the transition is reduced, the rate of change of the curvature increases, see the curvature plots of transition curves for different values of m in Figs. 3(b) and 5(b) indicating the G2 continuous joints of the circles with the transition curves. For m = 1, the results reduce to those of (Walton and Meek, 2002) and there is no provision of shape control. By algebraic reorganization and manipulation we have produced more flexible constraints than in (Walton and Meek, 2002). To guarantee the absence of interior curvature extremum in S-shaped transition curve, the ratio of the radii of the circles are as big as 37 because λ(= (r1 /r0 )1/3 )  0.3, whereas in (Walton and Meek, 2002) the results were shown to be valid for a ratio of up to 8. To guarantee a single curvature extremum for a C-shaped transition curve, there is no upper limit for the distance between the centers of two circles (see Fig. 5), whereas in (Walton and Meek, 2002) it is constrained to less than 3.3 times the larger radius. Acknowledgement The authors owe their gratitude to the anonymous referees for their valuable comments and suggestions which have helped in improving the presentation of the paper. This work is supported by Japan Society for the Promotion of Science (JSPS/FF1/315-P04034).

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

261

Fig. 4. C-shaped circle to circle transitions for (r0 , r, λ) = (4, 4, 0.7).

Appendix A Here we need to show that φ(s) in (3.7) has upward opening for c3 < 0. The second derivative of φ(s) in (3.7) is given by Since

φ  (s) = 20c5 s 3 + 12c4 s 2 + 6c3 s + 2c2 .

(A.1)

  c3 2 8c2 c4 − 3c32 8c2 c4 − 3c32 φ (s)  12c4 s + 6c3 s + 2c2 = 12c4 s + +  , 4c4 4c4 4c4

(A.2)



2

it is sufficient to show that 8c2 c4 − 3c32 > 0. To simplify the analysis let d = cos 2θ . Then from (3.7), we have (c2 , c3 , c4 ) = 2 tan2 θ (r2 , r3 , r4 ),

(A.3)

where

 

 r2 = 2 8m3 − 24(1 + d)m2 λ + 2 7 + 13d + 6d 2 mλ − 3d(1 + d)2 λ2 , 

  r3 = 2λ −8m3 + 24(1 + d)m2 − 2 7 + 13d + 6d 2 mλ + 3d(1 + d)2 λ ,  

 r4 = λ 32m3 − 16(1 + d)m2 λ + 2 1 + 7d + 6d 2 mλ − 7(1 + d)2 λ2 .

(A.4)

Since c3 < 0, the coefficient of 2λ in r3 is negative, i.e.,     3d 3 λ + 6λ(1 − 2m)d 2 + 3λ − 26mλ + 24m2 d − 2m 7λ − 12m + 4m2 < 0.

(A.5)

262

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

Fig. 5. C-shaped circle to circle transitions.

To simplify subsequent algebraic expressions, we assume λ = 1 without loss of above inequality and get the following.      3d 3 + 6(1 − 2m)d 2 + 3 − 26m + 24m2 d − 2m 7 − 12m + 4m2 = ψ(d) < 0. (A.6) For later use, we need to find the valid range of shape preserving parameter m by examining the existence and the number of zeros of ψ(d) in (−1, 1). A change of variable c−1 d= , c > 0, c+1 reduces it to

    − 4(m − 1) 2m2 − 10m + 3 c3 + 4 6m3 − 24m2 + 14m + 3 c2     +4m 6m2 − 12m + 1 c + 8m3 = ψ(c) /(1 + c)3 . (A.7) Note that the sequences of the signs of the coefficients of ci , i = 3, 2, 1, 0, inside the braces of (A.7) are (i) (ii) (iii) (iv)

√ (+, +, +, +) for m  (5 + 19)/2(≈ 4.67945 √ . . .), (−, +, +, +) for 3.22957 . . . < m < (5 + 19)/2, (−, −, +, +) for 1.91287 . . . < m < 3.22957 . . . , (− or 0, −, −, +) for 1  m < 1.91287 . . . .

Descartes rule of signs√shows the existence of the unique positive zero of (A.7), i.e., the unique zero d(= ψ0 (m)) of ψ(d) if 1  m < (5 + 19)/2. Intermediate value theorem gives the bounds for the solution ψ0 (m) since

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

263

Fig. 6. Cam cross-section for m = 1 (thin), 1.3 (bold).

Fig. 7. Vase profile for m = 1 (thin), 1.6 (bold), 3 (extra bold).

ψ(−1)(= −8m3 ) < 0,    504 + 2991(m − 1) + 3438(m − 1)2 + 1003(m − 1)3 7m − 13 = > 0. ψ 15 1125 Lemma A.1. If r3 < 0 then we obtain the following conditions. √   7m − 13 5 + 19 , (ii) −1 < d = ψ0 (m) < (< 1) (i) 1  m < 2 15 Proof. These results follow immediately from the above discussion.

2

for 1  m < 4.

(A.8)

264

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

Let λ = 1/(1 + μ), μ > 0, then, from (A.4), we have 8r2 r4 − 3r32 =

4  4 fi μi , (1 + μ)5

(A.9)

i=0

where f4 = 1024m6 (> 0),

 f3 = 64m4 3d 2 + d(5 − 38m) + 2 − 38m + 61m2 ,

  f2 = 16m2 9d 4 + d 3 (39 − 27m) + 2d 2 29 − 5m + 48m2    + d 35 + 61m + 174m2 − 456m3 + 7 + 44m + 78m2 − 456m3 + 348m4 ,     f1 = −27d 6 + 36d 5 (2m − 3) + 6d 4 8m2 + 18m − 27 − 4d 3 27 + 125m − 156m2 + 216m3    + d 2 −27 − 1428m + 1412m2 − 320m3 + 2496m4 − 4dm 321 − 286m − 488m2    − 1152m3 + 1824m4 + 4m −98 + 77m + 352m2 + 528m3 − 1824m4 + 880m5 ,   

 f0 = −ψ(d) (1 − d) 50 − 11d − 9d 2 + 6 49 − d + 2d 2 (m − 1)  + 8(40 + d)(m − 1)2 + 104(m − 1)3 (> 0). We show that all fi , 0  i  4, are positive under the conditions in Lemma A.1. To show that f3 (= f3 (d)) > 0, the expression of the terms in the braces of f3 (d) about m = 4 gives   f¯3 (d) = 826 − 147d + 3d 2 + (450 − 38d)(m − 4) + 61(m − 4)2 ,

(A.10)

(A.11)

which is positive for m  4. Next, for 1  m < 4, we note the following. (i) (ii)

f¯3 (d) is monotone decreasing with respect to d and f¯3 ((7m − 13)/15)(= (967 + 2067(m − 1) + 1098(m − 1)2 )/25) > 0.

Next, we show that f1 , f2 > 0. For m  4 and −1 < d < 1, the terms inside the braces of f1 , f2 about m = 4 gives (i)   7580960 − 6153360d + 635349d 2 − 47420d 3 + 1038d 4 + 180d 5 − 27d 6   + 12898328 − 8057668d + 633484d 2 − 36980d 3 + 492d 4 + 72d 5 (m − 4)   + 9067316 − 4202504d + 237188d 2 − 9744d 3 + 48d 4 (m − 4)2     + 3373440 − 1091680d + 39616d 2 − 864d 3 (m − 4)3 + 700992 − 141312d + 2496d 2 (m − 4)4 + (77184 − 7296d)(m − 4)5 + 3520(m − 4)6 (> 0), (ii)    61335 − 26121d + 1554d 2 − 69d 3 + 9d 4 + 67868 − 20435d + 758d 2    − 27d 3 (m − 4) + 28014 − 5298d + 96d 2 (m − 4)2 + (5112 − 456d)(m − 4)3 + 348(m − 4)4 (> 0). Lemma A.2. For 1  m < 4, we have (i) f1 > 0 for m > 3.265 . . . and f1 has a unique zero d = ψ1 (m)(∈ (−1, 1)) for m < 3.265 . . . . Then, f1 > 0 (or < 0) is equivalent to −1 < d < ψ1 (m) (or ψ1 (m) < d < 1). (ii) f2 > 0 for m > 2.02972 . . . and f2 has a unique zero d = ψ2 (m)(∈ (−1, 1)) for m < 2.02972 . . . . Then, f2 > 0 (or < 0) is equivalent to −1 < d < ψ2 (m) (or ψ2 (m) < d < 1).

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

265

(iii) ψ1 (m), ψ2 (m) > (7m − 13)/15. Proof. The statements (i) and (ii) follow from the proof of Lemma A.1 by assuming again d = (c − 1)/(c + 1), c > 0. (i) f1 in (A.10) becomes f1 (c) =

6 16m2  i e¯i c , (1 + c)6

(A.12)

i=0

where 

e6 = (m − 1) 27 + 241m + 20m2 − 116m3 − 692m4 + 220m5 ,   e5 = 2 27 − 339m + 286m2 + 488m3 + 1128m4 − 2280m5 + 660m6 ,   e4 = 3 −9 − 190m + 146m2 + 704m3 + 1088m4 − 3040m5 + 1100m6 ,   e3 = 2m −53 + 22m + 920m2 + 1008m3 − 4560m4 + 2200m5 ,   e2 = m2 −43 + 568m + 384m2 − 4560m3 + 3300m4 ,   e1 = 24m4 −2 − 38m + 55m2 , e0 = 220m6 . The zeros (> 1) of ei , 2  i  6, are m = 1.16271 . . . , 1.63834 . . . , 2.1653 . . . , 2.71099 . . . , 3.26585 . . ., and e0 , e1 are positive for m  1. Then, Descartes rule of signs proves (i), where 3.26585 . . . is a positive zero (> 1) of the terms inside the braces of e6 . (ii) Similarly, f2 in (A.10) becomes f2 (c) =

4 64m2  i ei c , (1 + c)4

(A.13)

i=0

where 

k4 = (m − 1) −37 − 54m − 141m2 + 87m3 , k3 = −4 + 88m + 165m2 − 684m3 + 384m4 , k2 = −5 + 71m + 69m2 − 684m3 + 522m4 ,   k1 = 3m2 −3 − 76m + 116m2 , k0 = 87m4 . The zeros (> 1) of ki , 2  i  4, are m = 1.07847 . . . , 1.56103 . . . , 2.02972 . . ., and k0 , k1 are positive for m  1. Then, Descartes rule of signs proves (ii), where 2.02972 . . . is a positive zero (> 1) of the terms inside the braces of k4 . (iii) Here we only have to note the following.   7m − 13 1 = 171305064 + 1014680952(m − 1) f1 15 421875 + 2576715615(m − 1)2 + 3602331260(m − 1)3

 f2

7m − 13 15

+ 2918812410(m − 1)4 + 1292214612(m − 1)5  + 242391031(m − 1)6 (> 0),

 =

16m2 663201 + 2809692(m − 1) + 4497399(m − 1)2 5625  2 + 3216418(m − 1)3 + 865066(m − 1)4 (> 0).

266

Z. Habib, M. Sakai / Computer Aided Geometric Design 24 (2007) 252–266

Combine Lemmas A.1 and A.2 to show that 8r2 r4 − 3r32 > 0 for r3 < 0, i.e., φ(s) is upward opening as claimed in case 2 (c3 < 0) in the proof of Theorem 3.2. References Burchard, H., Ayers, J., Frey, W., Sapidis, N., 1993. Designing Fair Curves and Surfaces, Ch. Approximation with aesthetic constraints. Farin, G., 1997. Curves and Surfaces for Computer Aided Geometric Design: A Practical Guide, 4th ed. Academic Press, New York. Farouki, R., Sakkalis, T., 1990. Pythagorean hodographs. IBM Journal of Research and Development 34, 736–752. Gibreel, G.M., Easa, S.M., Hassan, Y., El-Dimeery, I.A., 1999. State of the art of highway geometric design consistency. ASCE Journal of Transportation Engineering 125 (4), 305–313. Guggenheimer, H., 1963. Differential Geometry. McGraw-Hill, New York. Habib, Z., Sakai, M., 2005a. Spiral transition curves and their applications. Scientiae Mathematicae Japonicae 61 (2), 195–206. e2004, 251–262, http://www.jams.or.jp/scmjol/2004.html. Habib, Z., Sakai, M., 2005b. G2 PH quintic spiral transition curves and their applications. Scientiae Mathematicae Japonicae 61 (2), 207–217. e2004, 263–273, http://www.jams.or.jp/scmjol/2004.html. Habib, Z., Sakai, M., 2007. On PH quintic spirals joining two circles with one circle inside the other, Computer-Aided Design 39 (2), 125–132. http://dx.doi.org/10.1016/j.cad.2006.10.006. Habib, Z., Sakai, M., Sarfraz, M., 2004. Interactive shape control with rational cubic splines. Computer-Aided Design & Applications 1 (1–4), 709–718. Habib, Z., Sarfraz, M., Sakai, M., 2005. Rational cubic spline interpolation with shape control. Computers & Graphics 29 (4), 594–605. http://dx.doi.org/10.1016/j.cag.2005.05.010. Hartman, P., 1957. The highway spiral for combining curves of different radii. Transactions of the American Society of Civil Engineers 122, 389–409. Henrici, P., 1988. Applied and Computational Complex Analysis, vol. 1. Wiley, New York. Hickerson, T.F., 1964. Route Location and Design. McGraw-Hill, New York. Meek, D.S., Walton, D.J., 1989. The use of Cornu spirals in drawing planar curves of controlled curvature. Computational and Applied Mathematics 25, 69–78. Sakai, M., 1999. Inflection points and singularities on planar rational cubic curve segments. Computer Aided Geometric Design 16, 149–156. Sarfraz, M. (Ed.), 2004. Geometric Modeling: Techniques, Applications, Systems and Tools. Kluwer, Dordrecht. Sarfraz, M., 2005. A rational cubic spline for the visualization of monotone data: An alternate approach. Computer & Graphics 27, 107–121. Walton, D.J., Meek, D.S., 1996. A Pythagorean hodograph quintic spiral. Computer-Aided Design 28 (12), 943–950. Walton, D.J., Meek, D.S., 2002. Planar G2 transition with a fair Pythagorean hodograph quintic curve. Computational and Applied Mathematics 138, 109–126. Walton, D.J., Meek, D.S., Ali, J.M., 2003. Planar G2 transition curves composed of cubic Bézier spiral segments. Computational and Applied Mathematics 157 (2), 453–476.