which is best programming language for applied mathematics

in #mathematics7 years ago

My two favorite programming languages are at opposite ends of the computer spectrum: Mathematica…
QuickScreencapture_20180128-163735.png
Credit

and assembler!
QuickScreencapture_20180128-163229.png
Credit

For rapid prototyping, doing symbolic manipulation, and creating a line of reasoning that you can easily turn into a publishable paper without ever leaving the language, it’s hard to beat Mathematica. I understand Maple is also excellent for these things, and it has its own following. The distance between what an applied mathematician scribbles on a whiteboard and what you type into Mathematica is much less than with conventional languages like C; the editor is two-dimensional so you can create typeset-looking mathematical equations that actually compute. If there is a logic error in your reasoning, Mathematica can frequently expose it right away. They are interpretive languages that free you from having to worry about limits on the sizes of integers, and even the hazards of rounding error. If you ask for ArcTan[1], you get π/4, not a floating-point approximation to π/4. And the graphics capabilities are fantastic.

If you don’t like the long learning curve for Mathematica, and I wouldn’t blame you if you do because it’s a monster climb, Python also makes a very good language for rapid prototyping that can do many of the same things Mathematica and Maple can do. Matlab also has a following and can do high-level mathematics interpretively. These programming environments allow an applied mathematician to concentrate on the math and not have to worry so much about the internal workings of the computer.

But Mathematica, Maple, and Python have one big flaw if you’re a High-Performance Computing (HPC) guy like I am… they’re SLOW. People sometimes urge me to turn my Mathematica notebooks into C++ or C or some other compiled language to get more speed once the prototype works. But if it’s speed I want, the best language is the native assembly language of whatever computer you’re using. Assembly programmers are very rare these days, and many computer science curricula don’t even require it for graduation, but it’s the ultimate way to make a computer go as fast as possible and make the most efficient use of resources. Even the smartest optimizing compilers produce code that is usually three to ten times slower than well-crafted assembly code. I’ll write C in a conventional programming environment that supports the ability to create large, complicated codes, profile the code to find the parts consuming the most time (or memory or other resource), and then optimize those with assembly code. If you are the type of applied mathematician who loves solving puzzles, laying out machine-level instructions to create a screamingly fast version of an algorithm is about as fun as it gets. For me, anyway.

Sort:  

Use C++ thats the one i think is more mathematics problems type .please upvote my latest post @biggy .oh and please follow me

i would also mention GNU Octave as an alternative to Matlab - for those who can't afford license, or simply like free software and all the possibilities that it gives you

Coin Marketplace

STEEM 0.16
TRX 0.13
JST 0.027
BTC 58188.83
ETH 2585.51
USDT 1.00
SBD 2.40