3 ms·
Have you seen DifferentialEquations.jl? It's an incredibly fast suite of solvers that pretty consistently is faster than Sundials/CVODE/lsoda or any of the othe
by adgjlsfhk1 5y ago
Have you seen DifferentialEquations.jl? It's an incredibly fast suite of solvers that pretty consistently is faster than Sundials/CVODE/lsoda or any of the other C++ solver. (for a bunch of benchmarks vs pretty much everything else, see https://github.com/SciML/SciMLBenchmarks.jl https://github.com/SciML/SciMLBenchmarks.jl)
- melissalobos 5y agoIndeed, that particular implementation is very fast. One of the goals of the C++ language is to leave no space for a lower level language than C++. A motivated person could just re-implement those algorithms in C++, in the absolute worst case using inline Assembly and at the very worst exactly match their performance. One of the nice things about Julia is you get good performance without going through a huge amount of effort. However you could always do as good or better in C++(with maybe more effort).
- adgjlsfhk1 5y agoJulia is pretty much the same but a few levels higher. Julia gives you some really powerful tools like @code_native (basically godbolt), inline assembly (or @code_llvm) something that , powerful macros, and better code reuse. If you look at the size of Julia libraries compared to similar C++ alternatives, the Julia ones are often about as fast (or faster), but typically around 10x less code. (my favorite example is that Julia's reader for Arrow files is more complete than the C++ one while being smaller than the makefiles for the C++ one (https://twitter.com/MoseGiordano/status/1489255661728796679 https://twitter.com/MoseGiordano/status/1489255661728796679)