APPROXIMATION and INTERPOLATION CURVES

Approximation (interpolation) is a generating principle, which enables to model connected curve segments from the discrete ordered sets of points in the extended Euclidean space. Intrinsic geometric properties of the modelled curves depend on the form of the polynomial interpolation functions determining the analytic representations of the modelled figures, it means on the values of the coefficients in the powers of the variable u. Required geometric properties of the resulting curve segment determine the conditions for calculation of these coefficients. In general, the interpolation polynomials

Pli(u)=ainun+ain-1un-1+...+ai1u+ai0

must satisfy the following condition:
sum of the polynomials related to the real points of the basic figure
(in the given order) is equal to 1

(1)

Analytic representation of the modelled curve segment determined by the ordered n-tuple of points
represented analytically by the map

M=( Pi(xi , yi , zi , hi ) ), i=1, ..., n, where hi = 0, 1

and created by applying an approximation (interpolation) determined by the interpolation matrix

I(u)=( Pl1(u) Pl2(u) ... Pln(u) )

is the point function of the required properties on I=<0,1>

We distinguish two different types of modelling:

interpolation - all points of the basic figure are located on the created figure called interpolation curve segment
approximation - all points of the basic figure need not be located on the created figure called approximation curve segment.

Modelling can be applied to the whole ordered set, n-tuple of points, or it can be modelled by parts, while the created curve is composed from elementary curve segments, usually cubic ones. Both modelling methods of curve segments have tsome advantages and some disadvantages.
If we apply the interpolation on the whole
n-tuple of points, the resulting curve is of the degree n-1, it has many extremal points (with extremal curvatures in some points, or points of inflection) and usually it is not possible to change its shape locally (in the neighbourhood of some point only), modelling of the curve is not flexible.
In modelling by parts it is important to provide continuity and smoothness of the resulting curve in the common points of the separate adjoining curve segments, by the equality of some elements of the adjoining curve segments basic figures, it means in the input data structure for the computer processing. These data files are usually in the practical applications very large and not easy to convey, and their change is very difficult and inconvinient.
We will speak about several types of modelled curve segments most frequently used in the CAD systems of the computer based design and modelling.

Cubic curve segment is the curve segment with the basic figure in the form of the ordered quadruple of the points in the extended Euclidean space

Pi=(xi, yi, zi, hi) , for i=0, 1, 2, 3,   where hi = 0, 1

Generating principle is an approximation (interpolation) determined by the ordered set of cubic interpolation polynomials

Pli(u)=aiu3+biu2+ciu+di , for i=0, 1, 2, 3

satifying the condition (1).

1. Ferguson cubic (cubic interpolation curve segment)

Ferguson cubic is the interpolation curve segment determined by the start and the end points and tangent vectors in these points. Interpolation is determined by cubic Hermit polynomials.

Synthetic representation:     ({P0, P1, a 0, a1}, I(u) )
Analytic representations:
basic figure -   P0=(x0, y0, z0, 1)  P1=(x1, y1, z1, 1)
a0=(xA0, yA0, zA0, 0)      a1=(xA1, yA1, zA1, 0)
map of the curve segment         M =( P0 P1 a0 a1)
generating principle -         I(u)=(F0(u), F1(u), G0(u), G1(u)), where
F0(u)=2u3-3u2+1       F1(u)= -2u3+3u2        G0(u)=u3-2u2+u       G1(u)=u3-u2
are Hermit interpolation polynomials, while
modelled figure -   r(u)=M.IT(u)= P0F0(u)+ P1F1(u)+ a0 G0(u)+ a1G1(u), uÎ<0,1>

It is valid:               r(0)=P0     r(1)=P1     (0)=a0    (1)= a1

The start point of the Ferguson cubic segment is the point P0, the end point is the point P1.
Tangent vector in the point
P0 to the curve is the vector a0, in the point P1 the vector a1.
Geometric properties of the modelled curve segment determine the conditions for the calculation of coefficients of the used interpolation polynomials. The name Hermit polynomials is related to the name of the mathematician Hermit, who lived in the 19th century and used these polynomials for the interpolation of functions. Applied generating principle is known as the Hermit cubic interpolation.
Coordinates of the interior points on the Ferguson cubic segment can be calculated from the curve point function for the values of the point curvilinear coordinates in the interval (0,1).

