I want to solve only one equation by RK4Rich function, but doesn't work ok.
Sorry for answering so late, I'm actually too busy at the moment...
I think
RK4Rich does not work properly because you forgot the output argument
y, which is mandatory; you just used the optional output, but mandatory output should be present as well, even if you don't need it. Try this:
T,tp,Tp=RK4Rich(RHS,t0,{T0},tf,true,5*10^-4)
I bet
RK4Rich will work then. If not, double-check your
RHS function, and make sure it implements the right-hand side of the differential equation you want to solve.
then what is the ?Rich function?? please explain without the abbreviations so maybe some one can help you.
"Rich" is
not a function written by girdeuax, it's part of the name of the LNA function. "Rich" comes from "Richardson extrapolation". Remember,
RK4Rich is not just an implementation of the Runge-Kutta method of fourth order; it also uses adaptive stepsize control (via Richardson extrapolation). Runge-Kutta method without stepsize control is not available in LNA, and it will never be, since constant integration step is a common source of inaccurate results.
Anyway, your question should be posted at the LNA topic, not here....