Is there a simple way to copy mathematical expressions between Mathematica and Maple (or at least in one direction)? I mean only expressions built from numbers and predefined mathematical functions, whithout any patterns or programmatical constructs like Function, Map or Nest.

Ideally, I want functions with different definitions to be automatically adjusted, for example the Mathematica expression EllipticF[Pi/6, 1/4] should be converted to the Maple expression EllipticF(1/2, 1/2).

  • 1
    $\begingroup$ it may well be that other solutions will work much better but I think for this question one should at least mention MathML, which (in its content markup version) is the official standard aiming to make exactly such exchange between programs more easy. Have you tried that (copy/paste or import/export as MathML)? I probably should note that my own experience with MathML is limited and I 'd expect problems when using it in practice, but probably it's worth a try. And both companies were involved in the specification so you could well ask for official support if something won't work :-) $\endgroup$ – Albert Retey Sep 7 '13 at 10:28

I assume you have Maple to use. If so, Simply open Maple and type the Mathematica command itself directly into Maple using the FromMma package built-into Maple, like this:

with(MmaTranslator); #load the package
(*[FromMma, FromMmaNotebook, Mma, MmaToMaple]*)

and now can use it


Mathematica graphics

One can also use Maple convert command with the FromMma option, like this:

convert(`Integrate[Cos[x],x]`, FromMma);

Mathematica graphics

For your example:

FromMma(`EllipticF[Pi/6, 1/4]`);

Mathematica graphics

You can also use a Mathematica computational expression, not just single commands, like this, and then use the resulting Maple command inside Maple:

r:=convert(`Table[i,{i,10}];`, FromMma);
(* r := [seq(i, i = 1 .. 10)] *)

Now run the result in Maple:

(*[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]*)

see http://www.maplesoft.com/support/help/Maple/view.aspx?path=MmaTranslator for information on the MmaTranslator package.

For translating Maple back to Mathematica: The only program I know about that converts Maple to Mathematica is http://library.wolfram.com/infocenter/Conferences/5397

From Maple 9 Worksheets to Mathematica Notebooks

by Yves Papegay. However, I can't find the actual program or the software. You can try to contact the author on this. This was from The 2004 Wolfram Technology Conference.

  • $\begingroup$ Thank you very much! Your answer helped me a lot. Do you by any chance know how to convert Maple expressions back to Mathematica? $\endgroup$ – Vladimir Reshetnikov Sep 6 '13 at 23:17

You can open a whole Mathematica notebook in Maple using its Open... menu, and all expressions in the notebook will be converted to Maple representation:

Open Menu in Maple


Convert Maple expressions to Mathematica:

Through latex: enter image description here enter image description here

Through free form input:

enter image description here enter image description here


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.