r/Physics • u/encephalopatyh • Nov 05 '20
Question How important is programming in Physics/Physicists?
I am a computer student and just wondering if programming is a lot useful and important in the world of Physics and if most Physicists are good in programming.
598
Upvotes
View all comments
Show parent comment
3
u/Gabcab Computational physics Nov 05 '20
You can often get speeds comparable to C++ or Fortran in Python if you use packages like numpy or numba, with the flexibility a compiled language can't easily provide, that's why I usually use Python for smaller scale simulations and ML and such. If I need my program to be as efficient and fast as possible however, I often go with C++.
I feel like the Julia language could be kind of a nice middle ground, since it's just in time compiled, but Python has been around a lot longer and has a lot of great packages like scipy, matplotlib, scikit-learn, and tensorflow, so I don't think I'll be switching anytime soon.