ODE Solvers Basic Usage


#1

I’ve searched everywhere for some basic info/tutorial on how to implement the ODE Solvers library, and in particular the ‘RungeKutta.FourthOrder’ method. Aside from the info in the Class Reference (which I didn’t really understand), all I found was some testing code which included some references like this:

        Func<double, double, double> ode = (t, y) => t + 2 * y * t;
        Func<double, double> sol = (t) => 0.5 * (Math.Exp(t * t) - 1);

Could some kind person provide me with a bit more information on how to use this? I’d sure appreciate it. It’s incredible the wonderful stuff you find in the MathNet libraries :slight_smile:


#2

Not sure I understand the question. What exactly are you interested in?


#3

Sorry, I think I’ve got it. I was confused about the ‘sol’ function that was used in the code I found, and thought somehow it was associated with the RK4 solver. I think it’s just the exact solution to the test ODE for purposes of checking errors.

Thanks.