Documentation of available methods (numerical solvers)?
Hi Ekin,
Furthermore, I am wondering if the available methods (numerical ODE solvers in the package 'desolver') are actually documented somewhere?
By the available methods, I am refering to those which I get with
print("available methods:", de.integrators.available_methods(names=True))
i.e.
['ABAS5O6H', 'ABAs5o6HSolver', 'AHE', 'Adaptive Heun-Euler', 'BABS9O7H', 'BABs9o7HSolver', 'BackwardEuler', 'CrankNicolson', 'DOPRI45', 'Dormand-Prince', 'Euler', 'Euler-Trap', 'Euler-Trapezoidal', 'EulerSolver', 'EulerTrapSolver', 'Explicit ABAS5O6H', 'Explicit Adaptive Heun-Euler', 'Explicit BABS9O7H', 'Explicit Euler', 'Explicit Euler-Trapezoidal', "Explicit Heun's", 'Explicit Midpoint', 'Explicit RK108', 'Explicit RK1412', 'Explicit RK4', 'Explicit RK45CK', 'Explicit RK5', 'Explicit RK8713M', "Explicit Ralston's", 'Explicit Symplectic Forward Euler', 'GaussLegendre4', 'GaussLegendre6', "Heun's", 'HeunEulerSolver', 'HeunsSolver', 'ImplicitMidpoint', 'LobattoIIIA2', 'LobattoIIIA4', 'LobattoIIIB2', 'LobattoIIIB4', 'LobattoIIIC2', 'LobattoIIIC4', 'Midpoint', 'MidpointSolver', 'Predictor-Corrector Euler', 'RK108', 'RK108Feag', 'RK108Solver', 'RK1412', 'RK1412Feag', 'RK1412Solver', 'RK4', 'RK45', 'RK45CK', 'RK45CKSolver', 'RK4Solver', 'RK5', 'RK5Solver', 'RK87', 'RK8713M', 'RK8713MSolver', 'RadauIA3', 'RadauIA5', 'RadauIIA19', 'RadauIIA3', 'RadauIIA5', "Ralston's", 'RalstonsSolver', 'Runge-Kutta 10(8)', 'Runge-Kutta 14(12)', 'Runge-Kutta 4', 'Runge-Kutta 5', 'Runge-Kutta 8(7)', 'Runge-Kutta-Cash-Karp', 'Symplectic Forward Euler', 'SymplecticEulerSolver']
Some of them are also identical, as far as I saw.
Does one of them actually correspond to MATLAB's ode15s and/or to MATLAB's ode23s often used in the case of stiff ODEs?
Kind regards, Thomas
Yes, each method has a series of aliases so you can see the different name's given to the method and use them instead (it's clearer in code sometimes to write Runge-Kutta-Cash-Karp than to write RK45CK).
The ode15s is a variable-order, variable-step method using numerical differentiation formulas (and backward differentiation formulas), while ode23s is a rosenbrock method of order 2.
All of DESolver's methods at this point are Runge-Kutta methods with most explicit and some implicit. For stiff problems you can try RadauIIA5 which is generally quite robust.
It seems I have broken the documentation so thank you for bringing that to my attention, the methods in DESolver are listed here: https://github.com/Microno95/desolver/blob/master/AVAILABLE_METHODS.rst
And the corresponding references are here: https://github.com/Microno95/desolver/blob/master/REFERENCES.rst
I will note that the implicit solvers are not very efficient, they calculate the full jacobian of the system and so while they run and give correct results, they are not fast. MATLAB's solvers will definitely be faster as they use more efficient methods and compiled languages underneath.
Oh also, for specific cases where you have a phase space system that obeys a Hamiltonian (ie. physical system), then you can use the symplectic methods which can conserve the Hamiltonian and sometimes give better results.