In the majority of the practical applications, the interpolation curve is determined only by the ordered set of real points, which must be located on the resulting curve. Tangent vectors determining the curvatures (flection and torsion) in the given point on the modelled curve segment are inserted empirically, and their choice depends on the skill of the user. These can cause, in general, a rather serious problem in the industrial design and modelling, because tangent vectors influence deeply the shape of the resulting curve segments.
In the more sofisticated CAD systems, there is provided the possibility to determine tangent vectors with respect to the form of the basic figure - the ordered set of real points in the space, so that the resulting interpo
lation curve has the "quiet flow", it copies the shape of the basic polygon without large extremes.
One of the methods for determination of the tangent vectors in the point on the interpolation curve widely used in the practise is the
Akima interpolation.
Let Pi-2 Pi-1 Pi Pi+1 Pi+2 be the part of the basic polygon
determined by the points of the interpolation curve basic figure (Fig. 3. 31).
Akima construction can be used to determine the tangent vector in the point
Pi on the curve.
Let us find first points
Ai, Bi a Ci, for which the following is valid

Pi-2Pi-1 Ç PiPi+1 =Ai
Pi-1Pi Ç Pi+1Pi+2 =Bi
AiBi Ç Pi-1Pi+1 =Ci
ti=PiCi , if Ci is the ideal point, then

AiBi // Pi-1Pi+1 // ti, | ti|=| Pi-1Pi+1 |

In the first (last) two points of the ordered sequence of points in the basic figure it is necessary to determine tangent vectors by a different method, for example as the tangent vectors to the conic section segment (parabola) passing through the first (last) three points.

A different method to determine tangent vectors is the D-interpolation, in which the tangent vector a in the point Pi is determined as the linear combination of the vectors formed by the given point and two other points of the basic figure,
point Pi-1 (proceeding the tangent point)
and point Pi+1 (succeeding the tangent point) (Fig. 3. 32).

j=

Vector a is the image of the vector b in the orhogonal mapping to the vector of the sum di.

Interpolation cubic determined by the basic figure { P0 P1 a0 a1}, in which the tangent vectors are determined by
the D-interpolation, and for which the generating interpolation polynomials are Hermit ones, is called the
D-spline cubic.

Owerhauser cubic is the interpolation curve determined by the ordered n-tuple of points and Hermit interpolation, while tangent vectors to the curve are determined in the start point and in the end point, only.

2. Bézier cubic (cubic approximation segment)

Bézier cubic is the approximation curve determined by the four real points in the basic figure. Approximation is determined by Bernstein cubic polynomials.

Synthetic representation:     ({P0 ,P1 ,P2 ,P3}, I(u))
Analytic representations:
basic figure -     Pi=(xi, yi, zi, 1) , for i=0,1,2,3
map of the curve segment     M=(P0 P1 P2 P3)
generating principle -     I(u)=(Be03(u) Be13(u) Be23(u) Be33(u)), where
Be03(u)=(1-u)    Be13(u)=3u(1-u)2     Be23(u)=3u2(1-u)    Be33(u)=u3
are Bernstein approximation polynomials, while .
modelled figure    r(u)=M.I(u)=P0Be03(u)+P1Be13(u)+P2Be23(u)+P3Be33(u), uÎ<0,1>

It is valid:     r(0)= P0    r(1)=P3    r(0)=3 P0 P1    r(1)=3 P2 P3

The start point of the curve segment is the point P0 and tangent vector to the curve segment in this point is the three multiple of the vector in the first side of the basic polygon - 3P0P1. The end point is the point P1, tangent vector in this point is the three multiple of the vector in the last side of the basic polygon - 3P2P3. Given geometric properties of the modelled cubic curve segment are provided by the used Bernstein polynomials, called by the Russian mathematician Bernstein, who used them for the approximation of functions ulready in the year 1912.
The general formula for calculation of these polynomials of degree
n is

, for i=0,...,n, where n is the degree.

