Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have to solve about 30 symbolic equations simultaneously. Mathematica is taking more than 24 hours to solve it on a 6 core system and now I have to run that on a cluster. In order to do so I need to convert GUI based code into text user interface code. Any suggestions how to proceed ?

share|improve this question
Have you tried; InputForm[HoldForm[your equation here]]? – RunnyKine Jul 29 '14 at 6:28
No, I have no knowledge of text user interface code. I have to type few equations and one solve command. How do it do it? – Qwerty Jul 29 '14 at 10:02
Could you please explain what is "GUI based code" and "text user interface code"? I have been using Mathematica for over 10 years and never came across these terms before. – Oleksandr R. Jul 29 '14 at 15:11
  1. Start with a Notebook with your complete set of entries in it.

  2. Select the Input cells that contain the definitions and commands you wish to run

    • You can select all Input cells by Alt+clicking the cell bracket of an Input cell
  3. Mark the cells as Initialization Cells using menu Cell > Cell Properties

  4. Use menu File > Save As... and save a Mathematica Package (*.m)

The .m file that you create will contain InputForm expressions for all your definitions and commands.

share|improve this answer
Thanks a lot for sharing that.. but should it not be in .txt format? – Qwerty Jul 29 '14 at 13:46
@Qwerty It is a text format; you could rename .m to .txt if necessary. However I suggest that you do not as Mathematica expects .m and and will use that by default in some cases. How are you planning to use the contents of the file? You should be able to Get the file directly. – Mr.Wizard Jul 29 '14 at 13:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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