Example 1.  Construct the natural cubic spline for the 7 points  [Graphics:Images/B-SplinesMod_gr_111.gif]  
This requires that the spline has the second derivative endpoint constraints   [Graphics:Images/B-SplinesMod_gr_112.gif].  

Solution 1.

The B-spline construction requires the two nodes  [Graphics:../Images/B-SplinesMod_gr_113.gif] and  [Graphics:../Images/B-SplinesMod_gr_114.gif] that are out of the range of the abscissas  [Graphics:../Images/B-SplinesMod_gr_115.gif]  of the given data points.
Thus we will construct the  [Graphics:../Images/B-SplinesMod_gr_116.gif] in the following special way, with a formula for calculating the equal spacing nodes.

 

[Graphics:../Images/B-SplinesMod_gr_117.gif]

Now start with the list structure for the data points

 

[Graphics:../Images/B-SplinesMod_gr_118.gif]

The ordinates are obtained by taking the second element in the transpose of  [Graphics:../Images/B-SplinesMod_gr_119.gif].

[Graphics:../Images/B-SplinesMod_gr_120.gif]

[Graphics:../Images/B-SplinesMod_gr_121.gif]

[Graphics:../Images/B-SplinesMod_gr_122.gif]

[Graphics:../Images/B-SplinesMod_gr_123.gif]

The list structure or vector form of [Graphics:../Images/B-SplinesMod_gr_124.gif] is different from the subscript notation used in describing the points.
To use the subscript notation we use the following formula for locating ordinates.

[Graphics:../Images/B-SplinesMod_gr_125.gif]

[Graphics:../Images/B-SplinesMod_gr_126.gif]
[Graphics:../Images/B-SplinesMod_gr_127.gif]
[Graphics:../Images/B-SplinesMod_gr_128.gif]
[Graphics:../Images/B-SplinesMod_gr_129.gif]
[Graphics:../Images/B-SplinesMod_gr_130.gif]
[Graphics:../Images/B-SplinesMod_gr_131.gif]

Solve the system of equations for the coefficients.

[Graphics:../Images/B-SplinesMod_gr_132.gif]



[Graphics:../Images/B-SplinesMod_gr_133.gif]
[Graphics:../Images/B-SplinesMod_gr_134.gif]
[Graphics:../Images/B-SplinesMod_gr_135.gif]

[Graphics:../Images/B-SplinesMod_gr_136.gif]

[Graphics:../Images/B-SplinesMod_gr_137.gif]

[Graphics:../Images/B-SplinesMod_gr_138.gif]

[Graphics:../Images/B-SplinesMod_gr_139.gif]

[Graphics:../Images/B-SplinesMod_gr_140.gif]

[Graphics:../Images/B-SplinesMod_gr_141.gif]

[Graphics:../Images/B-SplinesMod_gr_142.gif]

[Graphics:../Images/B-SplinesMod_gr_143.gif]

[Graphics:../Images/B-SplinesMod_gr_144.gif]

 

Now form the spline.  It is assumed that the cell defining the basic B-spline function B[x] has been evaluated as well as the functions for  [Graphics:../Images/B-SplinesMod_gr_145.gif]  and  [Graphics:../Images/B-SplinesMod_gr_146.gif].
Since the index on the summation [Graphics:../Images/B-SplinesMod_gr_147.gif] ranges from  i = -1  to  i = n+1 = 7  there are  9  terms in the sum forming the B-spline.  

 

[Graphics:../Images/B-SplinesMod_gr_148.gif]


[Graphics:../Images/B-SplinesMod_gr_149.gif]

Let's look at the graph.

[Graphics:../Images/B-SplinesMod_gr_150.gif]


[Graphics:../Images/B-SplinesMod_gr_151.gif]

[Graphics:../Images/B-SplinesMod_gr_152.gif]
[Graphics:../Images/B-SplinesMod_gr_153.gif]

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

(c) John H. Mathews 2004