AMS-TeX

TeX Live 2024 still ships a command called amstex. Run it and the banner reads This is pdfTeX ... (preloaded format=amstex) followed by AmS-TeX- Version 2.2, and one .dvi appears. The file behind it, amstex.tex, is dated 4 October 2001 — untouched for nearly a quarter of a century. AMS-TeX is the macro package the mathematician Michael Spivak wrote on top of plain TeX for the American Mathematical Society, a way of “using TeX” parallel to and separate from LaTeX. Nobody invokes it directly any more, yet its descendant runs every time you write \usepackage{amsmath}. This page checks both halves — the frozen one and the living one — by opening the actual files.

What AMS-TeX is: a macro package stacked on plain TeX

AMS-TeX is a macro package stacked on Knuth’s plain TeX. It is neither ancestor nor sibling of Leslie Lamport’s LaTeX but a different idiom standing on the same foundation. In the 1980s it was clear that TeX could set mathematics, but expecting authors to build multiline alignments and commutative diagrams by hand was not realistic. Spivak took that on, encoding the AMS house rules — typefaces, spacing, the treatment of symbols — as macros. The manual that explains it is The Joy of TeX, and the bibliography of amsldoc.tex, shipped with TeX Live, still lists it: Michael Spivak, The joy of TeX, 2nd revised ed., Amer. Math. Soc., Providence, RI, 1990.

Because it is its own format, the markup looks nothing like LaTeX. The body is wrapped in \document\enddocument rather than \documentclass\begin{document}; headings are \head; theorem-like statements are \proclaim; and the whole visual style arrives through \documentstyle{amsppt}. The mathematical alphabets have their own names too: fraktur is \frak and blackboard bold — the hollow-stroke capitals — is \Bbb. These rest on AMSFonts, the font collection the AMS assembled, whose font names eufm (fraktur), msam, and msbm (extra symbols) are still in use on the LaTeX side today.

amstex is a format, not an engine — inside it is pdfTeX

There is no executable called amstex. In TeX Live 2024 it is a symlink to pdftex, and line 48 of fmtutil.cnfamstex pdftex - -translate-file=cp227.tcx *amstex.ini — is the instruction to dump the AMS-TeX format on top of pdfTeX. The same trick applies to latex, pdflatex, csplain, and etex, all of which are likewise symlinks to pdftex; here you can see TeX’s basic structure in the open — one engine, many formats. The amusing part is the output: although it runs on pdfTeX, amstex emits DVI. Its amstex.ini never switches PDF output on, so in that respect too the 1990s are preserved intact.

terminal
$ ls -l /usr/local/texlive/2024/bin/universal-darwin/amstex
amstex -> pdftex

$ grep "^amstex" /usr/local/texlive/2024/texmf-dist/web2c/fmtutil.cnf
amstex pdftex - -translate-file=cp227.tcx *amstex.ini

$ amstex paper.tex
This is pdfTeX, Version 3.141592653-2.6-1.40.26 (TeX Live 2024) (preloaded format=amstex)

AmS-TeX- Version 2.2

(.../amstex/base/amsppt.sty version 2.2 (2001/08/07): ... )
Output written on paper.dvi (1 page, 1168 bytes).

You can feel the separation as error messages. Hand a LaTeX manuscript to amstex and it fails on line one with ! Undefined control sequence. followed by l.1 \documentclass — AMS-TeX has no such command. Hand an AMS-TeX manuscript to pdflatex and \documentstyle, \topmatter, \endtitle and the rest each raise ! Undefined control sequence., ending with ! LaTeX Error: Missing \begin{document}. Seeing that pair of errors is the signal that the manuscript and the command do not match.

The history of amsmath, told through three generations of \frac

