Computer Aided Geometric Design 22 (2005) 27–43 www.elsevier.com/locate/cagd
Smooth surface extension with curvature bound Hoisub Kim a , Seungtaik Oh b , Jin-whan Yim b,∗ a Department of Mathematics, Kyungwon University, Songnamsi, Kyonggido, 461-701, South Korea b Department of Mathematics, Korea Advanced Institute of Science and Technology, Daejon, 305-701, South Korea
Received 12 November 2003; received in revised form 1 August 2004; accepted 2 August 2004 Available online 28 August 2004
Abstract For a given surface with a piecewise smooth boundary, a new method to extend the surface across its boundary is suggested. The extended surface is C 2 -continuous along the old boundary, and some extra conditions can be imposed on the new boundary. Furthermore, it is shown that normal curvature of the extended part of the surface can be controlled by predetermined conditions. In order to test the effectiveness of our algorithm, it is shown that surfaces with rectangular and circular boundaries can be extended with all necessary conditions satisfied. 2004 Elsevier B.V. All rights reserved. Keywords: Surface extension; Curve extension; Curvature
1. Introduction In manufacturing or modelling of a solid surface, it is sometimes helpful or necessary to extend an existing surface across its boundary. A surface may be given by polynomial equations or spline, and there are many ways to extend or extrapolate the underlying surface depending on one’s need and situation. The simplest way to extend a polynomial surface is to use the same polynomial equation for a larger domain, but polynomial functions usually fluctuate more widely for larger values of variables and it becomes unacceptable for some purposes. Spline surfaces suffer similar shortfalls and require more sophisticated methods. In many cases, notably due to the nature of manufacturing methods or tools, some * Corresponding author.
E-mail addresses:
[email protected] (H. Kim),
[email protected] (S. Oh),
[email protected] (J.-w. Yim). 0167-8396/$ – see front matter 2004 Elsevier B.V. All rights reserved. doi:10.1016/j.cagd.2004.08.003
28
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
geometric constraints are imposed on the surface and these constraints are to be maintained on the extended part of the surface. Sometimes other additional requirements such as the C 2 continuity across the boundary or extra boundary conditions on the extended surface need to be imposed to produce an optimal outcome. One way to smoothen data from an experiment or a surface design is the least square method to form a polynomial or a B-spline surface (Kim, 1997; Hayes and Halliday, 1974). In this case, the formula usually yields a well-defined surface without too much error inside some predetermined effective domain where the data is available, but outside the effective domain it becomes unacceptable for manufacturing tools or part design with physical specifications. It is therefore required to extend the surface within a reasonable distance. In this kind of situation, it is certainly possible to extend the surface mathematically with various types of extension operators (Stein, 1970; Gilbarg and Trüdinger, 1983). But the problem with commonly used extension operators is that they are insensitive to the curvature and sometimes the extension range is too short for engineering applications. In engineering design or modelling of parts, the required curves or surfaces usually have a very complicated geometric shape and there is no universal solution for the extension problem. It is therefore practically a case-by-case problem and there are some works in various directions (Kim, 1997; Shetty and White, 1991; Wolters, 2000). In this article, we study a surface extension method motivated by the following engineering problem. We try to present our geometric arguments and surface generating algorithm in a general setting, but its application will be focused on this example. Let us consider designing process of a correction lens used in the Color Display Tube (CDT) of a monitor set (Fig. 1). The electron beams from the lamp do not land on right spots of the fluorescent screen as they are supposed to, and this mislanding should be corrected by a lens, called a correction lens (Lens-2 in Fig. 1). In order to increase the sharpness of pictures on the screen, it is of utmost importance to have a proper correction lens. In designing a correction lens, some finite number of points on the screen are chosen and the mislanding errors are measured at these points. The data from these sampling points together with the least square method are used to generate a surface for the correction lens.
Fig. 1. Exposure process.
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
29
As we can see in the picture, the correction lens is placed in the middle of the screen and the lamp which has a single point source in computation of ray-tracing. Due to this structural problem, the effective area of the correction lens is relatively small compared to its actual size needed for mounting. Of course, the generating formula for the effective area can be used for a larger region, but this leads to another problem. The correction lens has a large curvature compared to other surfaces in the tube and the fluctuation produced by the generating formula outside the effective region can be troublesome for manufacturing. Therefore, an efficient method is needed to extend the effective area of the lens with geometric property suitable for manufacturing. Of course, the surface of lens is curved for the deflection property, and the surface has to be second order differentiable in order to compute curvature. It is also true that the size of grinding tool yields a constraint on normal curvature of the final outcome, and it is necessary to maintain the curvature bound and the geometric continuity on the extended surface. We may formulate our problem as follows. We are concerned with a surface with a piecewise smooth boundary and want to extend this surface across its boundary, which consists of a number of smooth curves. There are some geometric constraints on the surface, and along the new boundary created by the extended surface, one may impose some extra conditions depending on needs. These conditions are given by boundary values and derivatives. In our case, the surface represents a lens with an effective region of rectangular shape, and we will make the extended lens to have a constant thickness and right angle edge along the boundary. With these conditions along the new boundary of the extended surface, it can be extended further as a flat surface with a fixed thickness. Then we can cut and manipulate the surface into any shape in this flat area. This is certainly an ideal condition for our purpose, but one may impose other similar conditions on the boundary. The geometric constraint we are interested in is normal curvature, which measures how much a surface is curved in each tangent direction. There are several kinds of curvatures, and they measure how much a geometric object is curved in various ways. It has been widely studied to control or measure the quality of a visualized surface in terms of curvatures. The quality or fairness of a surface can be measured and studied by curvature (Beck et al., 1986; Farin and Sapidis, 1989; Hagen et al., 1992; Pottmann and Opitz, 1994; Sapidis and Koras, 1999), and sometimes the numerical computation of curvature becomes a subject of study (Chuang and Hoffmann, 1990; Meek and Walton, 2000; Wollmann, 2000). The normal curvature characterizes an extrinsic geometry of a surface in a surrounding space while Gaussian curvature characterizes an intrinsic geometry. Therefore, it may be fair to say that the normal curvature is the most important factor to control the visual shape of a surface in space. For this reason, the normal curvature is not only an important geometric property of a surface in mathematical point of view, but it is also frequently studied concept in engineering applications. A given surface will be extended in such a way that the tangential continuity and the curvature continuity across the boundary is achieved while there is a normal curvature bound. The surface we are going to consider is in graph form, z = f (x, y), over a domain in the (x, y)-plain. Any smooth surface can be broken into patches of surfaces in this form, and the condition we have is not very restrictive. In order to meet all these requirements, we consider the projected image of given surface in the (x, y)-plain and use a multi-step polynomial extension in the normal direction of the boundary curve of domain. A bound on the normal curvature will be determined by given boundary conditions and two parameters, the extension parameter and the control parameter, which will show up in the multi-step process. The key ingredient in our method and arguments is the geometry of curves on the surface. The geometric properties of curves on the surface will be transferred to the geometry of their projected images on the (x, y)-plane and the
30
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
functional properties of the height function f (x, y). Therefore, all the conditions and constraints are also given in terms of plane curves on the parameter space and the height function. In the following sections, we will provide some mathematical background for our argument of surface extension with the continuity, normal curvature bound and boundary conditions. We also provide numerical examples to demonstrate the effectiveness of our method. Our extension method only requires derivatives of a given surface along the boundary, and hence it can be used for any surface as long as these derivatives can be computed. The surface we will use for the numerical examples is the correction lens we discussed above, and it is given by a polynomial function of two variables. The extended surface will be also defined as a function of two variables. With this function, it is an easy task to generate the extended surface, but we also provide an algorithm to generate the surface by spline.
2. Construction of the surface extension In this section, we explain how to extend a given surface with the C 1 or C 2 continuity along boundary. At each point of the existing boundary, we attach a curve satisfying all necessary conditions. Putting these curves together we obtain an extended surface patch which meets the given surface along the boundary with the C 1 or C 2 continuity. Moreover, the construction of the extended surface will be made so that it has a sufficiently small curvature bound. For most practical purposes, the C 1 -continuity (continuity of surfaces up to the first order derivatives) is quite enough, and it is much easier with the C 1 -continuity to control curvature of the extended part of surface. In some cases, however, second order derivatives of surface are crucial and one needs to have continuity up to the second order derivatives. We will consider both cases. The C 2 extension is achieved by a small modification of the C 1 extension, and hence their geometric nature will not be very different from each other. This process is necessary because as mentioned above it is easier to control curvature with the C 1 extension. In other words, even for the C 2 extension, we will use the C 1 extension with almost same geometric characteristic to find an upper bound of curvature. This section consists of two subsections. We will first show how to extend a curve at each boundary point, and then explain how to construct a surface. 2.1. Construction of a family of curves covering the surface For a given curve segment, we make an extended curve with the C 1 or C 2 continuity, which satisfies some boundary conditions at the other end and has properly bounded derivatives up to the second order. This is accomplished by using two special non-uniform splines. A quadratic spline is used for the C 1 continuity, and a cubic spline for the C 2 continuity. Let us first consider the C 1 quadratic extension. For some fixed number l > 0, which will be called the extension parameter, let α(t) = (t, f (t)), 0 t l, be a non-uniform quadratic spline with three knots at t = 0, t = σ and t = l. Let Li and Ri be the left and right end conditions of α(t), respectively, for i = 0, 1. The left end condition Li is for the C 1 -continuity with the given curve, and the right end condition Ri is to be decided by users. Then the non-uniform quadratic spline α(t) satisfying the boundary conditions is uniquely determined by the middle knot σ , which will be called the control parameter. Denote by α1 (t) and α2 (t) the two quadratic curves forming α(t). We first write αi (t) in terms of the Bernstein polynomial bases of degree two as follows;
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
31
t = , 0 t σ, α1 (t) = σ i=0 2 t 2 t −σ = , σ t l, ai+2 Bi α2 (t) = l − σ f2 (t) i=0
t f1 (t)
2
ai Bi2
where Bi2 is the Bernstein polynomial of degree two and ai ’s are the control points given by σ 0 σ 2 , a1 = , a2 = , a0 = a0 a2 a1 σ +l l 2 , a4 = . a3 = a3 a4 From the end conditions and the intermediate C 1 condition, it is easy to see that ai ’s are given by 1 0 0 0 a0 L0 σ a1 0 0 1 2 (l−σ ) σ (l−σ ) L1 σ (l−σ ) σ − 2l . a2 = l 2l l R0 ) a3 0 0 1 − (l−σ 2 R1 a4 0 0 1 0
(1)
Since αi (t), i = 0, 1, is quadratic, we have the second order derivatives in simple forms. −2(L0 − R0 ) − (l + σ )L1 − (l − σ )R1 , σl 2(L0 − R0 ) + σ L1 + (2l − σ )R1 . f2 (t) = (l − σ )l
f1 (t) =
Note that the second order derivatives depend on the difference (L0 − R0 ) as one may expect. It is also clear that our C 1 extension α(t) is the simplest C 1 -spline with the lowest degree which satisfies the above end conditions up to the first order. We now consider the C 2 extension. As mentioned earlier, the C 2 extended curve is given by a nonuniform cubic spline, which is a slight modification of the C 1 extension α(t). This modification makes it possible for the C 2 extension to have the almost same second order derivatives as the C 1 extension over the quadratic part. Since the previous C 1 extension α(t) is quadratic, its second order derivative has constant values with discontinuity at the first two knots, t = 0 and t = σ . In order to obtain the C 2 continuity, we use the linear interpolation of the second order derivatives over [0, ε] and [σ, σ + ε] (see Fig. 2). Of course, the remaining quadratic parts of α(t) should be properly modified for the boundary conditions. Denote the resulting new curve by β(t) = (t, g(t)), 0 t l. Then the component function g(t) is given by g1 (t), 0 t ε, g (t), ε t σ, 2 g(t) = g 3 (t), σ t σ + ε, g4 (t), σ + ε t l,
32
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
Fig. 2. Cubic spline extension and its second order derivative.
where g1 (t) and g3 (t) are cubic polynomials and g2 (t) and g4 (t) are quadratic polynomials with g2 (t) = m and g4 (t) = n as in Fig. 2. We again put βi (t) = (t, gi (t)), i = 0, 1, 2, 3, and write these curves as
β1 (t) =
3 i=0
β2 (t) =
2
bi Bi3
t , ε
bi+3 Bi2
i=0
β3 (t) =
3
bi+5 Bi3
i=0
β4 (t) =
2 i=0
bi+8 Bi2
0 t ε,
t −ε , σ −ε
ε t σ,
t −σ , ε
σ t σ + ε,
t −σ −ε , l−σ −ε
σ + ε t l,
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
33
where bi ’s are the control points to be determined in the same manner as the C 1 case. We will have to decide the second components bi ’s only. By the end conditions, we have 1 0 0 0 0 L0 b0 ε b1 0 0 0 1 L1 3 2 ε 2ε L2 , b2 = 1 3 0 0 6 σ +ε−l b9 R0 0 0 0 1 2 b10 R1 0 0 0 1 0 and by the continuity condition at knots we have b A −2ε 0 0 0 3
b4 B b 0 5 = 2 b6 ε b7 0 b8 0
2ε 2 2ε −2ε 2 0 0
−ε 2 −A −B 0 0
0 3C 6C 2 0 3D 2
0 0 −3C 2 −3D −6D 2
0 −1 3Cb2 2 0 3C (2b2 − b1 ) 0 0 , 0 0 E 2εb9 2 F ε (b10 − 2b9 )
where A = 3σ − ε, B = 3(σ − ε)2 − ε 2 , C = σ − ε, D = l − σ − ε, E = 3l − 3σ − ε and F = 3(l − σ − ε)2 − ε 2 . It is certainly possible to write down the solutions explicitly in terms of Li and Ri , but they are quite long and it is better to leave the task to a numerical solver when one has a specific problem. Note that as ε → 0 we have m → f1 (t), n → f2 (t) and b0 = b1 = b2 = b3 , b5 = b6 = b7 = b8 . Therefore, the above equations become identical to the equation (1) with b0 = a0 , b4 = a1 , b5 = a2 , b9 = a3 and b10 = a4 . If we take ε > 0 small enough, then any visual difference between the C 1 and C 2 extensions becomes negligible. 2.2. Surface parametrization Consider a surface in graph form, S(x, y) = (x, y, f (x, y)), in terms of the standard (x, y)-coordinate of a domain Ω ⊂ R2 . Suppose that the domain Ω has a piecewise smooth boundary with possible vertices. We first explain how to extend the given surface along a smooth part of the boundary ∂Ω, and then provide an argument for the vertices. Denote by c(s) a smooth part of ∂Ω parametrized by the arc-length parameter s ∈ [s0 , s1 ]. Hence c (s) ≡ 1. We will extend the surface along c(s) by attaching a one-parameter family of curves consisting of quadratic or cubic splines we discussed above. For each s ∈ [s0 , s1 ], let n(s) be the outward unit normal vector of the domain Ω at the point c(s). Then, for a suitable value of the extension parameter l > 0, the map (s, t) → (x(s, t), y(s, t)) = c(s) + tn(s) is a diffeomorphism from the parameter space [s0 , s1 ] × [0, l] to a collar neighborhood of Ω. We therefore use (s, t) as a coordinate system for the extended part of the surface (Fig. 3). The extension parameter l has to be chosen carefully depending on the convexity of the boundary so that the extended surface is well defined. We will explain how to find this number in the next section. As an example, if we have a circular boundary x 2 + y 2 = R 2 , then c(s) = (R cos Rs , R sin Rs ) and n(s) = (cos Rs , sin Rs ). Therefore the map (x(s, t), y(s, t)) = c(s) + tn(s) = ((R + t) cos Rs , (R + t) sin Rs ), 0 s 2π , 0 t l, defines a coordinate system for the annulus around the disk.
34
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
Fig. 3. Parametrization of extension domain.
If we use the coordinate (s, t) to parametrize the extended surface S, then S(s, t) = (x(s, t), y(s, t), z(s, t)) = (c(s) + tn(s), h(s, t)), where h(s, t) is the height function. For each fixed s ∈ [s0 , s1 ], h(s, t) = αs (t) is identified as a quadratic or cubic spline in Section 2.1. In the next section, we will show that normal curvature of this surface is bounded by the derivatives of h(s, t), and we need to show how these derivatives can be controlled. As mentioned earlier, the C 2 extension can be made arbitrarily close to the C 1 extension, and all of their derivatives up to the second order can be controlled by almost same bounds. Therefore we only have to estimate derivatives of the C 1 extension. Let us decompose h(s, t) into two parts, h1 (s, t) and h2 (s, t), coming from α1 (t) and α2 (t), respectively. In other words, 2 1 2 t , 0 t σ, ai (s)Bi h (s, t) = σ i=0 2 2 2 t −σ , σ t l. ai+2 (s)Bi h (s, t) = l −σ i=0 Note that the coefficients ai ’s are determined by the boundary conditions as in (2). In fact, they are linear combinations of L0 , L1 , R0 and R1 with coefficients depending on some chosen constants l and σ . The left end conditions L0 and L1 represent the boundary conditions of the given surface S, and the right S. In general, end conditions R0 and R1 are the conditions for the new boundary of the extended surface they are functions of s if a particular boundary curve c(s) is given. Therefore, in order to have an upper bound on the curvature of the extended surface, it suffices to show that the derivatives of h(s, t) can be controlled in terms of l, σ and ai ’s. Remark. The one-parameter family of extended curves are constructed independently for each s ∈ [s0 , s1 ]. Therefore it is quite possible to obtain a surface extension with varying parameters l and σ as long as they change smoothly as functions of s-variable. Of course, there are certain restrictions on
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
35
l(s) and σ (s) imposed by the geometry of boundary curve, but the surface extension can be carried out in the exactly same manner as the constant case. The only reason we have chosen constant parameters is to simplify the following computation of derivatives. If we choose varying parameters, then the width of extended part will vary and the inner knot can change its position. With this freedom, we will have more flexibility in surface extension and may have better control over the quality of the extension. For any reason, if one needs more flexibility of extended surface, varying parameters can be used. For instance, one may want to distribute curvature (either normal or Gaussian) of the extended part of surface as evenly as possible. Then it will certainly require very flexible surface extension, and varying parameters will help. Most likely, this type of optimization process will yield some conditions on parameter functions. However, the price for this advantage is that the derivatives of the height function h(s, t) will also depend on the derivatives of l(s) and σ (s), and the subsequent computation will require much more sophisticated mathematical analysis. In our case, we only want a simple bound on the normal curvature, and we will use constant parameters hereafter. From the convex hull property of Bézier curves, it is easy to estimate the derivatives of h(s, t) (Farin, 2002; Filip et al., 1986) and we have 1 h (s, t) max a (s), a (s), a (s) , s 0 1 2 1 h (s, t) 2 max a1 (s) − a0 (s), a2 (s) − a1 (s) , t σ 2 (2) h (s, t) max a (s), a (s), a (s) , s 2 3 4 2 h (s, t) 2 max a3 (s) − a2 (s), a4 (s) − a3 (s) . t l −σ In addition, the second order derivatives are bounded by 1 h (s, t) max a (s), a (s), a (s) , ss 0 1 2 1 h (s, t) 2 max a (s) − a (s), a (s) − a (s) , st 1 0 2 1 σ 1 h (s, t) 2 a2 (s) − 2a1 (s) + a0 (s), tt σ2 2 (3) h (s, t) max a (s), a (s), a (s) , ss 2 3 4 2 2 h (s, t) max a3 (s) − a2 (s), a4 (s) − a3 (s) , st (l − σ ) 2 2 a4 (s) − 2a3 (s) + a2 (s). h (s, t) tt 2 (l − σ ) It is now an easy task to write down the above inequalities in terms of Li , Ri , l and σ . The extension parameter l is decided by how far one needs to extend the given surface and the convexity of the boundary curve, and the control parameter σ has to be decided when a specific bound for the curvature is given. Note that as σ increases the bounds for |h1t |, |h1st | and |h1t t | decrease while those for |h2t |, |h2st | and |h2t t | increase, and vice versa. Therefore, if the curvature tolerance limit one wants to achieve is not very large, then the control parameter σ has to be chosen carefully. We now consider the case that the boundary curve ∂Ω has vertices. We will only have to explain how to parametrize the extension domain in a collar neighborhood of Ω, and hence all the subsequent arguments
36
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
(a)
(b)
(c)
(d)
Fig. 4. Extension method for boundary curve with vertices.
and figures are in the (x, y)-plane. At a vertex, two smooth boundary curves meet with a certain angle. If they meet in a concave way, then it is in general impossible to extend the surface smoothly around the vertex. We will explain this point in the next section. We therefore assume that the projected image of the existing surface in the (x, y)-plane is convex around the vertex in question. The easiest way to obtain a smooth curve from a curve with vertices is by replacing a small neighborhood of each vertex with a C 2 -continuous curve as in (Fig. 4(a)). This is a very simple and efficient process, but there is one shortcoming that this method ruins a small portion of the original domain and can not be used when one wants to leave effective area unchanged. This method however has an advantage that our extension scheme can be applied in one step after all corners are rounded off and boundary conditions are easily satisfied. For the second method, we first choose one of two smooth boundary curves meeting at a vertex (left edge in Fig. 4(b)) and extend it beyond the vertex with C 2 -continuity. In fact, a portion of a parabola will do the job. Along the extended part of the first curve, we put necessary initial data which is also a continuous extension of the existing data at the vertex. For this C 2 -continuous extended boundary curve we apply our surface extension algorithm. In the resulting enlarged parameter space, we extend the other boundary curve (right edge in Fig. 4(b)) with C 2 -continuity, and apply the surface extension algorithm again for the second extended boundary. In the case that two smooth boundary curves meet with an obtuse angle at the vertex, we do not even need to extend the first curve (Fig. 4(c)). Repeat this process for all
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
37
vertices to obtain a global extension. This method works without much difficulty when one has a simple boundary condition such as a flat end along outer boundary. In fact we use this method for our example, which has a boundary with straight line segments and extensions by straight lines suffice. If we are very stingy about effective area and have outer boundary conditions other than a flat end, we will have to utilize the two methods in combination. We first use the second method to obtain an extended surface which does not necessarily satisfy the given boundary condition, and then cut it with a smooth boundary curve along the extended part of the surface (Fig. 4(d)). We then apply the extension algorithm for this smooth boundary curve to obtain an extended surface satisfying the outer boundary condition.
3. Curvature bound In this section, we explain in some detail how to obtain an upper bound for normal curvature of extended surfaces in terms of the derivatives of the height function h(s, t), which we discussed in the previous section. The normal curvature of a surface measures how much the surface is curved in each tangent direction. A grinding tool with a certain curvature cannot produce a surface with normal curvature larger than that of the tool. Therefore, for constraints imposed by manufacturing tools and other practical reasons, the normal curvature of a surface becomes an important factor. The existing surface is assumed to be well within this curvature constraint and we want our extended surface to obey the same rule. In (2) and (3), we obtained bounds for the derivatives of h(s, t), and we use standard geometric arguments to show that the normal curvature of the extended surface S is bounded by these derivatives. For a smooth surface S, let γ (τ ) be a curve on S with γ˙ (τ ) = 1, where τ is a time parameter and γ˙ (τ ) denotes the derivative with respect to the τ -variable. Then γ¨ (τ ) is the acceleration vector and its length κ = γ¨ (τ ) is the curvature of γ . If U denotes the unit normal vector of S, then the normal component κn = |γ¨ (τ ) · U | is the normal curvature of S at γ (τ ) in γ˙ (τ )-direction. It is an elementary fact in classical differential geometry that the normal curvature is a property of surface and it dose not depend on any particular choice of curve γ but only its tangent direction as long as the curve stays on the surface (do Carmo, 1976). It is now easy to see that if γ (τ ) is not of unit speed, then the normal curvature is given by κn = |γ¨ · U |/γ˙ 2 . We assume that an extended surface S is parametrized by (s, t) and can be expressed as a graph of a function, that is, S(s, t) = (x(s, t), y(s, t), h(s, t)) = (c(s) + tn(s), h(s, t)), where c(s), s ∈ [s0 , s1 ], and n(s) are the boundary curve and the normal vector, respectively, as in Fig. 3. Then the function k(s) = n (s) · c (s) = −n(s) · c (s) represents the oriented curvature of the boundary curve c(s) in the (x, y)-plane. For a convex boundary we have k(s) > 0, and for a concave boundary k(s) < 0. The normal curvature of the extended surface can be controlled by the height function h(s, t) and the boundary curvature function k(s). We have the following theorem. given by the height function h(s, t) along the smooth boundary Theorem 1. For an extended surface S c(s) with the oriented curvature k(s), the normal curvature κn is bounded above by a positive number N , which is determined by k(s) and h(s, t). Proof. In order to find an upper bound of normal curvature of S, we consider a curve γ (τ ) = (x(τ ), y(τ ), h(s(τ ), t (τ ))) on the surface in an arbitrary direction. Since normal curvature is a property of surface and not influenced by any particular choice of curve, we choose a curve γ (τ ) on the surface
38
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
so that (x) ˙ 2 + (y) ˙ 2 = 1 and (x, ¨ y) ¨ = 0. In other words, the projected image of γ in the (x, y)-plane is a straight line with unit speed. Then γ˙ (τ ) = (x, ˙ y, ˙ hs s˙ + ht t˙) and γ¨ (τ ) = (0, 0, dτd (hs s˙ + ht t˙)). Since ˙ 2 + (y) ˙ 2 + (hs s˙ + ht t˙)2 1, the normal curvature in γ (τ ) direction is given by γ˙ (τ )2 = (x) κn =
|γ¨ · U | γ¨ γ¨ . 2 γ˙ γ˙ 2
Therefore, in order to control the normal curvature, it suffices to have an upper bound on γ¨ . By the chain rule of differentiation, we have d hss hst s˙ γ¨ = (hs s˙ + ht t˙) = (˙s , t˙) + (hs s¨ + ht t¨ ). dτ hst ht t t˙
(4)
For the first term in (4), we use the first assumption of γ (τ ). Since (x(s, t), y(s, t)) = c(s) + tn(s) with c (s) = n(s) = 1, we have (5) (x, ˙ y) ˙ = s˙ c (s) + s˙ tn (s) + t˙n(s) = s˙ (1 + k(s)t) c (s) + t˙n(s). ˙ 2 + (y) ˙ 2 = 1, we have (˙s (1 + k(s)t))2 + t˙2 = 1. Put u = s˙ (1 + k(s)t) By the assumption, (x, ˙ y) ˙ 2 = (x) 2 and v = t˙. Then (u, v) ∈ R is a unit vector and hss hst s˙ u hss hst (1+k(s)t ) (1+k(s)t )2 ˙ = (u, v) . (˙s , t ) h st ˙ hst ht t t v ht t (1+k(s)t )
In order estimate this number, we use a general fact about a quadratic form. For any symmetric matrix to H = ab bc and a unit vector v = (u, v), we have |vH vT | = |au2 + 2buv + cv 2 | |a|u2 + |b|(u2 + v 2 ) + |c|v 2 2 max |a|, |b|, |c| . For the second term in (4), we use the assumption, (x, ¨ y) ¨ = 0. By differentiating Eq. (5) once more, we see that 2k(s)˙s t˙ + k (s)˙s 2 t 2k(s)uv k (s)u2 t |¨s | = (1 + k(s)t)2 + (1 + k(s)t)3 1 + k(s)t |k (s)|t |k(s)| + , (1 + k(s)t)2 |1 + k(s)t|3 k(s)u2 2 |k(s)| . |t¨| = k(s)˙s (1 + k(s)t) = 1 + k(s)t |1 + k(s)t|
We therefore put |hss (s, t)| |hst (s, t)| , h , (s, t) N = sup 2 max tt |1 + k(s)t|2 |1 + k(s)t| 0t l s0 ss1
+
|k(s)hs (s, t)| t|k (s)hs (s, t)| |k(s)ht (s, t)| , + + |1 + k(s)t|2 |1 + k(s)t|3 |1 + k(s)t|
and obtain the normal curvature bound, κn N .
(6)
2
In the definition of N , the derivatives of h(s, t) can be controlled by the inequalities (2) and (3). In practical applications, |k(s)| and |k (s)| are not very large along smooth boundary. For instance, k(s) =
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
39
k (s) = 0 for a straight line and k(s) = R1 , k (s) = 0 for a circle with radius R. Nevertheless, we may assume that there are upper bounds for |k(s)| and |k (s)| for all s ∈ [s0 , s1 ]. If the boundary of a domain is convex, then the oriented boundary curvature k(s) > 0 and the denominators in (6) can be replaced by 1. On the other hand, if the boundary is concave, then k(s) < 0 and the denominators vanishes at t0 = 1/|k(s)|. In this case, the point (x(s, t0 ), y(s, t0 )) is called the focal point of ∂Ω, and (s, t) fails to be a coordinate system beyond this point. A surface can not be smoothly extended beyond a focal point by a normal extension technique as ours. Therefore, if any part of the boundary is concave, the extension parameter l has to be determined with respect to this constraint. The extreme case of a concave boundary is a vertex with concave angle. In this case, the oriented curvature is considered to be negative infinity, and the extension parameter becomes zero, and that means the surface can not be extended at all. We remark that the estimation process we used above may look crude in some places, but in fact the normal curvature bound we have is sharp. Consider a surface given as the graph of the height function h(s, t) = s 2 + 2st + t 2 . Assume that the boundary is a straight line segment and hence k(s) = 0. Take a curve γ (τ ) = ( √τ2 , √τ2 , 2τ 2 ) on the surface passing through (0, 0, 0). Then we have γ˙ (0) = ( √12 , √12 , 0), γ¨ (0) = (0, 0, 4), and U (0, 0, 0) = (0, 0, 1). Hence γ˙ (0) = 1, γ¨ · U = 4, and we obtain κn = 4 at the origin. On the other hand, we clearly have hss (0, 0) = hst (0, 0) = ht t (0, 0) = 2, hs (0, 0) = ht (0, 0) = 0, and we have an equality case for the normal curvature bound.
4. Examples As an application of our surface extension, we consider the correction lens in the CDT of a monitor set. In the correction lens design, it is necessary to extend an effective surface patch across the boundary for mounting. Therefore, the most favorable condition for the new boundary is given by R0 = C, R1 = 0, where the constant C is determined by the average thickness of the lens in the effective region. In manufacturing the lens, a spherical grinder of approximate radius 10 is used, and hence the curvature of the intended surface has to be less than 1/10. We have to find an extended surface satisfying these conditions. The effective region of the actual correction lens in our example is given by a polynomial surface (Kim, 1997), aij x i y j , |x| x0 , |y| y0 , (7) f (x, y) = i,j
where aij ’s are given in Table 1, and x0 = 38.2, y0 = 21.4. Since we intend to obtain a surface extension defined on a larger domain {(x, y) | |x| x1 , |y| y1 }, (x1 > x0 , y1 > y0 ), four consecutive extension processes are needed for a rectangular boundary. We first extend the rectangular surface along the boundaries y = −y0 and y = y0 , and then use this extended surface as the initial surface for the extension along x = −x0 and x = x0 . Let us consider the extension process for the boundary y = y0 . The remaining cases are similar. In this case, we have s = x, (−x0 s x0 ) and t = y − y0 , and hence hss = hxx , hst = hxy , ht t = hyy . We put R0 = −0.4 and R1 = 0, and the coefficients ai ’s in (1) become a0 (x) = L0 (x), a1 (x) = L0 (x) +
σ L1 (x), 2
40
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43 Table 1 Coefficients of the polynomial function representing the correction lens i
j
aij
i
j
aij
0 0 0 0 0 0 2 2 2 2 2 2 4 4 4 4 4 4
0 2 4 6 8 10 0 2 4 6 8 10 0 2 4 6 8 10
0.00000000E-00 −2.50064258E-05 −5.46532922E-08 1.43962314E-11 −1.42112785E-15 4.86035452E-20 −9.13339401E-04 4.83272601E-07 −6.11532697E-11 −6.61007998E-15 1.49012388E-18 −6.53187487E-23 4.01394923E-07 −2.72558956E-10 4.72483589E-14 −1.01584216E-18 −3.11301792E-22 1.76480711E-26
6 6 6 6 6 6 8 8 8 8 8 8 10 10 10 10 10 10
0 2 4 6 8 10 0 2 4 6 8 10 0 2 4 6 8 10
−5.75358992E-11 4.30475702E-14 −8.76987792E-18 5.39463081E-22 1.08957985E-26 −1.47247954E-30 3.40474091E-15 −2.72783230E-18 6.20138278E-22 −5.23854744E-26 1.12103641E-30 3.15963648E-35 −7.23012417E-20 6.10470695E-23 −1.50140687E-26 1.49507799E-30 −5.74230033E-35 4.01954173E-40
y1 − y0 − σ σ σ a2 (x) = × 0.4, L0 (x) + L1 (x) − y1 − y0 2 y1 − y0 a3 (x) = −0.4, a4 (x) = −0.4. To estimate the second order derivatives of the extended surface, we put l = y1 − y0 and σ = lδ. Then the second order derivatives of the C 1 extension can be estimated as 1 h (x, y) L (x) + lδ L (x), xx 0 1 2 1 2 L0 (x) + 0.4 + 1 + δ L1 (x), h (x, y) yy 2 l δ lδ 2 1 h (x, y) L (x) + L (x), xy 1 l 0 2 h (x, y) (1 − δ)L (x) + lδ(1 − δ) L (x), xx 0 1 2 2 2 δ L0 (x) + 0.4 + L1 (x), h (x, y) yy l 2 (1 − δ) l(1 − δ) 2 2 h (x, y) L (x) + δ L (x). xy 1 l 0 In our case, the boundary curve is a straight line, and hence k(s) = k (s) ≡ 0. Therefore we only need the second order derivatives, and we have the curvature bound (6) of the extended surface. κn 2 max |h1xx |, |h1yy |, |h1xy |, |h2xx |, |h2yy |, |h2xy | .
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
41
In our numerical test, we set x1 = 2x0 = 76.4 and y1 = 2y0 = 42.8. Then the derivatives of L0 and L1 are easily computed from the polynomial function (7) along each boundary, and the curvature bound is obtained. We have to choose the control parameter 0 < δ < 1 so that the above second derivatives are properly bounded. In our case, the original surface is quite flat and we can choose δ = 1/2. Then the above inequality are further simplified to 1 3 |L0 + 0.4| + |L1 |, |h1xy | |L0 | + |L1 |, |h1xx | |L0 | + 6|L1 |, |h1yy | 100 20 and 1 1 1 1 1 |h2xx | |L0 | + 3|L1 |, |h2yy | |L0 + 0.4| + |L1 |, |h2xy | |L0 | + |L1 |. 2 100 20 10 2 −1 Along the boundary y = y0 , we have |L0 (x) + 0.4 = f (x, y0 ) + 0.4| 3.8 × 10 , |L0 (x) = fx (x, y0 )| 2 × 10−2 , |L0 (x) = fxx (x, y0 )| 1.5 × 10−3 , |L1 (x) = fy (x, y0 )| 7.6 × 10−3 , |L1 (x) = fxy (x, y0 )| 4.8 × 10−4 and |L1 (x) = fxxy (x, y0 )| 5.6 × 10−5 . Therefore we have the curvature bound κn 2.3 × 10−2 . The actual curvature bound for the extended surface for this boundary is computed to be 6 × 10−3 ,
(a)
(b) Fig. 5. (a) Extension by the polynomial function, (b) extension by the new method. The effective regions are shown by a rectangular path.
42
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
(a)
(b) Fig. 6. Effective region and extended surfaces with circular boundaries.
and it is verified that our curvature bound is not very crude and the final extended surface is within the curvature tolerance limit 1/10. We have similar bounds for other boundaries as well. In Fig. 5, the effective region, the extended surfaces by the original polynomial function and our method are illustrated. Another example we want to consider has a circular boundary. We use again the surface given by the function (7). This time we use the polar coordinate and assume that the effective region is a disk of radius r0 = 38.2 with center at the origin. The extended surface will be a disk of radius r = 2r0 . Therefore the extended part is an annulus and the extension parameter l = r0 . The oriented curvature of the boundary circle is k(s) ≡ 1/r0 and k (s) ≡ 0 in (6). Similar computations as the rectangular case can be carried out, and we have the curvature bound κn 4.4 × 10−3 . The actual bound for the extended surface is 3.3 × 10−3 , and it is verified that the curvature bound is well within the tolerance limit 1/10. The same pictures as in the rectangular case are shown in Fig. 6.
Acknowledgements The authors would like to thank the referees for their valuable comments and suggestions.
H. Kim et al. / Computer Aided Geometric Design 22 (2005) 27–43
43
References Beck, J., Farouki, R., Hinds, J., 1986. Surface analysis method. IEEE Comput. Graph. Appl. 6, 18–36. Chuang, J.-H., Hoffmann, C.M., 1990. Curvature computations on surfaces in n-space. Math. Modelling Numer. Anal. 26, 95–112. do Carmo, M.P., 1976. Differential Geometry and Curves and Surfaces. Prentice Hall. Farin, G., Sapidis, N., 1989. Curvature and the fairness of curves and surfaces. IEEE Comput. Graph. Appl. 9, 52–57. Farin, G., 2002. Curves and Surfaces for CAGD: A Practical Guide. Morgan Kaufmann. Filip, D., Magenson, R., Markot, R., 1986. Surface algorithms using bounds on derivatives. Computer Aided Geometric Design 3, 295–311. Gilbarg, D., Trüdinger, N.S., 1983. Elliptic Partial Differential Equations of Second Order. Springer-Verlag. Hagen, H., Hahmann, S., Schreiber, T., 1992. Surface interrogation algorithms. IEEE Comput. Graph. Appl. 12, 53–59. Hayes, J.G., Halliday, J., 1974. The least-squares fitting of cubic spline surfaces to general data sets. J. Institute Math. Appl. 14, 89–103. Kim, H.S., 1997. On the construction of a surface from discrete derivative data and its extended surface using the least squares method. Korean J. Comput. Appl. Math. 4, 387–396. Meek, D.S., Walton, D.J., 2000. On surface normal and Gaussian curvature approximations given data sampled from a smooth surface. Computer Aided Geometric Design 17, 521–543. Pottmann, H., Opitz, K., 1994. Curvature analysis and visualization for functions defined on Euclidean spaces or surfaces. Computer Aided Geometric Design 11, 655–674. Sapidis, N.S., Koras, G.D., 1999. Visualization of curvature plots and evaluation of fairness: an analysis of the effect of ‘scaling’. Computer Aided Geometric Design 14, 299–311. Shetty, S., White, P.P., 1991. Curvature-continuous extensions for rational B-spline curves and surfaces. Computer-Aided Design 23, 484–491. Stein, E.M., 1970. Singular Integrals and Differentiability Properties of Functions. Princeton University Press, New Jersey. Wollmann, C., 2000. Estimation of the principle curvatures of approximated surfaces. Computer Aided Geometric Design 17, 621–630. Wolters, H.J., 2000. Extensions: extrapolation methods for CAD, HP Laboratories Technical Report HPL-2000-37.