Is Fortran better than Python for teaching the basics of numerical linear algebra? – Dr. Jean-Christophe Loiseau
https://loiseaujc.github.io/posts/blog-title/fortran_vs_python.html
Post
Is Fortran better than Python for teaching the basics of numerical linear algebra? – Dr. Jean-Christophe Loiseau
https://loiseaujc.github.io/posts/blog-title/fortran_vs_python.html
https://en.wikipedia.org/wiki/Betteridge%27s_law_of_headlines says "No".
For a beginner (and for me, who learned Fortran in the 1970s, and has over 20 years experience with Python), having a command line interface to the language makes it much, much easier to experiment with.
@jbz Oh, and he prefers Fortran because it's strongly typed, but the strength of modern Python typing is quite high. Most professionals now just start off each project by throwing a type checker and a linter into the tool chain from the very start. (For me it's mypy and ruff, but it might well by pyrefly and ruff fairly soon.)
@TomSwirly @jbz or, as some of the commenters note (and he sort of hints at in his article), you could use Julia - which just supports all this stuff out of the box, has the 1-indexing that he wants, has strong (inferred) typing...
@jbz interesting. I’m old enough to have done my 2nd year numerical methods course in Fortran. I find it odd that python won the popularity contest for numerical computation. For one thing, it’s an interpreted language compared with Fortran (or C) being compiled. Fortran (at least the one I learned) is not object oriented. So Fortran should be much more efficient, if less readily accessible. I would not be surprised if most of the heavy lifting library calls in numpy are not actually written in python but Fortran (or C).
A space for Bonfire maintainers and contributors to communicate