The constructs AMS-TeX invented and amsmath inherited are still the core of mathematics in LaTeX. Nothing shows it more sharply than three generations of \frac, all three of which are alive at once inside TeX Live 2024: line 325 of amstex.tex has \def\frac#1#2{{#1\over#2}}; line 12700 of latex.ltx has \DeclareRobustCommand\frac[2]{{\begingroup#1\endgroup\over#2}}; and line 234 of amsmath.sty has \DeclareRobustCommand{\frac}[2]{{\begingroup#1\endgroup\@@over#2}}. The plain AMS-TeX form is tidied by LaTeX into one that fences its arguments, and amsmath then swaps \over for the saved-away primitive \@@over. The moment you write \usepackage{amsmath}, your \frac becomes the third generation.

latex
% amstex.tex:325   (AMS-TeX 2.2, 2001)
\def\frac#1#2{{#1\over#2}}

% latex.ltx:12700  (the LaTeX kernel)
\DeclareRobustCommand\frac[2]{{\begingroup#1\endgroup\over#2}}

% amsmath.sty:234  (v2.17o, 2023/05/13 in TeX Live 2024)
\DeclareRobustCommand{\frac}[2]{{\begingroup#1\endgroup\@@over#2}}

\frac is the tip of the iceberg. Open amstex.tex and count the command names and you keep meeting things you take for granted in LaTeX: \dfrac, \tfrac, \binom, \text, \align, \gather, \multline, \cases, \matrix, \pmatrix, \smallmatrix, \boxed, \operatorname, \intertext, \hdotsfor, \sideset. None of them exists in plain.tex or in latex.ltx. Much of the idiom of mathematical writing in TeX, in other words, was invented neither by Knuth nor by Lamport but by AMS-TeX. You have the align environment in LaTeX because Spivak wrote \def\align.

latex
% AMS-TeX (legacy: processed with the amstex format)
\align
  (a+b)^2 &= a^2 + 2ab + b^2 \\
  (a-b)^2 &= a^2 - 2ab + b^2
\endalign

% the same thing in modern LaTeX
\usepackage{amsmath}
\begin{align}
  (a+b)^2 &= a^2 + 2ab + b^2 \\
  (a-b)^2 &= a^2 - 2ab + b^2
\end{align}

The port, 1988–1994: the package was called amstex for six years

The story of the port survives in the participants’ own words, in the Credits section of amsmath.dtx, shipped with TeX Live. Much of the code of amsmath, it says, originated in Michael Spivak’s amstex.tex; the initial work of porting it to a LaTeX package, amstex.sty, was done in 1988–1989 by Frank Mittelbach and Rainer Schöpf. In 1994 David M. Jones added support for the fleqn option and made extensive improvements to the align family of environments and to equation numbering in general, while Michael Downes at the AMS coordinated the efforts of all three. The last sentence is the telling one: versions 1.0 and 1.1 of the package were named amstex, not amsmath — the name was changed in 1994, in the document’s own phrase, to make it user-oriented rather than history-oriented.

The family that resulted is known collectively as AMS-LaTeX: the packages amsmath, amssymb, amsthm, and amscd, together with the AMS document classes amsart (articles), amsbook (books), and amsproc (proceedings). The symbols were ported in the same movement: loading amssymb pulls in amsfonts internally, and AMS-TeX’s \Bbb became \mathbb (from the msbm font) while \frak became \mathfrak (from the eufm font). Only the names changed; the letterforms are the same ones.

ComponentWhat it is and doesVersion in TeX Live 2024
amstex.texAMS-TeX itself: the macro set on plain TeXVersion 2.2, dated 2001/10/04
amsppt.styAMS-TeX’s house style; \head, \proclaim, \topmatter live hereversion 2.2 (2001/08/07)
amsmathThe core math package: align, gather, cases, and the restv2.17o (2023/05/13); jointly maintained by the LaTeX Project and the AMS
amssymbExtra symbols and mathematical alphabets; loads amsfonts internally\mathbb comes from msbm, \mathfrak from eufm
amsthmTheorem and proof environments; proof and an extended \newtheoremthe successor to AMS-TeX’s \proclaim
amscdAn environment for commutative diagrams (horizontal and vertical arrows only)for diagonal arrows, move to tikz-cd
amsart / amsbook / amsprocThe AMS document classes (article, book, proceedings)amsart is v2.20.6 (2020/05/29)

The year AMS-TeX was told it was not free software

AMS-TeX reached version 2.2 for a licensing reason, not a technical one. The change log distributed with it, amstex.bug, records under “Changes released July 2001” a request to remove the copyright notice and usage restriction that were printed to the terminal and the log on every single run. The reason given is that this restriction made AMS-TeX “not free software” for the purposes of TeX Live. Then: Changed: Version 2.2 (August 2001). So the reason the banner is so terse when you run amstex today is that a dozen-odd lines were cut out of it in 2001. Episodes like this are not rare in software history; what is rare is that the file it happened to has been shipped unchanged ever since.

How to write new mathematical documents today

There is no longer a reason to start the amstex command. Begin a new report, lecture note, or paper as a LaTeX document and load the AMS-LaTeX packages you need: amsmath for aligned displays, amssymb for extra symbols such as blackboard bold, amsthm for theorems, lemmas, and proofs. For an AMS journal or book, add amsart or amsbook as the class. What AMS-TeX has to teach is not a list of legacy commands but the habit of marking mathematical structure by meaning. Choosing among align, gather, and multline is not about appearance; it distinguishes “these should line up on the equals sign,” “these merely belong together,” and “this single formula is too long for one line.”

latex
\documentclass{article}
\usepackage{amsmath,amssymb,amsthm}

\newtheorem{theorem}{Theorem}

\begin{document}
\begin{theorem}
For all real $a$ and $b$ and every $z \in \mathbb{C}$,
\begin{align}
  (a+b)^2 &= a^2 + 2ab + b^2, \\
  \operatorname{Re}(z) &= \tfrac{1}{2}\left(z + \bar{z}\right).
\end{align}
\end{theorem}
\begin{proof}
Expand and collect terms.
\end{proof}
\end{document}
  • The body starts at \begin{document}, not \document, and the class is declared with \documentclass{...}, not \documentstyle{amsppt}.
  • Headings are \section and its relatives, not \head … \endhead; numbering and the table of contents come along for free.
  • Do not hand-build theorem statements with \proclaim; declare them with \newtheorem from amsthm, which brings a numbering scheme with it. The proof environment even places the end-of-proof mark.
  • Blackboard bold is \mathbb, not \Bbb; fraktur is \mathfrak, not \frak. Loading amssymb gives you both.
  • amscd is often enough for commutative diagrams, but move to tikz-cd as soon as you need diagonal or curved arrows.

When you inherit an AMS-TeX manuscript

The first task is not rewriting but securing a PDF you can reproduce. If old lecture notes or a publisher’s archive turn up a manuscript containing \document, \enddocument, and \documentstyle{amsppt}, try amstex oldfile.tex on it unchanged. That is most of the reason amstex is still in TeX Live 2024: there is real value in a twenty-year-old manuscript still setting exactly as it did. Once you have that baseline PDF, migrate to LaTeX plus amsmath a section at a time, comparing against the baseline as you go. Equation numbers, line breaks, and theorem counters are where a migration drifts first, so watch those in particular.

In the end AMS-TeX occupies an unusual position: frozen but not dead. The files stopped in 2001, the format is still dumped, and old manuscripts still compile. Meanwhile the work moved on to amsmath, which the LaTeX Project and the AMS maintain together and still update — the version in TeX Live 2024 is v2.17o, dated 2023/05/13. The head of amsmath.sty carries two lines side by side, Copyright (C) 1995, 1999, 2000, 2013 American Mathematical Society. and Copyright (C) 2016-2023 LaTeX Project and American Mathematical Society., so the date of the handover is itself the copyright notice. When you write \usepackage{amsmath}, the syntax running is Spivak’s; the people keeping it current are somebody else.