We would like a function that interpolates energies on a grid and provides a first and second derivative. Trilinear interpolation only is defined up to a first derivative. Grids with second derivatives include B-spline and trilinear cubic grids.