I have 8 sets of 2D-data that I want to each interpolate with ListInterpolate, because it is a very efficient command. The complete data are therefore in a 3D table. I would like to use ListInterpolate such that it returns a 2D function that evaluated to a 1D list (of 8 elements). How can I do that best? This would be using ListInterpolate in a listable way/ giving a list of 2D tables to it.

  • 4
    $\begingroup$ Look up Map in the documentation. $\endgroup$ – Sektor Aug 17 '15 at 12:54
  • $\begingroup$ Thanks, Sektor, this is indeed also here the good solution. $\endgroup$ – qcomp Aug 17 '15 at 13:17
  • 1
    $\begingroup$ Mathematica permits adding the attribute Listable to ListInterpolation, but you don't want to do that -- it breaks the function. $\endgroup$ – m_goldberg Aug 17 '15 at 13:25
  • $\begingroup$ Look up ListInterpolation in the documentation. There is no built-in function named ListInterpolate $\endgroup$ – m_goldberg Aug 17 '15 at 13:27

If you have your data in an array 'data' you can simply run ListInterpolation on each entry of the array via Map or /@

lip = ListInterpolation /@ data

or if you have to supply additional arguments

lip = ListInterpolation[#, whatever option or argument] & /@ data
| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.