Re: Converting Mathematica code to C++

*To*: mathgroup at smc.vnet.net*Subject*: [mg88274] Re: [mg88251] Converting Mathematica code to C++*From*: jmt <jmt at dxdydz.net>*Date*: Wed, 30 Apr 2008 04:25:21 -0400 (EDT)*References*: <200804291051.GAA28369@smc.vnet.net>*Reply-to*: jmt at dxdydz.net

Hi, The company I am currently working for recently asked me to evaluate the transformation of a complex Mathematica code into C++. So I considered using MathCode C++. In short : MathCode C++ is a wonderful tool when you start a project, but when your already written Mathematica code uses mostly all features available in Mathematica, the task of conforming Mathematica code to MathCode C++ (MathCode C++ understands only a subset of Mathematica) is very frustrating ; rewriting all in C++ seems easier, because you can then use all features of C++. Also note that Mathematica code can often be optimized, and that most of numerics in Mathematica hide C/C++ code, so that a gain using efficiency of C++ is not dramatic. Finally, your code must be parallelized if you want it to run on a cluster : the task of parallelizing code is a prerequisite, and certainly not easy. Afterwards, on a cluster, the un-parallelized code is only a kind of glue code, not needing to be fast ; and Mathematica is great for this kind of tasks. In your case, I should have a look on Grid Mathematica. On 2008 04 29, Charlie Brummitt wrote: > Hi all, > I am considering running my research project on a computer cluster on > campus. However, the computer cluster requires the programs to be in C++, > and I've already coded much of the project in Mathematica. Do converters > such as MathCode C++ > <http://library.wolfram.com/infocenter/TechNotes/4694/> work > well? Or do I need to re-write everything in C++ (not to mention learn > how to code in C++)? > > If it's relevant, my project calculates the Lyapunov exponents of partial > differential equations, and the goal is to find the simplest chaotic PDE. > > I'm considering trying Intel's Compiler 10.1 for MacOSX, but I am very > reluctant to abandon Mathematica to learn to use Intel's interface and > others' PDE solvers in C++. > > Thanks to infinity, > > Charlie Brummitt > University of Wisconsin - Madison -- ---------------------------------------- Informatique technique et scientifique http://www.dxdydz.net Jean-Marie Thomas +33 (0)1 75 57 60 75 +33 (0)6 37 18 86 63

**References**:**Converting Mathematica code to C++***From:*"Charlie Brummitt" <cbrummitt@wisc.edu>