![]() ![]() When you solve an equation using ode45, the Runge-Kutta method uses a “free” interpolation to fill in some extra points. That method just works and creates good plots, right? Well, Shampine added a little trick to it. Let’s take for example the classic ode45. MATLAB documents its ODE solvers very well, there’s a similar interface for using each of the different methods, and it tells you in a table in which cases you should use the different methods.īut the modifications to the methods goes even further. The MATLAB ODE Suite does extremely well at hitting these goals. Instead of focusing on efficiency, they key for this group is to have a clear and neatly defined (universal) interface which has a lot of flexibility. The idea is pretty simple: users of a problem solving environment (the examples from his papers are MATLAB and Maple) do not have the same requirements as more general users of scientific computing. Shampine also had a few other papers at this time developing the idea of a “methods for a problem solving environment” or a PSE. MATLAB’s differential equation solver suite was described in a research paper by its creator Lawerance Shampine, and this paper is one of the most highly cited SIAM Scientific Computing publications. MATLAB’s Built-In Methodsĭue to its popularity, let’s start with MATLAB’s built in differential equation solvers. All other packages were benchmarked by looking at the same set of problems implemented by modifying the example code from their documentation. For general benchmarks of the algorithms which are mentioned in this post, see the SciMLBenchmarks.jl repository and the associated benchmarks result website. For the current state of the reproducible benchmarks on the overhead of the various wrapper packages, see the ODE Solver Multi-Language Wrapper Package Work-Precision Benchmarks (MATLAB, SciPy, Julia, deSolve (R)) (which includes direct benchmarks of Sundials and Hairer’s methods as well). However, we are beginning to wrap all of the packages together within a single interface to allow for reproducible benchmarking. The packages mentioned in this blog post were originally benchmarked individually by investigating the same set of standard benchmark problems in each of their respective modeling languages. If you just want a quick summary, I created a table which has all of this information. You will see at the end that DifferentialEquations.jl does offer pretty much everything from the other suite combined, but that’s no accident: our software organization came last and we used these suites as a guiding hand for how to design ours.) Quick Summary Table (Full disclosure, I am the lead developer of DifferentialEquations.jl. ![]() I hope that by giving you the details for how each suite was put together (and the “why”, as gathered from software publications) you can come to your own conclusion as to which suites are right for you. This is a good way to reflect upon what’s available and find out where there is room for improvement. What I would like to do is take the time to compare and contrast between the most popular offerings. For the field of scientific computing, the methods for solving differential equations are one of the important areas. See screenshot below.Many times a scientist is choosing a programming language or a software for a specific purpose. Spyder - I normally just use these libraries with a text editor and a ipython terminal session, but if you are more comfortable with an integrated environment you may look at spyder, an IDE designed in the vein of matlab/mathematica using the above libraries. Python-numpy python-scipy python-matplotlib - Core scientific python libraries Numpy provides efficient arrays for handling large amounts of data Scipy provides algorithms, eg clustering, FFT, numerical integration, linear algebra and Matplotlib provides a wide variety of plotting functions (including an interface designed for interactive use). You might also want ipython-notebook which provides a browser-based interactive session (see image below). ipython - a much nicer version of the standard python shell, with session saving, tab-completion, etc.It is not quite a replacement, since the python language is not as specialised for mathematics as matlab/mathematica syntax, but it combines a relatively good syntax for interactive mathematics with a fully-capable programming language. I would suggest python with appropriate libraries as a good option. ![]()
0 Comments
Leave a Reply. |