Astrophysics - Which Programming Language

  • Thread starter Seb222
  • Start date
  • #1
1
0
I've done a very small amount of C++, but I don't want to spend the time I have to prepare on learning a language when it would have been more preferable to learn another (even though it seems you may use several language, and learning one helps to learn another.)

But are there any language you would say I require? Of course, everyone seems to swear by one language, whereas someone else will tell you to avoid it at all costs, so it's all a little confusing. Any input would be really valuable to me, thanks!
 

Answers and Replies

  • #2
150
0
Depends on what you want to do and which style suits you best.
There are a myriad of options.

One would be a high level interpreted language of one of the math software - Matlab, Mathematica, Maple(there's a whole section https://www.physicsforums.com/forumdisplay.php?f=189" covering just those types of packages).
If you are interested in building simulations C++ is a good bet. On the other hand Java works for multiple platforms.
Then there's a whole another area of GPU computing(if you need more computing power), which as I understand it is quite similar to C++ in style(CUDA anyway, don't know about OpenCL).

Besides, a program is just a tool for helping you to some result. And if you are talking astrophysics the choice of language will be the least of your problems I'd wager.
 
Last edited by a moderator:
  • #3
Astronuc
Staff Emeritus
Science Advisor
18,869
2,134
I've done a very small amount of C++, but I don't want to spend the time I have to prepare on learning a language when it would have been more preferable to learn another (even though it seems you may use several language, and learning one helps to learn another.)

But are there any language you would say I require? Of course, everyone seems to swear by one language, whereas someone else will tell you to avoid it at all costs, so it's all a little confusing. Any input would be really valuable to me, thanks!
Either FORTRAN or C++, with some Python perhaps.

C++ seems to be becoming the new standard particularly for Multiphysics Object Oriented Simulation Environment (MOOSE) with parallel and massively parallel systems.
For example, http://www.inl.gov/technicalpublications/Documents/4336141.pdf [Broken]

FORTRAN is the legacy standard for larger computational/simulation systems.

There is the matter of implicit vs explicit solutions, with the possibility for hybrid techniques. A lot depends on the time scale and non-linearities.
 
Last edited by a moderator:

Related Threads on Astrophysics - Which Programming Language

  • Last Post
Replies
8
Views
3K
Replies
15
Views
6K
Replies
3
Views
1K
Replies
7
Views
4K
Replies
26
Views
6K
Replies
397
Views
5K
Replies
11
Views
1K
Replies
122
Views
8K
  • Last Post
Replies
2
Views
783
Top