Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Ask HN: Adoption of 'modern' C++ in physics/astro community
4 points by beezle on April 16, 2019 | hide | past | favorite | 2 comments
Long time away. Broadly speaking, looking to get current for computational physics. My Fortran is reasonable and likely easy to refresh, but I was never big into C (and less C++) so that requires a fresh start.

I know adoption of new language features (let alone entire languages) can be glacial in many fields of physics and engineering. Where is the most reasonable point to start in C++? Is C++11 the sweet spot? Is most new code gravitating to at least that revision? Have legacy code bases been refactored and would going with C+11 hinder understanding of any that have not?



Not meaning to be a bad cog in your plan, but why in the world would you go from Fortran to C++. I also would not recommend C, nor a host of other languages.

Personally I would recommend Java or C#. Both require variable declaration and manage memory. Neither support 'goto' but most languages do not these days as the famous 'goto' generates the classic spaghetti code.


I'm not aware of any significant physics code in java or c#, only Fortran and C++. There are some use cases for python as well.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: