# [SciPy-user] Is there any easy way to calculate derivatives from ndimage.spline_filter coeffs?

Jorge E. ´Sanchez Sanchez hnry2k@hotmail....
Thu Jul 9 11:51:53 CDT 2009

```
Hi all,

I have interpolated a surface function with x, y, fvals using:

coeffs = ndimage.spline_filter(fvals)
newf = ndimage.map_coordinates(coeffs, coords, prefilter=False)

and I also need the x and y partial derivatives of fvals at the new interpolation points in coords. I suppose that there should be
some command similar to bisplev (as in the next code lines) which allows to calculate them, and I have been looking for it
unsuccsesfully, so I would appreciate it very much if somebody could help me with this.

#########################################################################
tck =  interpolate.bisplrep(xn,yn,fvalsn)

newff= interpolate.bisplev(newx[:,0],newy[0,:],tck)
#THE PARTIAL DERIVATIVE RESPECT x
newfdx = interpolate.bisplev(newx[:,0],newy[0,:],tck,dx=1,dy=0)

#THE PARTIAL DERIVATIVE RESPECT y
newfdy = interpolate.bisplev(newx[:,0],newy[0,:],tck,dx=0,dy=1)

#########################################################################

jorge

_________________________________________________________________
Actualiza tu Perfil y gana!
http://www.actualizatuperfil.com.mx/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20090709/fe375c70/attachment.html
```