2
$\begingroup$

I would like to give a theoretical estimation of local truncation error (and then for the global one) for a solution to a numerical initial value problem by NDSolve.
For this estimate I need to know what method has been used and the size of the steps (or an average size for the global error, since I think it uses adaptive size step). How can I get this information?

$\endgroup$
1
  • $\begingroup$ welcome! Could you please provide any information on what you have tried already (MMA code, literature etc.) and why it did not satisfy your requirements? This would alow others to produce meaningful answers. $\endgroup$ Dec 8, 2015 at 9:38

1 Answer 1

2
$\begingroup$

See this to find out the method used by NDSolve and this

sol = NDSolveValue[{y'[x] == y[x] Cos[x + y[x]], y[0] == 1}, y, {x, 0, 30}];
Differences @ First @ sol["Coordinates"]

to get magnitude of step size

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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