# Typesetting Mathematics According to the ISO Standard

In The Princeton Companion to Applied Mathematics we used the conventions that the constants e (the base of the natural logarithm) and i (the imaginary unit), and the d in derivatives and integrals, are typeset in an upright font. These conventions are part of an ISO standard, ISO 80000-2:2009. The standard is little-known, though there is an excellent article about it in TUGboat by Claudio Beccari, and Kopka and Daly’s A Guide to $\LaTeX$ has a page on the standard (in section 7.4.10 of the fourth edition and section 5.4.10 of the third edition). An extract from The Princeton Companion to Applied Mathematics (page 178) showing the upright e, d, and i in one equation.

The standard goes into great detail about how all kinds of mathematical notation should be typeset. It is unclear how the typesetting choices were made or who was on the technical committees that made them. Nevertheless the recommendations are well thought-out.

The most interesting aspects of the standard concern the use of an upright versus a sloping font, which in practice usually amounts to roman versus italic.

1. Variables and generic functions are written in italic. This, of course, is standard practice.
2. Mathematical constants whose values do not change are written in roman. Thus e, i, and $\pi$ should be in roman font. However, standard $\LaTeX$ fonts do not have upright lower case Greek letters, so an italic $\pi$ is unavoidable.
3. Mathematical functions with a fixed meaning, such as exp and sin, are written in roman. Of course, $\LaTeX$ has such definitions built in for many standard functions, but it is a common error for inexperienced users to write, for example, $sin(x)$ (giving $sin(x)$) instead of $\sin(x)$ (giving $\sin(x)$). The best way to define macros for additional functions is via \DeclareMathOperator, assuming you are using the amsmath package:

\DeclareMathOperator{\diag}{diag}

4. Mathematical operators are written in roman. This includes the d in derivatives and integrals.

Although the second and fourth of these rules are not widely followed, they are appealing in that they distinguish variable quantities from fixed ones.

There are some subtleties and some dubious cases.

• A capital delta may appear in both forms: as an operator, hence roman, as in the forward difference operator $\Delta(f) = f(x+h) - f(x)$; and combined with a letter to denote a variable, hence italic, as in $A + \mathnormal{\Delta}A$ (where in $\LaTeX$ the latter delta is typed as \mathnormal{\Delta}).
• The ISO standard explicitly says that named polynomials, such as the Chebyshev polynomials, should be written in roman: $\mathrm{T}_n(x)$ instead of $T_n(x)$. This certainly follows the rules above, since such polynomials have a fixed meaning, but I have never seen the upright font being used for such polynomials in practice.

I’ve started to use rules 1–4 in my recent papers, most thoroughly in this recent EPrint on matrix functions, and intend to use them in my future writing. In doing so, I am using the following $\LaTeX$ macros, based on those suggested in Beccari’s article.

% The number e'.
\def\eu{\ensuremath{\mathrm{e}}}
% The imaginary unit.
\def\iu{\ensuremath{\mathrm{i}}}
% The differential operator.
\def\du{\ensuremath{\mathrm{d}}}


The \ensuremath is not essential, but it means that you can type \eu, etc., outside math mode—for example, in the phrase “the limit of this sequence is \eu”. You may want to rewrite the \def commands using \newcommand, so that if the \eu command has already been defined an error will be issued:

\newcommand{\eu}{\ensuremath{\mathrm{e}}}


\int_C\frac{\eu^z}{z}\,\du z = 2\pi\iu.

Note that if you are using Beamer with the recommended sans serif fonts then mathrm should be replaced by \mathsf in these definitions.
`