Re: Mathematica to .NET compiler
- To: mathgroup at smc.vnet.net
- Subject: [mg79223] Re: Mathematica to .NET compiler
- From: David Bailey <dave at Remove_Thisdbailey.co.uk>
- Date: Sat, 21 Jul 2007 04:31:24 -0400 (EDT)
- References: <f7pon7$prc$1@smc.vnet.net>
Jon Harrop wrote: > Would anyone be interested in a compiler that translates Mathematica code > into code that runs on Microsoft's .NET? > > This would allow general purpose programs written in Mathematica to execute > much more efficiently. > Translation to Java would make more sense, because it would work cross-platform, but Java or .NET, there are serious problems as I see it. You would only be able to compile about as much as the Compile command within Mathematica can achieve. True, that command only compiles to a form of P-code, but it has the advantage that it can invoke Mathematica for the bits it cannot handle without needing to switch process. I would imagine that this would put such code at a disadvantage WRT the output of Compile - at least in many cases. There is, of course, MathCode, which translates a subset of Mathematica to C++: http://www.mathcore.com/products/mathcode/mathcodec++.php The subset in question is described on a link, which was unfortunately dead when I pressed it. I would imagine their subset would be much the same as yours would need to be. Because I have a background in writing compilers, I once gave some serious thought to the compile-to-Java approach. It would be interesting to know other people's experiences with MathCode. David Bailey http://www.dbaileyconsultancy.co.uk