I think people should just get skills in one typical OO language and not get too hung up on the choice of initial language. Once you do that, hopping to another one as needed is basically trivial. Off the top of my head, ancient Fortran is good for computational science, I think, as is Python. I learned Python, but I now use C# exclusively. I'm no programmer or software engineer, so I don't have a deep technical knowledge on these languages, but as a casual user, they all pretty much feel the same to me.
I definitely agree that you shouldn't sweat the initial choice, mine happened to be python due to a course I was taking. At the end of the day it's about solving the problem you are given in an efficient way. For a lot of problems the functionality available (or familiarity) will be more important than the speed. But once you jump into work that requires a lot of speed / has high computational complexity I think you should use a compiled language. Fortran is fine but I don't really know many people who use it anymore. C++ (for my field) seems to have a lot more support/ libraries to work off of.
I doubt the presenter knows your language's word, "dost." But hey, that's okay. He gave your comment a Like, and if he doesn't know, then I will let him know here: friend; buddy; pal; dude.
I'm a freshly enrolled PhD student in astrophysics, but I changed my specializations from CMP and hence have beginner level computational knowledge. Can you give a brief roadmap on how should I proceed to learn the required things as it would help me to make my learning journey a bit better? maybe atleast for the initial stage
Do you have any numerical experience at all? Which languages? Which languages would you be working with during your PhD? I can answer better once you give me more details :). Also feel free to join the discord community, I answer quicker there and can go into more depth. For c++ I would say start on the tutorials of: cplusplus.com/ (assuming it's brand new)
@@JonathonRiddell Thank you so much for looking at my comment. I had numerical physics classes of different series, algebra, matrices, etc. In programming, we were taught C in our undergrad computational physics classes, and i did learn different numerical methods like newton Rapson etc. But, I am learning Python on my own as I would mostly be working with this language. I inquired about the requirements, but I was given no specification and was told that anyone would work, with the only difference in syntax. But there is a large gap in my knowledge of the numerical methods as I still need to relearn those techniques. I have no prior real time experience data handling and stuff which I would be mostly working on. You can call I'm a astro enthusiast who is starting his astro journey from PhD. Looking forward to hear from you on this. Also. I would love to connect with you on discord. Username - Spydr98 . name- swagat, loved your video ❤
I see! So to me it looks like you are quite the experienced computational physicist already :) you are just out of practice. For python and computational physics I would highly recommend the channel: ruclips.net/user/MrPSolver It's dedicated to computational physics in python specifically. There are intro python videos there to get you started if need be and then you can code along in the other videos!
For plotting I believe the channel I mentioned covers this, but matplotlib is easy and intuitive to work with. I'd recommend looking into AXES plotting and learn that way vs. The normal plt.plot route as you'll eventually want subplots and more fancy features :).
Python is good for prototyping but for serious supercomputing, there is not much to be gained by not using Fortran. Of course, if speed is not an issue, C# and C++ might be OK - though wny torture yourself with the latter.
You guys, @MrPSolver included could benefit from learning LAPACK and Fortran. But, Mr Riddell, if you know C++ and no Fortran, you might find Fortran odd, though its syntax or I should say its readability is not so different from python.
With eigen in c++ I'm not sure lapack is necessary anymore / the advantages of c++ really shine. You can also construct eigen with a lapack back end if you want :)
@@JonathonRiddell very good. I was just somewhat surprised you didn't mention Fortran or Haskell (kidding about the latter one; however, it is supposed to be excellent at number crunching. I did try learning it, but gave up; I could not get the hang of the syntax; it all seemed so bizarre.). Maybe younger physicists don't generally use Fortran. It is an older language, but it's a good one. The fact that it is still around and used so heavily attests to its resiliance.
Julia is quite a nice language with some packages like iTensor offering support now. I get the impression that it is in general quite fast, and much easier to develop efficient code on than c++. Depending on your use case it might be a better alternative to c++, but in the end, highly optimized c++ code is going to be faster.
I’ve used python for data analysis and plots as you mention. And I’ve learnt C and basic numerical methoda through formal courses. I have a bit of free time at hand right now before grad school and would like to improve my numerical abilities. What book or other resources would you recommend? I want to learn algorithms that are common to most computational physics.
Before I give feedback, just curious about two things. Have you taken a class on numerical analysis or were they strictly numerical methods courses? And what area of physics will you focus on in graduate school? It seems like you have a solid foundation :) just want to make a recommendation that makes sense for you.
@@JonathonRiddell It was about a semester worth of course on basic numerical methods with things like root finding, differentiation and integration methods, and methods to solve ode like RK4 etc. I’m leaning towards numerical relativity for grad school at the moment but I’m not totally sure. I like condensed matter physics as well.
@@bibekgautam512 Hey! So, I don't have any experience in numerical relativity, but, I do have some suggestions here. One suggestion is to get a more formal intro to numerical analysis, this will expose you to more algorithms and allow you to understand what's going on at a deeper level. From that, I used (and enjoyed): A Graduate Introduction to Numerical Methods: From the Viewpoint of Backward Error Analysis By Rob Corless and Nicolas Fillion. For condensed matter specific algorithms, I'll instead recommend an review article that includes pseudo code, for solving a bunch of different types of problems in condensed matter systems (the author uses magnetic systems as an example but it's not limited to it: arxiv.org/pdf/1101.3281.pdf Either, or both, would be good ways to expand your knowledge. :) Hope that helps.
I started in Fortran back in the 70's. I tried to change to c and found it very confusing so I stayed with Fortran. I like Python a lot, but it is a little slow. I have not tried c++ is it easier to learn than c? I really like Python in linux. Is there a more modern language like python with more speed?
Julia might be up your ally then! It's modern and designed to be easier. Still slower than c++/c. Depending on your needs modern c++ might be made a lot easier with libraries, for example eigen c++ makes linear algebra very easy (it's free and highly optimized).
maybe just try to update your fortran, there is an amazing book from Milan Curcic about modern fortran. I know and use python, c, c++ and c#, but I still rely on fortran (standard 2023) for proper big number crunching :) as python is too slow and c++ syntax feels a bit more uncomfortable for maths problems.
I personally don't, though some people still do. A lot of newer code seems to be written for c++, c or even Julia these days :). Sometimes python and Matlab too.
Thanks for the shoutout! ❤️. I'm actually planning on learning C++ some time in the near future, would love to see samples of your code on here!
No you're falling for the devil. Trust in the lord and go for Julia.
@@adwaitnaravane5285 and yes u r really right
I think people should just get skills in one typical OO language and not get too hung up on the choice of initial language. Once you do that, hopping to another one as needed is basically trivial. Off the top of my head, ancient Fortran is good for computational science, I think, as is Python. I learned Python, but I now use C# exclusively.
I'm no programmer or software engineer, so I don't have a deep technical knowledge on these languages, but as a casual user, they all pretty much feel the same to me.
I definitely agree that you shouldn't sweat the initial choice, mine happened to be python due to a course I was taking.
At the end of the day it's about solving the problem you are given in an efficient way. For a lot of problems the functionality available (or familiarity) will be more important than the speed.
But once you jump into work that requires a lot of speed / has high computational complexity I think you should use a compiled language. Fortran is fine but I don't really know many people who use it anymore. C++ (for my field) seems to have a lot more support/ libraries to work off of.
I really don't like C, Is C# hard to learn and use? Is C# like Fortran, does C# have an easy to use editor?
You should not use "ancient Fortran". You should use Fortran2008 or later, which is object-oriented, supports parallelism, &c.
Great idea for coding series
Thank You dost.. much needed video
I doubt the presenter knows your language's word, "dost." But hey, that's okay. He gave your comment a Like, and if he doesn't know, then I will let him know here: friend; buddy; pal; dude.
I'm a freshly enrolled PhD student in astrophysics, but I changed my specializations from CMP and hence have beginner level computational knowledge. Can you give a brief roadmap on how should I proceed to learn the required things as it would help me to make my learning journey a bit better? maybe atleast for the initial stage
Do you have any numerical experience at all? Which languages? Which languages would you be working with during your PhD? I can answer better once you give me more details :). Also feel free to join the discord community, I answer quicker there and can go into more depth.
For c++ I would say start on the tutorials of: cplusplus.com/ (assuming it's brand new)
@@JonathonRiddell Thank you so much for looking at my comment. I had numerical physics classes of different series, algebra, matrices, etc. In programming, we were taught C in our undergrad computational physics classes, and i did learn different numerical methods like newton Rapson etc. But, I am learning Python on my own as I would mostly be working with this language. I inquired about the requirements, but I was given no specification and was told that anyone would work, with the only difference in syntax. But there is a large gap in my knowledge of the numerical methods as I still need to relearn those techniques.
I have no prior real time experience data handling and stuff which I would be mostly working on. You can call I'm a astro enthusiast who is starting his astro journey from PhD. Looking forward to hear from you on this.
Also. I would love to connect with you on discord. Username - Spydr98 . name- swagat, loved your video ❤
I see! So to me it looks like you are quite the experienced computational physicist already :) you are just out of practice. For python and computational physics I would highly recommend the channel: ruclips.net/user/MrPSolver
It's dedicated to computational physics in python specifically. There are intro python videos there to get you started if need be and then you can code along in the other videos!
For plotting I believe the channel I mentioned covers this, but matplotlib is easy and intuitive to work with. I'd recommend looking into AXES plotting and learn that way vs. The normal plt.plot route as you'll eventually want subplots and more fancy features :).
@@JonathonRiddell yess. i'll look into it for sure
Julia is great for physics
Python is good for prototyping but for serious supercomputing, there is not much to be gained by not using Fortran. Of course, if speed is not an issue, C# and C++ might be OK - though wny torture yourself with the latter.
You guys, @MrPSolver included could benefit from learning LAPACK and Fortran. But, Mr Riddell, if you know C++ and no Fortran, you might find Fortran odd, though its syntax or I should say its readability is not so different from python.
With eigen in c++ I'm not sure lapack is necessary anymore / the advantages of c++ really shine. You can also construct eigen with a lapack back end if you want :)
@@JonathonRiddell very good. I was just somewhat surprised you didn't mention Fortran or Haskell (kidding about the latter one; however, it is supposed to be excellent at number crunching. I did try learning it, but gave up; I could not get the hang of the syntax; it all seemed so bizarre.). Maybe younger physicists don't generally use Fortran. It is an older language, but it's a good one. The fact that it is still around and used so heavily attests to its resiliance.
What about Julia programming language?
Julia is quite a nice language with some packages like iTensor offering support now. I get the impression that it is in general quite fast, and much easier to develop efficient code on than c++. Depending on your use case it might be a better alternative to c++, but in the end, highly optimized c++ code is going to be faster.
I’ve used python for data analysis and plots as you mention. And I’ve learnt C and basic numerical methoda through formal courses. I have a bit of free time at hand right now before grad school and would like to improve my numerical abilities. What book or other resources would you recommend? I want to learn algorithms that are common to most computational physics.
Before I give feedback, just curious about two things. Have you taken a class on numerical analysis or were they strictly numerical methods courses? And what area of physics will you focus on in graduate school?
It seems like you have a solid foundation :) just want to make a recommendation that makes sense for you.
@@JonathonRiddell It was about a semester worth of course on basic numerical methods with things like root finding, differentiation and integration methods, and methods to solve ode like RK4 etc. I’m leaning towards numerical relativity for grad school at the moment but I’m not totally sure. I like condensed matter physics as well.
@@bibekgautam512 Hey! So, I don't have any experience in numerical relativity, but, I do have some suggestions here. One suggestion is to get a more formal intro to numerical analysis, this will expose you to more algorithms and allow you to understand what's going on at a deeper level. From that, I used (and enjoyed): A Graduate Introduction to Numerical Methods: From the Viewpoint of Backward Error Analysis By Rob Corless and Nicolas Fillion.
For condensed matter specific algorithms, I'll instead recommend an review article that includes pseudo code, for solving a bunch of different types of problems in condensed matter systems (the author uses magnetic systems as an example but it's not limited to it: arxiv.org/pdf/1101.3281.pdf
Either, or both, would be good ways to expand your knowledge. :) Hope that helps.
@@JonathonRiddell That sounds like exactly what I was looking for. Thanks a lot! Looking forward to that video series starting next week as well!
@@JonathonRiddell will check it out for sure... But before that I got to learn c++ in the frist place lol
I started in Fortran back in the 70's. I tried to change to c and found it very confusing so I stayed with Fortran. I like Python a lot, but it is a little slow. I have not tried c++ is it easier to learn than c? I really like Python in linux. Is there a more modern language like python with more speed?
Julia might be up your ally then! It's modern and designed to be easier. Still slower than c++/c.
Depending on your needs modern c++ might be made a lot easier with libraries, for example eigen c++ makes linear algebra very easy (it's free and highly optimized).
maybe just try to update your fortran, there is an amazing book from Milan Curcic about modern fortran. I know and use python, c, c++ and c#, but I still rely on fortran (standard 2023) for proper big number crunching :) as python is too slow and c++ syntax feels a bit more uncomfortable for maths problems.
Do you have to work with Fortran at all? As i heard that a lot of work is present in it.
I personally don't, though some people still do. A lot of newer code seems to be written for c++, c or even Julia these days :). Sometimes python and Matlab too.