*Theory Group, Institute of Physics, Jagiellonian University*

(Thanks to the Max-Planck-Institut für Physik, München, for still hosting this site)

Have you ever had problems with Mathematica fonts in EPS graphics? Do you want to have the same fonts as in your LaTeX files?

`MathPSfrag`

is a Mathematica package providing a graphics export
function that *automatically* replaces Mathematica expressions in a
graphic by the corresponding LaTeX constructs and positions them
correctly. It thus facilitates the creation of publication-quality
Enscapulated PostScript (EPS) graphics. It can also create
LaTeX independent EPS and PDF files for processing with other
programs or pdfLaTeX.

To create the nicer plot, you have to add the following instructions:

```
Needs["MathPSfrag`"];
myplot = Plot[ ... ];
PSfragExport["myfilename", myplot];
```

Simple, isn’t it?

Admittedly, there are many fine-points I will not mention on this self-ad page. In particular, when you are not happy with Mathematica’s TeXForm output (quite likely), you will want to attach your own TeX code to each label. This is still easy, but you will actually have to read the manual.

- Easy to use
- Produces lean EPS files
- Can produce stand-alone EPS and PDF image files.
- Allows previewing LaTeX rendered versions of the EPS file
- Uses psfrag commands, which can be edited with a text editor
- Free for private or scientific use

- Mathematica 4.1 or later (Mathematica 5.2 or later recommended)
- LaTeX and the following LaTeX packages
- psfrag (required)
- pst-pdf (recommended)
- auto-pst-pdf (recommended)

- pdfcrop (recommended), which requires Perl
- Ghostscript

As of January 15, 2008, the stable version is MathPSfrag-2.0.
Development will proceed in version 2.1.

Do not forget to download **CustomTicks**, too.

**MathPSfrag-2.0***stable release*(revision 55, 3Mb)**CustomTicks**by Mark Caprio. Download from MathSource.*There is a new version for Mma 6.0!*

All of the following files are included in the above package and are only separately provided for convenient direct access.

- MathPSfrag 2 article (arXiv:0801.2175 [cs.GR])
- MathPSfrag.m Version 2.0, rev. 55 (90kB)
- Full manual (1Mb, 37p.) [pdf]
- Beamer presentation [pdf]

Another useful program (which can turn psfrag-based images into PGF code) is

- MathPSfrag version 2 article (arXiv:0801.2175 [cs.GR])
- MathPSfrag, EuroBachoTeX 2007, to appear in TUGboat 2008
- MathPSfrag version 1 article (arXiv:cs.GR/0510087)

(only for archival purposes, no support)

- MathPSfrag-2.0 (beta, revision 48, manual included, 3Mb) [zip]
- MathPSfrag-2.0 (beta, revision 54, manual included, 3Mb) [zip]
- old development snapshot (2006-10-16) | zip
- HTML version of the README file
- Old Mathematica package plus example file: MathPSfrag-1.0.tar.gz | ~100 kB