Homogeneous coordinates of the interior points on the Bézier cubic with the curvilinear coordinates in the interval (0,1) can be calculated from the point function.
Point on the Bézier cubic can be constructed by the
algorithm Boor - de Casteljau (Fig. 3. 34).

Let a=1/3 be the curvilinear coordinate of the point on the cubic in the interval (0,1).
In the one third of the length from the start point on each of the sides of the basic polygon P0P1 , P1P2 , P2P3
there are located points P0', P1', P2' determining new basic figure, which can be reduced by the same construction up to one line segment P0''P1''
and then to one point P(1/3) located on the Bézier segment.
Tangent vector in this point is determined as
r(1/3)=P0P1.

3. Coons B-spline cubic (cubic approximation curve segment)

Coons B-splie cubic is the approximation curve determined by four real points in the basic figure. Approximation is defined by Coons cubic polynomials (obr. 3.35).

Synthetic representation:     ({P0, P1, P2, P3}, I(u))
Analytic representations:
basic figure -     Pi=(xi, yi, zi, 1) , for i=0,1,2,3
map of the curve segment     M=(P0 P1 P2 P3)
generating principle - I(u)=(Co03(u) Co13(u) Co23(u) Co33(u)), where
Co03(u)=            Co13(u)=

Co23(u)=            Co33(u)=
are Coons approximation polynomials, while .
modelled figure -   r(u)=M.IT(u)=P0Co03(u)+P1Co13(u)+P2Co23(u)+P3Co33(u), uÎ<0,1>

It is valid :      r(0)=((P0+P2)/2+2P1)/3     r(0)=(P2-P0)/2

r(1)=((P1+P3)/2+2P2)/3    r(1)=(P3-P1)/2

The start point of the curve segment is the anticentre of the gravivity in the triangle P0P1P2 located on the median passing through the vertex P1 to the centre of the side P0P2 in one third of its size from the vertex P1 .
The end point of the curve segment is the anticentre of the gravity in the triangle P1P2P3
located on the median passing through the vertex P2 to the centre of the side P1P3 in one third of its size from the vertex P2 .
Tangent vectors in these points are collinear to the vectors P0+P2 , P1+P3.
Geometry of the modelled curve segment is provided by Coons polynomials called after the American computer graphician Coons, which are special types of B-spline cubic polynomials.

The fact, that the modelled curve does not contain any point of the basic figure and in modelling it is not clear, where are located the start and the end points of the curve segment, causes a certain disadvantage in the practical usage of B-spline cubics in the computer aided design.
The input basic figure, an ordered quadruple of real points {P0 , P1 , P2 , P3}, can be substituted by a new basic figure
- suplementary basic polygon {Q0 , Q1 , Q2 , Q3}, which can be constructed in the way,
that points P0 and P3 be the start and the end points of the approximation B-spline curve segment
with the basic figure in the new suplementary basic polygon {Q0 , Q1 , Q2 , Q3},
curve can be "prolonged" to the points P0 and P3 (Fig. 3.36).

|Q1P1|=|P1P2|=|P2Q2|
|Q´0P0|=|P0P1|
|Q0Q´0|=2|Q´0Q1|
|Q´3P3|=|P3P2|
|Q3Q´3|=2|Q´3Q2|

In all forthcoming types of modelled curves it is possible to reach the change in the shape of the curve only by the change of elements in the basic figure, which represent the input data file for the computer processing. This file is in practical situations very large one and not easy to convey, which limits the modelling power of the user. Change of the intrinsic properties of the modelled curve segment can be also reached by the change of the generating principle, it means by the change of the used polynomial functions, having the possibility to change cofficients of these polynomials through several input parameters.

4. b-spline cubic (cubic approximation curve segment)

b-spline cubic is the approximation curve determined by the ordered quadruple of real points in the space. Approximation is defined by b-spline cubic polynomials.

Synthetic representation:  ({P0 , P1 , P2 , P3}, I(u))
Analytic representations:
basic figure -     Pi=(xi, yi, zi, 1) , for i=0,1,2,3
map of the curve segment     M=(P0 P1 P2 P3)
generating principle - I(u)=(Ba03(u) Ba13(u) Ba23(u) Ba33(u)), where
Ba03(u) =
Ba13(u) =
Ba23(u) =
Ba33(u) =
are b-spline approximation polynomials.
modelled figure -      r(u)=M.IT(u)=P0 Ba03(u)+P1Ba13(u)+P2Ba23(u)+P3Ba33(u), uÎ<0,1>

