3 ms·
Writing that programmers that use Euler instead of RK4 are "bloddy idiots" might work well to get some laughs in a blog post when the author is trying to stress
by atan2 1y ago
Writing that programmers that use Euler instead of RK4 are "bloddy idiots" might work well to get some laughs in a blog post when the author is trying to stress how RK4 is more accurate and stable than the alternative, but there are cases where real-time applications (especially on older machines and older consoles) could not afford the overhead of RK4 and Euler was gave good-enough for what they needed.
- Y_Y 1y agoForward Euler is very terrible and can give you wildly wrong answers after just a few steps. If you think higher Runge-Kutta and fancy methods are too complex/expensive you do have cheap and stable options, like implicit euler or leapfrog. It's very likely that your numeric integrator is going to be a hot part of your game loop, it's worth doing ten minutes of research, IMHO.
- kergonath 1y ago> like implicit euler or leapfrog Leapfrog is so easy to implement, as well. It might require a smaller timestep than some fancy techniques but it is very cheap per timestep. And given that it is accurate enough for statistical Physics simulations, so about 2 orders of magnitude more accurate than it needs to be for a game.
- coldburst 1y agoSymplectic Euler is often a good compromise. It's as simple as forward Euler but has better energy conservation.