BITS Pilani: ME F318: Computer Aided Design Tutorial/Assignment - 4
BITS Pilani: ME F318: Computer Aided Design Tutorial/Assignment - 4
Tutorial/Assignment - 4
BITS Pilani
Hyderabad Campus
Tutorial Problems
T1. For the quadratic B-spline curve developed for 4 control points, (a) find the parametric equation of the B-spline curve, and (b) prove that
the curve is tangent to the mid-point of the internal control polygonal segment. The control points are given by:
1 4 10 8
P0 , P1 , P2 , P3
1 4 5 1
T2. A Bezier curve is defined for the following four control points.
n+k+1=3+3+1=7
i 0 i 0
P0 N 0,3 (u ) P1 N 1,3 (u ) P2 N 2,3 (u ) P3 N 3,3 (u )
N 0, 2 (u ) N 1, 2 (u ) N 2, 2 (u ) N 3, 2 u N 4, 2 u
N 0,1 (u ) N 1,1 (u ) N 2,1 (u ) N 3,1 u N 4,1 u N 5,1 u
1 u0 1 0 u 1
N 0,1 N 1,1 N 2,1
0 elsewhere 0 elsewhere
1 1 u 2 1 u2
N 3,1 N 4,1 N 5,1
0 elsewhere 0 elsewhere
N i , k 1 (u ) N i 1, k 1 (u )
N i , k (u ) (u ui ) (ui k u )
(ui k 1 ui ) (ui k ui 1 )
where
1, ui u ui 1
N i ,1
0, otherwise
N 0,1 (u ) N 1,1 (u ) N 0,1 (u ) N 1,1 (u )
N 0, 2 (u ) (u u 0 ) (u 2 u ) (u 0) (0 u ) 0
(u1 u 0 ) (u 2 u1 ) (0 0) (0 0)
N 1,1 (u ) N 2,1 (u ) N 1,1 (u ) N 2,1 (u )
N 1, 2 (u ) (u u1 ) (u 3 u ) (u 0) (1 u ) 1 u N 2,1 (u )
(u 2 u1 ) (u 3 u 2 ) (0 0) (1 0)
N 2,1 (u ) N 3,1 (u ) N 2,1 (u ) N 3,1 (u )
N 2, 2 (u ) (u u 2 ) (u 4 u ) (u 0) (2 u ) uN 2,1 (u ) 2 u N 3,1 (u )
(u 3 u 2 ) (u 4 u 3 ) (1 0) (2 1)
N 3,1 (u ) N 4,1 (u ) N 3,1 (u ) N 4,1 (u )
N 3, 2 (u ) (u u 3 ) (u 5 u ) (u 1) (2 u ) u 1N 3,1 (u )
(u 4 u 3 ) (u 5 u 4 ) (2 1) (2 2)
N 4,1 (u ) N 5,1 (u ) N 4,1 (u ) N 5,1 (u )
N 4, 2 (u ) (u u 4 ) (u 6 u ) (u 2) (2 u ) 0
(u 5 u 4 ) (u 6 u 5 ) (2 2) (2 2)
Pu P0 (1 u ) 2 N 2,1 (u ) P1 u 1 u N 2,1 (u )
2 u uN (u ) 2 u N (u )
2 ,1 3,1
2
u
P2 uN 2,1 (u ) 2 u N 3,1 (u ) 2 u (u 1) N 3,1 (u ) P3 u 1 N 3,1 (u )
2
2
Writing N2,1 and N3,1 terms separately, we get the parametric equation in
two segments.
u 2 u u 2
P0 (1 u ) P1 u 1 u
2
P2 , 0 u 1
2 2
Pu
P 2 u 2
u 2 u
2 u (u 1) P3 u 1 , 1 u 2
2
2
1 P2
2
(b) For four control points, there is only one internal control polygonal segment from P1 to P2. Its midpoint is = (P1+P2)/2
= ([4;4]+[10;5])/2 = [7, 4.5], which should occur on the curve at u = 1. We may use either of the two segments of the B-
spline to prove it. Using the second segment:
4 2 5 2 1
1 4 1 10 7
0 proved.
2 4 2 5 4.5
The tangent vector along the control polygonal segment is P2-P1 = [10;5]-[4;4]=[6;1]. To prove that the curve is tangent at
this point, find the tangent vector on the B-spline curve at u = 1.
2 P0 (1 u ) P1 2 3u P2 u, 0 u 1
P' u
P1 2 u P2 (1 u ) 3 2u 2 P3 u 1, 1 u 2
Bezier curve remains invariant in shape hence transformation of the control points is sufficient to transform the whole curve.
The location of the point with transformed control points with [T] as the rotational transformation is:
cos60 sin 60 0 0
sin 60 cos60 0 0
[T ]
0 0 1 0
0 0 0 1
(A) The first three of the four control points of a Bezier curve are as given below. At a value of the parameter u in its range the
point is [6.83, 4.72]. The sum of the first three Bernstein polynomials is 0.65. Find the point and tangent vector at u/m, where
m is the average of the last three digits in your ID number.