B Spline vs Bezier curves
In CAGD applications, a curve may have a so complicated shape that it cannot
be represented by a single Bézier cubic curve since the shape of a cubic
curve is not rich enough. Increasing the degree of a Bézier curve adds
flexibility to the curve for shape design. However, this will significantly
increase processing effort for curve evaluation and manipulation. Furthermore,
a Bézier curve of high degree may cause numerical noise in computation.
For these reasons, we often split the curve such that each subdivided segment
can be represented by a lower degree Bézier curve. This technique is known
as piecewise representation. A curve that is made of several Bézier
curves is called a composite Bézier curve or a Bézier spline
curve. In some area (e.g., computer data exchange), a composite Bézier
cubic curve is known as the PolyBézier. If a composite Bézier
curve of degree n has m Bézier curves, then the composite Bézier curve
has in total m×n+1 control vertices.
A curve with complex shape may be represented by a composite Bézier curve
formed by joining a number of Bézier curves with some constraints at the
joints. The default constraint is that the curves are jointed smoothly. This
in turn requires the continuity of the firstorder derivative at the joint,
which is known as the firstorder parametric continuity. We may relax
the constraint to require only the continuity of the tangent directions at the
joint, which is known as the firstorder geometric continuity. Increasing
the order of continuity usually improves the smoothness of a composite Bézier
curve. Although a composite Bézier curve may be used to describe a complex
shape in CAGD applications, there are primarily two disadvantages associated
the use of the composite Bézier curve:
 It is considerably involved to join Bézier curves with some order
of derivatives continuity.
 For the reason that will become clear later, a composite Bézier curve
requires more control vertices than a Bspline curve.
These disadvantages can be eliminated by working with spline curves.
Originally, a spline curve was a draughtsman's aid. It was a thin elastic wooden
or metal strip that was used to draw curves through certain fixed points (called
nodes). The resulting curve minimizes the internal strain energy in the splines
and hence is considered to be smooth. The mathematical equivalent is the cubic
polynomial spline. However, conventional polynomial splines are not popular
in CAD systems since they are not intuitive for iterative shape design. Bsplines
(sometimes, interpreted as basis splines) were investigated by a number
of researchers in the 1940s. But Bsplines did not gain popularity in industry
until de Boor and Cox published their work in the early 1970s. Their recurrence
formula to derive Bsplines is still the most useful tool for computer implementation.
It is beyond the scope of this section to discuss different ways of deriving
Bsplines and their generic properties. Instead, we shall take you directly
to the definition of a Bspline curve and then explain to you the mathematics
of Bsplines. Given M control vertices (or de Boor points) d_{i}
(i = 0,1,¼,M1), a Bspline curve of order k (or degree
n = k1) is defined as
r(u) = 
M1
å
i = 0

d_{i} N_{i,k}(u), 

where, N_{i,k}(u) are polynomials of degree n and known as Bsplines
of order k. Analogous to Bézier curves, N_{i,k}(u) are also called
the Bspline basis functions. In most practical applications, the Bspline
basis functions are derived from the following knot vector (or knot
sequence):
u_{0} = u_{1} = ¼ = u_{n}, u_{k} £ ¼ £ u_{j} £ ¼ £ u_{M1}, u_{M} = u_{M+1} = ¼ = u_{M+n} 

where, u_{i} are called knots. The reason to select the first and
last k knots to be equal is that the control vertices d_{0}
and d_{M1} are the points on the curve. Furthermore, the tangent
direction of the curve at d_{0} is from d_{0} to
d_{1} and the tangent direction at d_{M1} is from
d_{M2} to d_{M1}. Due to these properties, the
shape of a Bspline curve resembles the shape of its control polygon formed by
the control vertices d_{i}, although such resemblance is not as
intuitive as that of a Bézier curve. In the literature, the Mk knots u_{k},
u_{k+1}, ¼, u_{M1} are sometimes called
the interior knots. If the interior knots are all distinct, then the Bspline
curve has Mk nonvanishing spans (i.e., the arc length of each span is not zero).
As we said previously, there are several methods to derive the Bspline basis
functions N_{i,k}(u) in terms of the knot vector. We present only the
recursive formula derived by de Boor and Cox as follows:
N_{i,k}(u) = 
uu_{i}
u_{i+k1}u_{i}

N_{i,k1}(t)+ 
u_{i}u
u_{i+k}u_{i+1}

N_{i+1,k1}(u), 

with
These basis functions have the following properties:
 The basis functions sum to 1, i.e., å_{i = 0}^{M1}N_{i,k}(u) = 1. This means that, similar
to a Bézier curve, a Bspline curve lies also within the convex hull.
 N_{i,k}(u) > 0 for u_{i} < u < u_{i+k}
and, elsewhere, N_{i,k}(u) = 0. This is known as the local support
property of Bsplines. In other words, a change of the control vertex
d_{i} affects the Bspline curve locally only for u_{i}
< u < u_{i+k}.
 If the interior knots are distinctive, N_{i,k}(u) has continuity
of order k2. This implies that a Bspline curve has parametric continuity
of order k2 across all the spans.