interpolation functions and tests