Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We know that changing the option InterpolationOrder in ListLinePlotListPlot3DListContourPlot will change the shape of the curve:

(*A example from the help*)
data = {{0, 0}, {1, 2}, {3, 4}, {4, 2}, {6, 0}};
Table[ListLinePlot[data, InterpolationOrder -> n], {n, {0, 1, 3}}]

Mathematica graphics

But nothing changes for NDSolve:

Table[Plot[Evaluate[First[x[t] /. NDSolve[{x'[t] == y[t], y'[t] == -x[t], x[0] == 1, 
        y[0] == 0}, {x, y}, {t, 0, 10}, InterpolationOrder -> n]]], {t, 0, 10}], {n, 1, 3}]

Mathematica graphics

I checked the help and found the only example for InterpolationOrder in NDSolve is to set it to All. (The same example appears in two different places…) So I met the question written in the title, and, what if I want to change the InterpolationOrder of the InterpolatingFunction worked out by NDSolve?

(Sigh…) Seems that InterpolationOrder in NDSolve is really "useless", and there's no option that can change the interpolation order of InterpolatingFunction worked out by NDSolve…whatever! here I've already picked up another approach for changing the order: I just need to replace the InterpolatingPolynomial with Interpolation[…, InterpolationOrder -> …] in the link.

share|improve this question
up vote 6 down vote accepted

This seems to (almost) confirm your point:

When strict accuracy of intermediate values computed with the InterpolatingFunction object returned from NDSolve is important, you will want to use the NDSolve method option setting InterpolationOrder->All that uses interpolation based on the order of the method, sometimes called dense output, to represent the solution between time steps. By default NDSolve stores a minimal amount of data to represent the solution well enough for graphical purposes. Keeping the amount of data small saves on both memory and time for more complicated solutions.

share|improve this answer
And here hides another example for InterpolationOrder in NDSolve 囧. – xzczd Oct 30 '12 at 12:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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