Message Boards Message Boards

0
|
9073 Views
|
3 Replies
|
0 Total Likes
View groups...
Share
Share this post:

Export formulas as images to excel

Posted 9 years ago

Hi,

Is there a way to export a formula written with Mathematica to an XLS file. I tried to do so, but the formula changes its appearance a lot when exported. For example subscripts would appear as words rather than notations. I tried to convert formulas to images before exporting them. But then, when I open the exported excel sheet, only file names, which contain the formulas images, appear rather than the images themselves.

Thanks

POSTED BY: Saf Al
3 Replies

Similar to the original post, except I want to programmatically direct my Mathematica 13.2.1 front-end to export TraditionalForm expressions as images or (better) as a MathML to Excel version 16.72. For example:

modelC2 = HoldForm[Plus[M,Times[A[1],Cos[Plus[Times[Times[2,Pi,Power[\[Tau][1],-1]],t],\[Phi][1]]]],Times[A[2],Cos[Plus[Times[Times[2,Pi,Power[\[Tau][2],-1]],t],\[Phi][2]]]]]];

How would I go about exporting modelC2 to Excel programmatically from within Mathematica preserving its TraditionalFormat in Excel?

NOTE: Applying a ReleaseHold on modelC2 and then exporting it to Excel does work, except that I've lost the TraditionalForm format. I've had zero success exporting MathMLFormat @ modelC2, although when I manually copy and past the MathML code from Mathematica to Excel, it almost works -- but I do not want to do that manual copying and pasting with hundreds of formulas.

POSTED BY: A. Chase Turner
Posted 9 years ago

One possibility is to highlight the formula (or any text) of interest and then from the Edit menu select Copy As and then select Metafile (Edit/Copy As/Metafile). Then paste into Excel.

POSTED BY: Jim Baldwin
Posted 9 years ago

Thanks for your reply. The method, you suggested, worked perfectly. And it seems that I am going to use it. However, I was hoping that the Mathematica-Command "Export" can do that automatically, since I have a list of formulas that I want to export to Excel.

Regards

POSTED BY: Saf Al
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract