Python What is the best book for learning python for physics applications?

AI Thread Summary
For beginners looking to learn Python for physics applications, starting with foundational programming skills is essential. Online platforms like Codecademy can help with basic syntax, but more comprehensive resources are recommended for a deeper understanding. "Learn Python the Hard Way" is suggested, despite mixed reviews, as a way to grasp programming fundamentals. Once comfortable with coding, exploring libraries such as NumPy and SciPy is crucial for scientific computing. For physics-specific applications, "Computational Physics" by Mark Newman is highly recommended, as it focuses on Python for physics students and includes practical elements like modeling and animations. The first five chapters of this book are available for free on the author's website, making it an accessible starting point.
TheQQ
Messages
5
Reaction score
0
Hello,

I would like to self learn python for my physics degree, but I don't really have an idea where to start. Could anyone recommend a good book out there for beginners (zero experience with programming)?

I don't want anything too comprehensive; that's for comp sci majors. I'm really just looking for a book with a focus on the application of python for physical simulations, solving equations, etc.

thanks
 
Technology news on Phys.org
I don't know of any books on the subject. If you have zero experience, you should start with learning to program. You can do stuff like code academy to learn the syntax (http://www.codecademy.com/, you won't learn how to code with these tutorials). Then you probably should work through some proper python tutorial or take a course on it if possible. When I was getting into python, I did this tutorial http://learnpythonthehardway.org/book/.
I didn't like it that much, but many people are saying it's great so you can look into it I guess. It requires you to learn basics of command line interface too.

When you know how to code, you can start looking into numpy/scipy library http://www.scipy.org/
It's probably the biggest and most widely used scientific library for python. For learning scipy you can google some material (like http://scipy-lectures.github.io/intro/index.html).

Then of course there are libraries like pygame which are nice for making little physics simulations/games (collisions, planetary systems) with some (2D) graphics.

But you really need to learn some programming first (not theory, just how to build a program), and the fastest way to learn that is writing programs.
 
  • Like
Likes 1 person
Last edited by a moderator:
  • Like
Likes 1 person
Thanks for the suggestions,

The book by Langtangen looks fairly interesting with good reviews on amazon so I think I'll try to start with that.
 
Last edited by a moderator:

Similar threads

Back
Top