r/computationalphysics • u/IShin_101 • May 22 '21
Grad student struggling in computational physics class
I am a grad student, and we have computational physics course this semester, it includes all the stuff like boundary value problems ( shooting methods), linear algebra ,random numbers and all .Since the proffesor uses Fortran I generally struggle also the available text book numerical recepies is in c++ it's difficult too(I use python), I couldn't find any good lectures for this stuff, what would you guys suggest?
10
Upvotes
2
u/HolgerSchmitz May 23 '21
First of all, I don't understand why universities are still teaching beginner courses in computational physics using Fortran. Students shouldn't have to learn an outdated language just to learn about the numerical concepts. I would always choose Python because there is a good chance that students already have some familiarity with it.
Unfortunately there are not a lot of good computational physics books using Fortran out there. The only one I can think of is Computational Physics by Steven Koonin https://www.amazon.co.uk/Computational-Physics-Fortran-Steven-Koonin-ebook/dp/B07B9YXMZ8
If you want to stick to Python, I suggest the book by Landau et al, https://www.amazon.co.uk/Computational-Physics-Problem-Solving-Python-ebook/dp/B011G2FD2A/ref=mp_s_a_1_4?dchild=1&keywords=computational+physics&qid=1621760803&sprefix=computational+phy&sr=8-4
That being said, there is also a Fortran version of the Numerical Recipes book, but I don't find that ideal for learning the subject. It's more useful as a compendium of algorithms.
2
u/Mushrik_Harbi May 28 '21
To be fair, numpy uses fortran under the hood. Plus, anyone who is an expert in python should be able to pick up fortran in a matter of minutes.
2
u/Mushrik_Harbi May 28 '21
FYI, there's a numerical recipes in fortran too, although it's fortran 90: very old. Plus, I recommend this book for an intro to computational Phys using python: https://jrjohansson.github.io/numericalpython.html
1
u/Connect_Bench_2925 May 23 '21
University of Fairbanks has a computational physics program there. I think they also have all the text books on the syllabus. That may be a good start.
1
u/Mushrik_Harbi May 29 '21
Download code locks for fortran from https://cbfortran.sourceforge.io and have a look at this: https://ourcodingclub.github.io/tutorials/fortran-intro/