January 5 2008 • 1:19 AM

Typesetting Math in InDesign

Maryanne wrote:

The geologists here produce their drafts in Word, and then I import the text into InDesign to do the final formatting. Some of them do mathematical equations using Word’s Equation Editor, and when I import their document into InDesign some of the characters do not come over properly.

Sigh. Yes. Everyone who typesets math wants there to be a seamless integration between Microsoft Word and InDesign. It would make life so much easier! But alas, I don’t think there are any easy solutions here. In fact, typesetting math often seems just as hard as doing the equations themselves. I’m going to throw out a few ideas, and then open the floor to see how other people have solved this problem.

First of all, the fact that Word’s equations import into InDesign at all amazes and terrifies me. I don’t do this, so I don’t know what kind of embedded object appears. But I have to say that I wouldn’t trust it for final high-quality printing.

In general, there tend to be two good ways to do math in InDesign, and both have their pros and cons.

Import As Graphic

First, you can save each equation as a separate image/picture and import it (using File > Place, like any other graphic) in InDesign. This is tedious and the management is tough, but it tends to work.

This is how we did the equations in my book, The Joy of Pi (using Design Science’s MathType to create the graphics, if I recall). The most annoying part of that whole project was finding out that the font changed in the book and realizing there was no way I was going to stay sane if I had to re-export all those equations. (I didn’t do the layout of that book; that was done by Maura Fadden Rosenthal. I just did the content.)

Create In InDesign

The second way to do it is to use an InDesign plug-in and do the math right on your page. The most popular plug-in for this is InMath, from ITIP. (Random note: They will be presenting two half-day seminars about typesetting math in InDesign at the Miami InDesign Conference in late February of this year.)

InMath is a very impressive and it’s awesome that it can typeset all that stuff right on the page (using paragraph styles, character styles, etc.), but (and I could be wrong here) I don’t think it imports equations from Word or any other system.

So what do you, the reader, use? Any clever ways to export as TeX and convert to something InDesign can import? What about methods for extracting Word’s equations and turning them into editable objects in InDesign?

Inquiring minds want to know!