Coefficients of b-spline polynomials are functions of two real parameters, influencing the intrinsic properties of the modelled curve segments.

Parameter b1 - tension influences the position of the strat and the end points of the curve segment, it
"takes" the curve to the first, or to the last point of the basic figure.

Parameter b2 - torsion influences the first curvature of the modelled curve segment in its interior points,
"stretches" ("looses") the curve towards (from) the side
P1P2 of the basic figure.
If
b1=1 and b2=0, we receive Coons B-spline polynomials.

5. Rational cubics (cubic approximation curve segments)

Rational cubic is the approximation curve determined by the ordered quadruple of real points in the space and positive weights of these points (chosen representants from the class of homogeneous coordinates of points). Weight of the point expresses the scale, in which the point has to influence the shape of the modelled curve. Approximation is determined by cubic polynomials.

Synthetic representation:     ({h0P0 , h1P1 , h2P2 , h3P3}, I(u))

Analytic representations:

basic figure -     Pi=hi(xi, yi, zi, 1), hi>0, for i=0,1,2,3
map of the curve segment          M=(h0P0 h1P1 h2P2 h3P3)
generating principle -     I(u)=(Pl03(u) Pl13(u) Pl23(u) Pl33(u)), where
Pli3(u) for i=0,1,2,3 are approximation cubic polynomials - Bernstein, B-spline, b-spline, for which
modelled figure -     rational extension of the cubic approximation curve
(Bézier, Coons, B-spline,
b-spline) represented by the point function
R(u)=M.IT(u)= ,
where H(u)= is the weight function, non-zero for uÎ<0,1>.

Rational approximation cubic curve segment is for uÎ<0,1> determined by the rational point function

With respect to the size of the weight of each point in the basic figure the shape of the modelled curve segment can be modified.
For values h0= h1= h2= h3 the modelled curve segment is related Bézier, Coons B-spline or
b-spline cubic segment.

Segments of conic sections can be modelled as approximation Bézier rational quadratic segments (Fig. 3. 38).

Synthetic representation:        ({h0P0 h1P1 h2P2 }, I(u))

Analytic representations:

basic figure -     Pi=hi(xi, yi, zi,1), hi>0, for i=0,1,2
map of the curve segment      M=(h0P0 h1P1 h2P2)
generating principle -     I(u)=(Be02(u) Be12(u) Be22(u)), where
Be02(u)=(1-u)2        Be12(u)=2u(1-u)        Be22 (u)=u2

are Bernstein approximation polynomials of the degree two
modelled figure        R(u) = M.IT(u)=
r(u)=R(u)/H(u), H(u)= , uÎ<0,1>,     h0=1-r, h1=r, h2=1-r, r=
Point O is the centre of the line segment P0P2
and point P=PE (PP or PH)
is the point on the modelled segment of conic section, which is
ellipse     for r<0,5
parabola     for r=0,5
hyperbola     for r>0,5
In modelling of rational approximation curves by parts - piecewise modelling, where the adjoining segments of different degrees are composed, we speak about non-uniform rational curves.
NURBS - non-uniform rational B-spline curves are suposed to be approximation curves of the most variable practical usage, due to their rather easy analytic representations, possibility to change locally the shape of the modelled curve by the change of the weight related to the appropriate point of the basic figure (it is not necessary to change its homogeneous coordinates) and the possibility to create the composed curve from curve segments of different degrees with respect to the required shape of the resulting curve.
In the Fig. 3. 39 there are used Ferguson cubic segments in modelling letters of the Greec alphavit, in the Fig. 3. 49 there is the word modelled from Bézier cubic segments. Bézier cubics are most frequently used approximation curves in the graphical software packages (SketchPad, AutoCAD, MSGraph, CorellDraw, CorellFlow) and they are included also in drawing menues provided by many text editors (MSWord, AmiPro, Word Pro, and other).
Fig. 3. 39