1 diffs-m.txt [1999/12/15] American Mathematical Society
3 This is a synopsis of the principal differences between various versions
4 of the amsmath package and its companion packages.
6 A synopsis of changes in the "AMS-LaTeX" distribution is included at the
7 end of this file. See also diffs-c.txt in the amslatex/classes area.
9 Those upgrading from version 1.2 to version 2.0 will probably be
10 interested in the question:
12 After I upgrade will anything fail in my pre-existing documents?
14 Certain of the bug fixes have the potential to affect the output of
15 existing documents in the following ways:
17 ---Vertical spacing for some displayed equations will change because
18 "abovedisplayshortskip" is now applied when possible.
20 ---Incorrect horizontal spacing for certain math constructs will change,
21 e.g., for \iint\nolimits or a subscript on a double-accented letter.
23 ---The default subscript placement in displayed formulas for \varinjlim,
24 \varprojlim, \varliminf, \varlimsup is now below rather than to the
25 side. To get the old behavior, add \nolimits---e.g.,
26 \varliminf\nolimits_{...}.
28 ---Ellipsis dots in text (\ldots or \dots) will now behave the same as
29 in standard LaTeX; the surrounding space may therefore change.
31 During regression testing we found some errors cropping up in documents
32 from incorrect usage that had not been caught with version 1.2. Although
33 these errors are relatively rare, documents containing such usage will
34 need to be corrected before they will run properly with version 2.0:
36 ---Use of two mutually exclusive display structures for the same
37 display. In this example the outer \[ \] are redundant:
45 ---Inadequate argument markup for math accents:
49 This should have been written with braces surrounding the argument of
50 the \hat command: \hat{\mathcal{C}}.
52 For documents where error messages crop up after the upgrade, there are
53 various possible approaches, including:
55 (a) Change instances of incorrect usage (if applicable).
57 (b) Put a copy of amsmath.sty version 1.2 into the home directory of the
58 document. Then it should continue to work the same as before.
60 (c) Use the snapshot package in combination with a shell script to
61 arrange that version 1.2 of amsmath is found instead of 2.0 when
62 processing the document. See ftp://ftp.ams.org/pub/tex/snapshot.*. This
63 approach requires a certain amount of technical knowledge.
65 (d) Downgrade to version 1.2 again.
67 ========================================================================
68 Changes in amsmath 2.0 [November 1999]
70 ---The AMS-LaTeX User's Guide (amsldoc.tex) has been turned into the
71 AMSmath User's Guide by moving the amsthm documentation into a
72 separate file (amsthdoc.tex) in the amslatex/classes area.
74 ---Restored normal use of "shortskip" spacing in single equations.
76 [!! NOTE: This means that page breaks may change in existing documents.]
78 ---Restored normal use of available shrink around binary operators in
81 ---Fixed poor subscript placement for double-accented letters. Math
82 accent handling was reworked in the process in such a way that the
83 capitalized forms of the math accent commands are no longer necessary.
84 \hat{\hat{X}} will do proper alignment of the second accent. \Hat et
85 cetera are retained for compabitility reasons. (Thanks to Javier Bezos
86 for donating some code from his accents package.)
88 [!! NOTE: Improper math accent use will now produce wrong output.]
90 Suppose that we have \boldH defined in the preamble as
91 \newcommand{\boldH}{\mathbf{H}}. Then the following examples illustrate
96 \hat\boldH Works OK, but deprecated by the LaTeX book
97 \hat\mathbf{H} Not OK! Output will be incorrect.
99 Since the output will be wrong, amsmath gives an error message when the
100 last variant is detected.
102 ---The following kinds of mixed structures worked by happenstance with
103 amsmath 1.2, although they should have produced an error message.
104 With amsmath 2.0 they will produce an error or warning message.
106 [!! NOTE: Potential error messages]
108 % Outer \[ \] is redundant
116 % Outer \begin{equation*} ... \end{equation*} is redundant
118 \begin{equation*}\begin{alignat*}{2}
123 % No printed material is allowed between \begin{equation} and
126 \begin{equation*}\left \{
132 ---diff12.tex is replaced by diffs-m.txt and diffs-c.txt, with the
133 latter moving to the amslatex/classes area.
135 ---Added an "?" option which gives some information about the available
138 ---The amsmath definitions for matrix, pmatrix, and cases are
139 incompatible with the plain-TeX syntax for \pmatrix, \matrix, and
140 \cases, which are used occasionally by some authors in LaTeX
141 documents. In version 2.0 the error messages resulting from the
142 plain-TeX syntax have been made more intelligible.
144 ---If you need the boldsymbol facilities of the amsbsy package, use of
145 the "bm" (boldmath) package is recommended instead for new documents.
146 The amsbsy package is retained for compatibility with existing
147 documents. If you have a recent version of LaTeX (1998 or newer) you
148 already have the bm package; otherwise you may need to get it from
149 CTAN. (It is not an AMS package.)
151 ---\iint\nolimits: Fixed poor placement of subscript (also \iiint,
154 ---\varinjlim, \varprojlim, \varliminf, \varlimsup: Default to
155 \displaylimits instead of nolimits.
157 ---Fixed alignedat so that it doesn't take the first token of its
158 contents and try to interpret it as a number.
160 ---Leave text version of \dots and \ldots unchanged.
162 ---Changed \numberwithin so it no longer assumes previous definition of
163 \thesomething contained no prefixes.
165 ---\mathbf{\Gamma}: Leave cap Greek letters alone instead of converting
166 them from variable (fam 7) to fixed (fam 0). \mathbf{\gamma} still
167 fails---but that's a math font problem.
169 ---\mathindent is aliased to \@mathmargin so that when the fleqn option
170 is used, users can reset it as the LaTeX book advertises.
172 ---With the showkeys package: Corrected loss of marginal notes when
173 labels occurred inside an align environment.
175 ---Carried over some tweaks (\bmod, \right/leftarrowfill) from the 1996
176 version of plain.tex.
178 ---Adjusted spacing of overarrow@ and underarrow@ to allow more room for
179 larger cmsy arrowheads.
181 ---Corrected spurious "overfull \hbox" warnings for \xrightarrow.
183 ---Corrected poor spacing for \xleftarrow.
185 ---Removed the \leavevmode in \smash which caused trouble for some
186 applications (e.g., the crop package) that expected the original
189 ---Changed \def to \newcommand/\newenvironment where appropriate.
191 ---Use \sqrtsign instead of \@@sqrt (but include a backward
192 compatibility hack for the latter).
194 ---Left brace in \env{cases} environment would fail to work in
195 certain circumstances: Fix by using \lbrace instead of \{.
197 ---Use \ignorespacesafterend where applicable instead of
200 ---Protected commands in the definition of \theequation were
201 incorrectly expanded by the subequations environment when copying
202 the definition to \theparentequation: Fix by using \protected@edef.
204 ---Spurious extra space following punctuation at that end of a display:
205 In \math@cr, \math@cr@@, etc, use \iffalse{\fi instead of simply { to
206 keep an unwanted mathord atom from being added at the end of the
207 current math list; added \endmultline@math to work around a similar
208 sort of problem specific to the `multline' environment.
210 ---Various wrong results or no effect for \displaybreak inside "align",
211 "alignat", etc. Resetting \dspbrk@level in the \everycr of
212 \@display@init cleared most of these up.
214 ---Changed \displaybreak to issue an error message if enclosed in boxing
215 environment that will keep it from having any effect.
217 ---Turned off \displaybreak during the measuring phase of multline.
219 ---Fixed some numbering problems with multline and multline* and error
222 ---Use \@gtempa instead of \@tempa where assigned globally (standard
223 save stack precaution).
225 ---Save and restore \column@ to keep aligned from screwing up the column
226 counting of a parent align environment. Made \column@ assignments
227 uniformly global, except in a couple of places where the risk of side
228 effects seemed too great.
230 ---Error recovery for misspelled '\end{multline}' was not very helpful.
231 Improve \collect@body along lines suggested by Hellström.
233 ---Fixed up certain number placement problems with align
235 ---Add \alignsafe@testopt to work around a LaTeX bug: when a nested
236 alignment environment that takes an optional argument has an empty
237 first cell (i.e., begins with an &) LaTeX's optional argument
238 scanning screws up the alignment state.
240 ---Add `mathdisplay' environment (internal use) to correct several
241 problems of \[ \] and the `equation' environment arising from the
242 previous implementation as a degenerate case of `gather'.
244 ---It is possible now to use \eeq as an abbreviation for \end{equation}
245 (one of the consequences of the preceding change). But still not \eal
246 for \end{align} or certain other display structures.
248 ---Reorganize `split' internal calling sequence to go along with the use
249 of `mathdisplay' in \[ \] and `equation'.
251 ---Suppression of LaTeX error messages during measuring phase made
252 primitive TeX errors harder to understand; stop suppressing. (As a
253 result, users will sometimes get redundant error messages now.)
254 Remove obsolete Sb, Sp environments again.
256 ---The file amsintx.dtx was removed from the distribution pending
259 ---Remove the \ifinany@ switch, use \spread@equation instead to achieve
262 ---Remove unbracefonts@ function, no longer needed after changes in
263 math accent handling.
265 ---Got rid of the special trap for '^x that had been carried over from
268 ---Made \overline, \doteq, \longrightarrow, etc, robust.
270 ---Changed \relbar to use \std@minus---otherwise \underleftrightarrow
271 works poorly in a \DeclareMathOperator definition.
273 ---Use \new@ifnextchar in matrix, pmatrix, cases so that \\<newline>[x]
274 doesn't trigger an error.
276 ---Bug fix for nested use of \label inside minipage inside equation.
278 ---Add minalignsep after every second column in aligned, for consistency
281 ========================================================================
282 Changes in amsmath 1.2 [January 1995]
284 ---Name change; relation to the "amsfonts" package
286 In version 1.1 of AMS-LaTeX, the name of this package was "amstex". The
287 new name is "amsmath". The amstex package automatically invoked the
288 amsfonts package as well; the amsmath package does not.
290 ---Adapted for LaTeX2e
292 Old method of invocation:
294 \documentstyle[amstex]{article}% LaTeX 2.09
296 New method of invocation:
298 \documentclass{article}
301 ---Handling of options intlim, nosumlim, nonamelm, righttag, ctagsplt
305 \documentstyle[amstex,righttag,intlim]
309 \usepackage[reqno,intlimits]{amsmath}
311 Several option names were changed (mainly, they are no longer restricted
312 to eight characters):
315 nosumlim -> nosumlimits
316 nonamelm -> nonamelimits
317 righttag -> reqno [for consistency with "leqno"]
318 ctagsplt -> centertags
320 ---Character @ is no longer used as a special command prefix
322 Certain commands in the amstex pkg started with "@" instead of "\". This
323 special usage has been discontinued, except for the amscd package, and
324 then only within the CD environment. Practically speaking, this means
325 primarily that it is no longer necessary to use doubled @@ to get a
326 single printed @ character (e.g., in e-mail addresses).
328 ---The @, and @! micro-spacing commands are no longer provided
330 As a consequence of the @ character change, "@," and "@!" are no longer
331 recognized spacing commands. An \mspace command is provided that can be
332 used instead; see the AMSmath User's Guide.
334 ---Extensible arrow commands @>>> and @<<<
336 The commands @>>> and @<<< are no longer available [except in the CD
337 environment of the amscd package]; alternative commands \xleftarrow and
338 \xrightarrow are provided by the amsmath package. The sub and
339 superscripts are given through an optional resp. mandatory argument, for
342 X\xleftarrow{b}Y % superscript "b" only
343 X\xrightarrow[\alpha]{\beta}Y % sub alpha, sup beta
345 ---The command \bold has been superseded by the command \mathbf, as the
346 latter is now the standard name provided by LaTeX for this purpose.
348 ---The commands \newsymbol, \frak, \Bbb are no longer available because
349 the amsfonts package is not loaded by amsmath. In any case those
350 commands now have new names---\frak -> \mathfrak, \Bbb -> \mathbb, etc.
351 See the amsfonts documentation for further details.
353 ---The amsmath package provides \lvert and \rvert to use for vert-bar
354 symbols when they act as delimiters (compare \langle, \rangle for
355 angle-bracket delimiters). Commands \lVert and \rVert are likewise
356 provided instead of \| for paired-delimiter use of the double-vert
357 symbol. Use of | and \| for paired delimiters can lead to incorrect
358 spacing in rare cases. Further discussion is found in the AMS-LaTeX
359 user's guide (amsldoc.tex).
361 ---The ~ command is now left unchanged by amsmath; the change
362 that makes it remove a redundant preceding or following space character
363 is now done only by AMS documentclasses (in version 1.1 this was done by
366 ---The following rarely used commands are removed to the amsxtra
367 package: \accentedsymbol, \sphat, \spcheck, \sptilde, \spdot, \spddot,
368 \spdddot, \spbreve, \@))), \@(((.
370 ---The six generalized fraction commands \over, \overwithdelims, \atop,
371 \atopwithdelims, \above, \abovewithdelims are deprecated and produce
372 warning messages. Their functionality can be obtained through \frac,
373 \binom, and \genfrac instead. See amsldoc.tex and technote.tex for
376 ---The \fracwithdelims command is gone, as \genfrac provides
377 equivalent functionality (and a little more).
379 ---The optional argument of \frac that allowed changing the thickness of
380 the fraction line is gone. That functionality is now provided only
381 through \genfrac: the need to change the line thickness is so rare in
382 practice that it seems better not to burden the ubiquitous \frac command
383 with the somewhat time-consuming look-ahead process required for an
384 optional argument. I.e., this change will contribute in a small way to
385 making your documents run faster.
387 ---The commands \lcfrac and \rcfrac for left or right alignment of
388 continued fraction numerators are gone; they are replaced by an optional
389 argument of the \cfrac command.
391 ---A new command \DeclareMathOperator is provided for defining new
394 \DeclareMathOperator{\Tr}{Tr}
395 \DeclareMathOperator*{\xlim}{x-lim}
397 The * form makes the operator name produce limit-style sub and
398 superscripts, like \max or \lim. This is now the preferred method,
399 instead of using the old command \operatorname (which is, however,
400 retained for now). The command \operatornamewithlimits has been renamed
401 \operatorname*. These commands now can also be obtained through a
402 separate package amsopn, so it's not necessary to load the entire
403 amsmath package just to get that feature.
405 ---Environments "Sb", "Sp" retired.
407 The environments Sb and Sp for multiline subscripts have been replaced
408 by a single command \substack, used as follows:
410 \sum_{\substack{first line\\second line}}
412 This command can be used equally well in a subscript or superscript, and
413 provides better vertical positioning (as compared to Sb, Sp) if a
414 multiline subscript is placed on the side, as perhaps for an integral.
415 There is also a slightly generalized alternative, an environment
416 subarray that allows you to specify either centering or left alignment
419 \sum_{\begin{subarray}{l}first line\\second line\end{subarray}}
421 ---New command \nobreakdash
423 A command \nobreakdash is provided to suppress the possibility of a
424 linebreak after the following hyphen or dash. For example, if you write
425 "$p$\nobreakdash-adic" then a linebreak will never be taken between the
426 hyphen and the "adic".
428 ---The placement of equation numbers has been substantially improved for
429 align, gather, and split. Numbers will now never overlap on top of the
430 equation body (as far as we can ascertain), and they are much less
431 likely to be shifted up or down unnecessarily when there is actually
432 adequate space to leave the number in the normal place. In a few
433 remaining cases, an equation number will be shifted unnecessarily
434 because technical complications make accurate measurement of the
435 available room too difficult; for those cases a \raisetag command is
436 provided that allows you to manually adjust the vertical position of the
439 ---The [xx]align[at] family of environments has been thoroughly revised:
440 now the xalignat environment is gone, as its function has been merged
441 into the align environment (it's no longer necessary to specify how many
442 side-by-side structures, as was required for xalignat, because align
443 automatically handles any number of them). Similarly, the xxalignat
444 environment has been replaced by an environment flalign that doesn't
445 require you to specify how many side-by-side structures will be needed.
446 Certain numbering problems (presence of an equation number when it
447 should be absent, or vice versa) have also been cleared up.
449 (Thanks to David M. Jones for his substantial [volunteer] work behind
450 this change and the preceding one.)
452 ---The alignedat environment was changed to take two arguments rather
453 than one: a mandatory argument (as formerly) specifying the number of
454 align structures, and a new optional one specifying the placement of the
455 environment (parallel to the optional argument of aligned). However,
456 aligned is simpler to use, allowing any number of aligned structures
457 automatically, and therefore the use of alignedat is deprecated.
459 ---The seldom-used command \oldnos is gone; if you need it, you should
460 consult the LaTeX documentation on using fonts (e.g., fntguide.tex) to
461 find out how to construct an equivalent command.
463 ---A new subequations environment causes all numbered equation
464 environments within its scope to be numbered (4.9a) (4.9b) (4.9c) etc.,
465 if the preceding numbered equation was 4.8. A \label command immediately
466 after \begin{subequations} will produce a \ref of the parent number
467 `4.9', not `4.9a'. The counters used by the subequations environment are
468 parentequation and equation and standard uses of \addtocounter,
469 \setcounter, etc., are possible with those counter names.
471 ---The amsmath package (unlike amstex) respects the setting provided by
472 the documentclass for putting equation numbers on the right or the left.
473 [Technical note: a documentclass that has leqno as the default should
474 explicitly pass that option to the amsmath package with
475 \PassOptionsToPackage in order for it to be effective.]
477 ---The fleqn option for left-aligned instead of centered equations is
478 now supported (thanks to David M. Jones).
480 ************************************************************************
481 The remainder of this file discusses some changes that do not directly
482 pertain to the amsmath package but to the parent distribution known as
485 ========================================================================
486 Changes in AMS-LaTeX 2.0
488 ---The AMS-LaTeX User's Guide (amsldoc.tex) is split up into amsldoc.tex
489 and amsthdoc.tex, with the latter moving into the "classes" area.
491 ---The file amslatex.faq was split into amsmath.faq and amsclass.faq.
493 ---The file amslatex.bug was done away with; most of the information was
494 merged into diffs-m.txt, diffs-c.txt, amsmath.faq, and amsclass.faq.
496 ========================================================================
497 Changes in AMS-LaTeX 1.2
499 ---Adapted for LaTeX2e
501 AMS-LaTeX 1.0 and 1.1 were designed to work with LaTeX 2.09, which
502 became obsolete in 1994 with the appearance of "LaTeX2e". AMS-LaTeX 1.2
503 has been extensively adapted to take advantage of various features of
504 LaTeX2e. It is no longer a separate TeX format---i.e., it does not need
505 to be invoked by a separate "amslatex" command.
507 ---LaTeX 2.09 font commands (\bf, \it, etc)
509 Pre-existing documents will for the most part continue to work fine
510 without requiring any changes. However, depending on the installation
511 options used for your copy of AMS-LaTeX 1.1 you may need to update the
512 options list of the \documentstyle command by adding newlfont, for
515 \documentstyle[newlfont]{amsart}
517 ---The packages amsfonts, amssymb were moved to the AMSFonts
518 distribution. They used to be included in the AMS-LaTeX distribution for
519 pragmatic reasons but their natural home is with the AMSFonts
522 ---Package amstex renamed to amsmath
524 The amstex package has been renamed amsmath. The old name `amstex' came
525 from the fact that version 1.0 was a more or less straight port into
526 LaTeX of selected portions from the macro package AmS-TeX written by
527 Michael Spivak, but the historical origins of the package are likely of
528 less interest to the general usership---especially looking to the
529 future---than a straightforward declaration in the name `amsmath' of the
530 sort of features that are provided.
532 Another important reason for the name change was to make possible some
533 progress that would be out of the question (because of the impact on
534 existing documents) if the name `amstex' were retained. For example,
535 unlike amstex, amsmath doesn't automatically load the amsfonts package,
536 as that package was moved out to the AMSFonts distribution as described
537 above. If this change were not accompanied by a name change, many
538 existing documents would have to be updated by hand (adding
539 \usepackage{amsfonts}) in order to run without error. A frozen version
540 of amstex.sty is provided for processing pre-existing documents; it
541 won't have active maintainence henceforth except for bug fixes. For new
542 documents, authors should use the amsmath package.
544 Therefore, "\usepackage{amstex}" is incorrect usage---do not rely on the
545 1994 edition of `The LaTeX Companion' in this respect (unless you obtain
546 the errata for Chapter 8; see
547 http://ctan.tug.org/info/compan-rev/ch8.pdf).
549 ---New documentclass amsproc
551 A new documentclass amsproc was added for collections of articles, such as
552 the proceedings of a conference.