Mathematica 9 is now available
Student Support Forum
-----
Student Support Forum: 'Spline interpolation' topicStudent Support Forum > General > "Spline interpolation"

Help | Reply To Topic
Author Comment/Response
yanfyon
06/12/13 10:02am

How to make BSplineFunction passes each data ploint like the obsolete SplineFit?

(*Obsolete spline packae*)
Needs["Splines`"]
testData = {{10, 10}, {10, 20}, {10, 25}, {10, 27}, {10, 28}, {9,
26}, {8, 25}, {5, 20}, {3, 1}};
fFit = SplineFit[testData, Cubic]
fFit[4.5]
ParametricPlot[fFit[n], {n, 0, Length[testData] - 1},
Epilog -> Point[testData]]

(*New function*)

fFit01 = BSplineFunction[testData,
SplineWeights -> Table[1, {Length[testData]}]];
fFit01[4.5]
ParametricPlot[fFit01[n], {n, 0, Length[testData] - 1},
Epilog -> Point[testData]]



URL: ,
Help | Reply To Topic