PDA

View Full Version : Best Language for Applied Mathematics


TRF86
Aug10-10, 04:16 PM
I am currently in graduate school and I work on modeling. The systems I model rely heavily on stiff ODE solvers (i.e. ode15s in MATLAB) and non-linear solvers as well for solving non-linear reaction and diffusion equations.

So far I have typically used MATLAB for my work, but I feel like this will limit me when I apply for a job, since companies may not be willing to shell out 1000's in licensing fees if they can just use open source products. So, I want to learn another language that will be useful for my modeling work. I have considered C using the GSL, but I want to make sure that what I invest time in will be the best choice.

What do you guys recommend I should pick? It's not really necessary to have solvers in place. I could write my own if need be. What's really important is being able to manipulate matrices as easily as it's done in MATLAB, and that the language is powerful with a learning curve that's not too bad. I have a fair amount of experience already in C.

Thanks.

zhermes
Aug10-10, 08:43 PM
For something like applied mathematics, I think its very beneficial to be multi-lingual in your coding. Everyone who wants to get respect should know C/C++ well; it sounds like IDL might be another good thing to look into for your situation; but it has essentially the same draw backs as MATLAB (e.g. cost).

See what kind of libraries/packages there are for vector manipulation in C++.

TRF86
Aug10-10, 09:03 PM
For something like applied mathematics, I think its very beneficial to be multi-lingual in your coding. Everyone who wants to get respect should know C/C++ well; it sounds like IDL might be another good thing to look into for your situation; but it has essentially the same draw backs as MATLAB (e.g. cost).

See what kind of libraries/packages there are for vector manipulation in C++.

It seems that BLAS (http://www.netlib.org/blas/) along with LAPAC (http://www.netlib.org/lapack/) is pretty much the standard for vector/matrix manipulation in C. It has a lot of the same functions/features that MATLAB has.

Maybe I will just start with that and learn the basics in there. Then I can develop that some more and maybe write some of my own solvers.

What about visualizing the data? Is GNU Plot the best for graphing my data? Or is there a better alternative? I would like 2D/3D graph support, and the ability to create animated plots (to step through time).

diggy
Aug16-10, 03:35 PM
Besides GSL, NAG and ROOT also have decent numerical libraries. Nag costs money, but ROOT is free. Oh and there is of course the Numerical Recipes library (which also costs money), but comes with a nice book. All of those are in C/C++. In fact I'm pretty sure I've searched around and found lots of others, but haven't checked many of them out. Mathematica, like Matlab and Maple, is also popular, but not C based.

schip666!
Aug17-10, 01:52 PM
A few years ago I knew a math wiz-kid who swore by Haskell.

Then there's the stats languages like R -- soon all math will be statistics, no?

diggy
Aug17-10, 02:35 PM
R is a nice language, I guess even though its focused on stats you could probably use if for finite difference equations and other numerical methods -- linear algebra is still linear algebra, and stats definitely use linear algebra. But it has some issues with looping that would probably make it non-ideal (plus if the methods you write aren't compiled they are going to be slow).

Haskell looks interesting -- surprisingly large number of libraries for it.

Dr Transport
Aug17-10, 08:36 PM
......So far I have typically used MATLAB for my work, but I feel like this will limit me when I apply for a job, since companies may not be willing to shell out 1000's in licensing fees if they can just use open source products.....

Most companies I know of will shell out the $$ for licensing fees as opposed to using open source, for example my employer will not allow us to use open source codes so that they avoid licensing issues down the road.