 
 
 
 
 
 
RE: simple questions about splinefit
- To: mathgroup at smc.vnet.net
- Subject: [mg48403] RE: [mg48378] simple questions about splinefit
- From: David.Annetts at csiro.au
- Date: Fri, 28 May 2004 00:50:31 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Hi Long,
>   i used splinefit function to fit some data and get a 
> funtion i name it "spline1".but  i can not figure out the 
> relationship between the input variable of "spline1 "and the  
> returned values from "spline1".and how to calculate the 
> derivative of spline1.
> can anyone give me some suggestions?
It's explained in the online help.  SplineFit[] returns a parametisation
of your data.
	data = {#, Sin[2 Pi #/64]} & /@ Range[0., 32.]
	splin = SplineFit[N[data], Cubic]
	splin[#] & /@ Range[0, 32] - data
Because of a spline's properties, you are not restricted to sampling at
integer values -- splin[1.5] returns the {x, y} pair at splin[1.5].
Note also that different splines have different properties; the above
example only works for cubic splines.
Regards,
Dave.

