- #1
CAF123
Gold Member
- 2,948
- 88
I have an analytic function F(x,y,z) and grids in x,y and z. I would like to reproduce the values I get for F at a given x,y and z through carefully interpolating the values given in the grids I have in each of these variables. The problem is that in some part of the x,y,z phase space, namely when y->0, the function F(x,y,z) oscillates very heavily and I am not sure how to tackle the interpolation.
My interpolation routine is in Cpp and, for a good part of my phase space, linear interpolation is OK but for y->0 I see it is not and was thinking of using splines. But, I see only a max 2D spline given in the gsl_library and I am anyway not sure if splines would help here when the function oscillates rapidly.
Thanks in advance for any comments.
My interpolation routine is in Cpp and, for a good part of my phase space, linear interpolation is OK but for y->0 I see it is not and was thinking of using splines. But, I see only a max 2D spline given in the gsl_library and I am anyway not sure if splines would help here when the function oscillates rapidly.
Thanks in advance for any comments.