3D bicubic spline.


siddharth
07-05-2005, 10:56 AM
hi,
can anybody help me by telling how to do the 3D bicubic spline.
In the book and even the source code is given for 2D.The book says tht it can be done easily.
if someone has done and can share with me wud be freat help.
the chapter number is 3 in NR in c book.
thanks.
siddharth

ephesus
06-09-2006, 02:27 AM
Hi ,

First of all you need to solve 4**3= 64 coefficients which u need for ur function. In 3D space you interpolate over 8 points. That means you need 64/8=8 equations to solve ur coefficients. The function itself (*1) , the first partial derivatives (*2,*3,*4) , the cross derivatives ( *5,*6,*7) and one third order cross derivative (*8).

Try to find the inverse of the coefficient matrix and save it in an array. The rest is same as bicubicspline... ;)