Bernstein Polynomials Bzier Curves de Casteljaus Algorithm Shenqiang
Bernstein Polynomials, Bézier Curves, de Casteljau‘s Algorithm Shenqiang Wu Computer Aided Geometric Design Ferienakademie 2004 1
Content Ø 1. Motivation Ø 2. Problems of Polynom Interpolation Ø 3. Bézier Curves Ø 3. 1 Bernstein Polynomials Ø 3. 2 Definition of Bézier Curves Ø 3. 3 Evaluation Ø 4. Summary Computer Aided Geometric Design Ferienakademie 2004 2
Motivation (1/2) Target : better control over the curve’s shape Background: Computer-supported automobile and aircraft design Bézier (Renault) and de Casteljau (Citröen) both developed independent from each other around 1960/65 descriptions of curves with the following attributes: Ø Substitutes of pattern drawings by CAD Ø Flexible manipulation of curves with guaranteed and controllable shape of the resulting curve Ø Introduction of control points that not necessarily lie itself on the curve Computer Aided Geometric Design Ferienakademie 2004 3
Motivation (2/2) Typical applications are: Ø Car design, aircraft design, and ship design Ø Simulation of movements Ø Animations, movie industry and computer graphics Modelling of objects with free-form-surfaces Computer Aided Geometric Design Ferienakademie 2004 4
Problems of Polynom Interpolation (1/2) Polynom interpolation is an easy and unique method for describing curves that also contain some „nice“ geometrical attributes. Ø Polynom interpolation is not the method of choice within CAD applications due to better curve descriptions (as we will see later). Reason: polynom interpolation may oscillate Ø Computer Aided Geometric Design Ferienakademie 2004 5
Problems of Polynom Interpolation (2/2) Problems: Ø The polynomial interpolant may oscillate even when normal data points and paramter values are used. Ø The polynomial interpolant is not shape preserving. This has nothing to do with numerical effects, it‘s due to the interpolation process. Ø Too high costs for interpolation process: huge amount of necessary operations for constructing and evaluating the interpolant. Computer Aided Geometric Design Ferienakademie 2004 6
Bernstein Polynomials (1/2) Ø Method of approximation: Bézier polynomials Ø Preliminaries: Bernstein polynomials Def. : A Bernstein polynomial of grade n has the following description with binomial coefficients Computer Aided Geometric Design Ferienakademie 2004 7
Bernstein Polynomials (2/2) Ø Ø i-times null in t=0, (n-i)-times null in t=1 Ø Proof: Ø Ø Attributes of Bernstein polynomials: Computer Aided Geometric Design Ferienakademie 2004 8
Basis functions of Bernstein Polynomials Bernstein-Polynome vom Grad 4 Computer Aided Geometric Design Ferienakademie 2004 9
Bézier Curves (1/2) Def. : The following curve b 2 Control polygon is called Bézier curve of grade n with control points b 0, …, bn Bézier curve b 3 b 1 The complete form of a Bézier polynomial of grade 3, for example, with control points b 0, …, bn looks as follows: Computer Aided Geometric Design Ferienakademie 2004 b 4 10
Bézier Curves (2/2) Different Bézier Curves with its control polygons Computer Aided Geometric Design Ferienakademie 2004 11
Attributes of Bézier Curves (1/9) Attributes of Bézier curves: Ø x(0)=b 0 and x(1)=bn, that means the Bézier curve lies on b 0 and bn. Ø x‘(0)=n(b 1 -b 0) and x‘(1)=n(bn-bn-1) (tangents in start and end point) Ø Values x(t) are a convex combination of the control points Ø The Bézier curve entirely lies in its control polyeder or control polygon Computer Aided Geometric Design Ferienakademie 2004 12
Attributes of Bézier curves (2/9) Ø Bézier curves are invariant under projections Ø Bézier curves are symmetric within their control points Ø Are all Bézier points collinear the Bézier curve becomes a line Ø Bézier curves are shape preserving: non negative (monoton, convex…) data leads to a non negative (monoton, convex…) curve Computer Aided Geometric Design Ferienakademie 2004 13
Attributes of Bézier Curves (3/9) Endpoint interpolation and attributes of tangents: b 0 A Bézier curve interpolates the first and the last point of its control polygon and has the first and last line element of its control polygon as tangent. control polygon bn line element Bézier curve Computer Aided Geometric Design Ferienakademie 2004 line element 14
Attributes of Bézier Curves (4/9) Convex hull property: A Bézier curve lies within the convex hull of its control polygon. Computer Aided Geometric Design Ferienakademie 2004 15
Attributes of Bézier Curves (5/9) Variation diminishing property: Given: Bézier curve, any kind of line or plane A Bézier curve doesn’t change the sides of any line or plane not more often as its control polygon. 3 1 2 3 Sample lines 1 2 3 1 Computer Aided Geometric Design Ferienakademie 2004 16
Attributes of Bézier Curves (6/9) Linear precision: Are the control points b 0, . . . , bn of a Bézier curve collinear the Bézier curve itself becomes a line. Control polygon bn Bézier curve b 0 Computer Aided Geometric Design Ferienakademie 2004 17
Attributes of Bézier Curves (7/9) Subdivision: Given is a Bézier curve with its control polygon (b 0, . . . , bn) resp. [0, 1]. b 2 b 1 c 2 Sometimes it’s necessary to cut ac 1 single Bézier curve into two parts, both together being identically to the originating curve. 1. The subdivision algorithm from de Casteljau leads to the control polygons (c 0, . . . , cn) and (d 0, . . . , dn) of the Bézier curves within the intervals [0, t] and [t, 1], resp. c 0 c 3 d 0 d 1 d 2 b 3 d 3 b 0 Computer Aided Geometric Design Ferienakademie 2004 Example: n=3 18
Attributes of Bézier Curves (8/9) b 2 b 1 Subdivision: Given is a Bézier curve with its control polygon (b 0, . . . , bn) 2. Successively subdivision with de Casteljau’s algorithm leads to a series of polygons fast converging to the curve. b 3 b 0 Computer Aided Geometric Design Ferienakademie 2004 19
Attributes of Bézier Curves (9/9) Subdivision: Given is a Bézier curve with its control polygon (b 0, . . . , bn) b 2 b 1 3. Cutting off edges doesn’t lead to further changes of sides. Variation diminishing property b 3 b 0 Computer Aided Geometric Design Ferienakademie 2004 20
Increase of Grade of Bézier curves (1/2) Ø Problem: After a Bézier polygon has been modified several times, it can be seen that the curve of grade n is not flexible enough to represent the desired shape. Ø Idea: Add one edge without changing the current shape of the curve. Ø Solution: Increase the grade of the Bézier curve from n to n+1, thus, the new Bézier points Bk can be determined from the old Bézier points bi as follows: Computer Aided Geometric Design Ferienakademie 2004 21
Increase of Grade of Bézier Curves (2/2) Increase of grade: both polygons describe the same (cubic) curve Application: Design of surfaces Ø Data exchange between different CAD and graphic systems Ø Computer Aided Geometric Design Ferienakademie 2004 22
Evaluation of Bézier Curves Method for determination of single curve points, i. e. determination of x(t) for some t: Ø Recursive calculation of Bernstein polynomials Ø de Casteljau‘s algorithm Computer Aided Geometric Design Ferienakademie 2004 23
Recursive Calculation Recursive calculation of Bernstein polynomials According to this definition Bézier curves are calculated with the help of Bernstein polynomials. Example of a cubic Bézier curve Computer Aided Geometric Design Ferienakademie 2004 24
de Casteljau‘s Algorithm (1/2) b 11 b 02 b 03 b 01 b 2 b 12 b 21 b 3 b 0 0 t 1 Geometric construction according to de Casteljau‘s algorithm for n=3 and t=2/3 Computer Aided Geometric Design Ferienakademie 2004 25
de Casteljau‘s Algorithm (2/2) de Casteljau‘s algorithm i=0, …, n: It can be described with the following scheme: k=1, …, n: i=k, …, n: This leads to Computer Aided Geometric Design Ferienakademie 2004 26
Example: De Casteljau‘s Algorithm (1/2) Ø Given: Bézier curve of grade 4 Ø With Bézier points Ø Wanted for Computer Aided Geometric Design Ferienakademie 2004 27
Example: de Casteljau‘s Algorithm (2/2) de Casteljau scheme for the x-component de Casteljau scheme for the y-component 1 0 1 6 7. 5 0 2 5. 5 0. 4 0. 6 4. 0 6. 9 0. 52 2. 64 1. 8 5. 74 4. 5 3. 42 = x(t=0. 6) 1. 2 4. 1 5. 5 6. 7 2. 9 4. 14 3. 6 4. 9 4. 174 = y(t=0. 6) Resultat: X(t=0. 6)=(x, y)=(3. 42, 4. 174) Computer Aided Geometric Design Ferienakademie 2004 28
Rating of Bézier Curves (1/2) Local changes of control points have global effects, but their influence is only of local interest: The change control point is only significant within the scope of the. Rating of Bézier curves according to controlability and locality: Computer Aided Geometric Design Ferienakademie 2004 29
Rating of Bézier Curves (2/2) Problems: Ø Double points are possible, i. e. the projection is not bijetive Ø Complex shapes of the desired curves may result in a huge amount of control points that again leads to a high ploynomgrade. Computer Aided Geometric Design Ferienakademie 2004 30
Further Freeform Curves NURBS B-Splines Computer Aided Geometric Design Ferienakademie 2004 31
Freeform Surfaces Bézier surface Computer Aided Geometric Design Ferienakademie 2004 32
Computer Aided Geometric Design Ferienakademie 2004
- Slides: 33