27 Responses discussing this post. Add yours below.

  1. Scott
    January 5th, 2008 • 4:18 am • Link

    Well, If you’re a Mac User, you’ve already got a fairly serviceable freebee in your Utilities folder. Look for Grapher. Obviously, it suppose to be used for graphing functions, but it does typeset a pretty good range of math functions (the layout can be modified to suit your own tastes) and the resulting equation can be copied to the clipboard as a PDF (so can the graphed function).

    It’s not without it’s bugs and flaws, but it is serviceable (it can even do integration, differentiation, find roots, intersects, etc.). You can’t beat free.

  2. blass
    January 5th, 2008 • 11:34 am • Link

    The Mathtype word plugin by Design Science, has a standalone version that exports to wmf but retaining the ability to edit. This way I can place in InDesign, but still edit the placed equation afterwards when necessary. Usually I typset all the equations again myself, as this way a configure fonts to match my copy and, as most authors don’t take the time to learn how to properly use the plugin, they are usually a mess anyway. Strangely I can’t manage to copy from word and paste in mathtype.

  3. Eugene
    January 5th, 2008 • 12:07 pm • Link

    I had to sleep on this one, and now that I have I agree with what blass has said. I would retype all the equations right into InDesign.

    I would put this down to a two-person operation. One to set the book and the other to go through the book and find all the equations and set them. I had to do this for a book last year that every second page contained a table. All the tables contained different sizes, columns and rows. And setting tables is time consuming. So I put one person on working on the book and the other on the tables, I took the task of the tables, as I felt this was the hardest part.

    I printed out the word file and went page to page looking at the tables and setting them. At the end of the project, the book and all the tables were finished at the same time, and it was a simple copy and paste from InDesign to InDesign to fill out the project.

    If I hadn’t have had someone to do the project with me I would have looked at outsourcing it so that at least one person worked on and dealt with the tables.

    I know equations are a different kettle of fish, but both tables and equations are time consuming and I feel having a wingperson allows for full concentration on two very important aspects.

    I don’t have much experience with equations, any that I have had to deal with I have set by hand in Quark/InDesign and I have never had the need to convert from MS Word to InDesign, or use a plug in for setting math type.

  4. January 5th, 2008 • 4:43 pm • Link

    MathMagic Pro Edition for InDesign could be a solution, when Writing/Editing any simple/complex equations with the printing quality in mind.

    Also, they have a separate converter for MathType/MS Equation Editor equations, and another converter for MathML.

    Another workaround is, when you insert equations in MS Word, you may insert the equations as EPS file instead of OLE objects so that InDesign importer can handle the equations without losing the quality. Although this may take more time in MS Word side, if you have InDesign in mind as a destination, this will save you more time after all.

    Anyway, it is worth trying the Free MathMagic Pro trial version, if you are to face with equations and many scientific symbols.

  5. January 5th, 2008 • 6:07 pm • Link

    If you’re just typesetting a few equations, it might be worth gritting your teeth and using a combination of Mathematical Pi, Symbol, tabs and baseline shift. Not for the faint of heart, but if you know your stuff and already have the fonts, it might be just as easy when you factor in the learning curve of plug-ins sophisticated enough to do the job professionally. Just sayin’…

  6. David Blatner
    January 5th, 2008 • 6:14 pm • Link

    PvQ: Thank you for mentioning MathMagic. I knew about this plug-in, but I did not know it had been updated (I thought it was only for CS or CS2). The Web site looks like it is now for CS3. I am curious about it.

  7. JT
    January 7th, 2008 • 2:26 pm • Link

    If I were to run into this situation, I’d print the Word file to PDF, then I’d convert the PDF to paths with PitStop Pro. Then I’d either import the PDF directly into ID or extract the equations with Illustrator and save them out as separate files.

  8. Maryanne
    January 7th, 2008 • 4:39 pm • Link

    Thanks David for posting my question in your comments area and to everybody who has replied with suggestions. Currently what I have been doing is saving the equations out as suggested as seperate PDF’s and then pasting them into the text and although slow and a bit tricky to get the lines lined up sometimes, it works well. I will have a look at the MathMagic Pro site as well to see if that might work better for the reports that have many equations in them. Thanks everybody for your input. Much appreciated.

  9. JV
    January 7th, 2008 • 6:09 pm • Link

    I had to do this recently, and found by buying PopChar, I could access all the symbols directly without much hassle. Copy/paste where I needed. But that was only for a dozen or so lines.

  10. Andrew Herzog
    January 9th, 2008 • 10:18 pm • Link

    MathMonarch/PowerMath anyone?
    PowerMath is a standalone application with a plugin for CS2. It can typeset professional quality math and it has numerous features. For just a few equations probably not worth it though.

    MathMonarch, which was created by WestWords, has the ability to export MathType equations to a WWDOC format that can be imported via the PowerMath plugin to very nicely formatted math. This leaves the math editable at any time as long as the plugin is active.

    Please note that both of these have a learning curve that would probably be prohibitive unless you were constantly setting math.

  11. January 10th, 2008 • 9:17 pm • Link

    Hi, this is Rudi from i.t.i.p., the distributors of the InMath plug-in for InCopy and InDesign.

    I’m definitely aware of the fact that the equation import from MS-Word to InDesign/InCopy is one of the most needed but also most challenging issues.

    Me personally, I try to encourage authors to write simple equations as plain text in MS-Word, for example “1/2″ or “R2″ (instead of the square root of 2). After having imported the text into InCopy/InDesign, I can create a fraction with one click using the InMath Expression Wizard.

    For more complex equations, there is in fact only the choice between importing equation as graphics or re-keying in InDesign/InCopy with InMath.

  12. Andrew Herzog
    January 11th, 2008 • 3:49 pm • Link

    For Rudi.

    Does InMath import only 1 equation, or portion thereof, at a time or can I import a complete 70 page document that has hundreds of equations?

    PowerMath has this capability. When things are coded correctly, a complete document, hundreds of equations, can have its math built with just a few clicks.

    Correct me if I am wrong, but if I wanted to built a complex fraction in InMath that had simple fractions in it numerator and denominator, I would have to build the simple fracs first then build the complex in a different step, correct?

  13. January 13th, 2008 • 7:46 am • Link

    I’m glad to hear that Maryanne got ideas how to improve her workflow – I think that everything is better than importing equations one by one as PDF.

    But let me just throw in a few more thoughts, explicitely asking for your opinion/feedback:

    1. Is Word always the right tool to typeset text with equations? If you need to place your text into InDesign on a regular basis, you should consider replacing Word by Adobe’s InCopy. In the US, it is rather cheap, and you can use InMath for the equations. Which means: you eliminate any conversion issues completely, because the way InCopy-InDesign back and forth works perfectly, also with InMath equations.

    2. In principle, you can transfer equations as a) graphics, b) text.

    a) is possible without additional software; however, you’ll loose the capability to make changes in them.
    If you want to preserve the capability to make changes, it is possible with additional software; however, you still have lots of graphics in your document, and you need external software to make the changes. Moreover, if you change e.g. the font size in InDesign, the equations don’t adapt themselves. And you have to accept a lot of restrictions regarding fonts and the equations’ appearance.

    b) requires, in a first step, coding the equations as text in or from Word and after importing this text into InDesign, in a second step re-coding and depicting as an equation. That’s the theory, and it sounds nice. However, from my perception, there is no tool converting the Word equations into somthing that could be interpreted reliably and sensefully – for example MathML in content (!) markup. Content markup is crucial here in order to keep the mathematical sense.
    In fact, there are a few proprietary solutions in the market – Andrew described his solution above.

    3. After all: It seems to me that there is no perfect way to bring equations from Word to InDesign, from a productional point of view, but good solutions for different scenarios.

    Any comments or objections are highly appreciated!

  14. Andrew Herzog
    January 14th, 2008 • 3:35 pm • Link

    A comment for Rudi.

    Yes, the biggest problem in converting math from one form/application to another is a conversion filter. The bigger problem is that not everyone creates equations in the same fashion.

    I am willing to bet that in InMath I could create the same equation multiple ways. So that even if there was an export filter for InMath to say MathML your export codes, my export codes, and another persons’ export codes for the same equation may not be the same even if the equations looked the same on printout.

    A way to get around this would be the use of a consistent language and consistently keyed math. WWDOC was a coding language created for this purpose and can be read from and exported to ascii text by PowerMath and the ascii text can be imported via MathMonarch to Math Type.

    But again only as long as those using it key/use it in a consistent fashion, otherwise all bets are off.

  15. Maryanne
    January 17th, 2008 • 5:39 pm • Link

    Hi Rudi, a quick reply to your comments. I agree that Word may not be the proper tool to be using but as I work for government that is what we get. I had looked into InCopy and suggested it for a better work flow after hearing about it at the InDesign conference in Seattle and on this web site, but that is as far as it made it.

    Yes, when importing the equations as a pdf/graphic you have to fiddle with the size to get the proper spacing in the text and if the author changes anything in the report, then the body has to really be checked to make sure
    that the graphics are still properly inserted. So overall it really slows down the production side.

    I tried using Math Type, but found that characters did not always translate over properly. Maybe I just wasn’t using it correctly being a newbie to it. Also as I had to type it there and then transfer it over, for some of the smaller equations that are single lines, I just started to type them directly into InDesign using the Character Map and hope that it works properly but again for production flow the author needs to really check that the formula does not have any typos.

    Alas, the best scenario would be to have an import function in InDesign that works as well as the other Word import qualities it has now. Maybe an update or CS4?

  16. Ashish Dayal
    June 28th, 2008 • 6:20 am • Link

    We work with a lot of complex math and find it better to convert all equations to EPS directly from the word file itself.
    Although recently, we have faced a situation where we get MathMl embedded in an XML file(our only source), and this gets to be a huge issue. Any suggestions anyone?

  17. andreas
    June 28th, 2008 • 6:30 pm • Link

    I can only recommend latexit!! If you have a Mac go and install a latex system + latexit, best and fastest way to produce nice vector formulas for all kinds of programs!

    latexit

    Mactex, complete package

  18. CR
    November 18th, 2008 • 12:25 am • Link

    Can someone tell me if automation can be done on InMath? To explain, let us say we have equations in one format such as TeX that need to be inserted as InMath into InDesign. Does InMath allow insertion of math using scripts….js, .as etc?

    We have large math data available in word and these have to be converted to InDesign. It is huge task keying each of these complex equations into InDesign using InMath. Can someone throw light on this? Thanks!!

  19. sampy
    April 7th, 2009 • 7:52 am • Link

    Hi
    How do i work with incopy. I have one project where editor is also involved with me and i do not want to split the file.

  20. Phil
    April 17th, 2009 • 7:23 am • Link

    The MathType to EPS to InDesign solution works well in theory for organizations where authors are working in MS Word. With MathType installed you can easily convert all native MS Word equations to MathType and then export them en masse as EPS or WMF from Word. It’s also possible to change font settings globally when exporting the EPS files, which can be very handy if the original fonts don’t match those of the text in InDesign. If you’re handy with scripting you can even create a script to place the exported EPS files back into the proper locations in your InDesign layout. Also the addition of the “Edit with” capability in CS4 means that the placed EPS equations can be easily edited in MathType after they’ve been imported (very cool!).

    However, there are numerous opportunities for error in this process, mostly as a result of font issues. For example, MathType likes to use Symbol Italic for lower case Greek variables. Is creates a pseudo-font when doing this and InDesign won’t correctly display or print this font in imported EPS files. The solution would seem to be installing Symbol Italic but that is not a font you’re likely to obtain easily. Other math characters may also present problems and we often wrestle with the EPS and WMF files trying to find the “magic” combination of fonts and settings that will work. Very frustrating. Another option is to export GIF out of MathType but this is limited to 1000 ppi which is not enough to support quality offset printing (sigh). So MathType would appear to be a good solution for those who are limited to MS Word authoring environments but there are issues that need to be addressed regarding fonts.

    On another note, I’ve tried MathMagic and found it to be buggy but that was with IDCS2. Could be better with CS4.

  21. esmail
    April 18th, 2009 • 2:54 am • Link

    instlling Mathtype Software in the word 2007 or 2003 then typing this formula and copy then paste in indeisgn .
    Past Vector file .

  22. parag
    April 20th, 2009 • 4:08 am • Link

    another vote for latexit [mac only]

    Main features of LaTeXiT are : generated PDFs can be reopened (even with copy/paste) to be modified
    - LinkBack support
    - syntax colouring and auto-completion of LaTeX keywords
    - smart LaTeX errors manager
    - LaTeX palettes
    - automatic history and library management
    - included application service
    - Automator support
    - several export formats (PDF, EPS, TIFF, PNG…)

    http://www.apple.com/downloads/macosx/math_science/latexit.html

  23. Regan
    July 2nd, 2009 • 9:04 am • Link

    To All,

    We have use in Powermath in Quark 4.1. OS 9.

    My problem how to active in my system powermath dongle, we have dongle orginal.

    Any idea active any application there, any one know regarding this issue, kindly send my email id.

  24. David Blatner
    July 2nd, 2009 • 5:06 pm • Link

    @Regan: Hm, it sounds like you’re using PowerMath for QuarkXPress, right? Perhaps try a QX site, such as http://planetquark.com/

  25. MathMagic vs. MathType
    August 4th, 2009 • 11:29 pm • Link

    MathType -> EPS -> InDesign can be a typical approach.

    Having this said,
    MathMagic offers direct inserting of equation in your InDesign document, without manually exporting equation in EPS and placing the file in your InD doc.
    And just double-click on any equation to re-edit it.
    This saves you great amount of time if you have to deal with lots of equations.

    MathMagic equations are inserted in EPS format, and it can be either linked or embeded by your choice from Preferences dialog.

    The most important difference would be the automatic baseline alignment when inserted in a text box as anInline graphic object.
    MathMagic automatically align the equation’s baseline to the text line.

    If you are familiar with LaTeX or Plain TeX, or if you receive LaTex equation, you can type TeX or paste TeX directly into MathMagic window to convert it to equation on the fly.
    MathMagic reads MathML and MathType equations as well.

  26. MathType > EPS > InDesign CS4
    January 8th, 2010 • 1:04 pm • Link

    MathType > EPS > Indesign CS4 has issues whenever a sub/superscript is used in the equation. According to a techie at Design Science, the MathType’s creators, it has something to do with the code used in MathType to change font sizes that is not recognized by InD CS4…causes the equation to fail to print to PS printers, you get a “makefont” error…….has anyone else seen this? Hoping for a feasible Work Around

Subscribe to the Discussion

Get the ongoing discussion surrounding "Typesetting Math in InDesign" delivered to you. Click here to subscribe via RSS.

Leave a Reply

You can use limited HTML tags, such as <em></em> for emphasis/italics and <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> .

InDesignSecrets reserves the right to edit and/or remove posts and comments.