43

Edit: When writing this I was under the impression that this was amsmath's choice. It has now been bought to my attention that it is Knuth's.

When was it decided that amsmath would have the real part notation as an uppercase fraktur variation R rather than a Re? (same question for the imaginary parts).

What was the motive for this?

IMPO the bottom line looks better and more readable.

enter image description here

Also is it not the case that the latter are far more common? Why would amsmath want writers to keep redefining the latter? The \Re and \Im are convinient but return the former.

8
  • 1
    I think they don't keep defining them, amsmath has been out there for a loooong time.
    – Manuel
    Jul 22, 2014 at 15:35
  • 9
    amsmath has nothing to do with this: \Re and \Im are defined by LaTeX in essentially the same way as in Plain TeX; apparently Knuth likes that notation. I agree with you, but that's opinion.
    – egreg
    Jul 22, 2014 at 15:38
  • 5
    This is far from the original reason for Knuth's choice, but in many fields there would be confusion with the Reynolds Number (Re), a dimensionless velocity often typeset the same way (but without operator spacing, of course). Jul 22, 2014 at 15:59
  • 3
    see also math.stackexchange.com/questions/234223/… Jul 22, 2014 at 16:00
  • 3
    I know Unicode came after TeX, but U+211C ℜ is described as "real part", so the notation isn't restricted to TeX. Jul 22, 2014 at 16:07

3 Answers 3

27

\Re and \Im are defined this way in plain.tex by knuth:

\mathchardef\Re="023C
\mathchardef\Im="023D

this means that they are "ordinary" characters (0), that they are found in the math symbol font (2 = cmsy), and they are located at (hex) positions 3C and 3D in that font.

the definitions were initially adopted into amstex along with all other names of single symbols, and from there into amsmath, unchanged.

27

It does not answer the question why but my answer shows how to get what you want to get.

Option 1 (recommended)

\documentclass[preview,border=12pt,12pt]{standalone}% change it back to your own document class
\usepackage{physics}

\begin{document}
$\!
\begin{aligned}
z &= a + b i\\
\Re(z) &= a\\
\Im{z} &= b
\end{aligned}
$
\end{document}

enter image description here

Option 2

\documentclass[preview,border=12pt,12pt,varwidth]{standalone}
\usepackage{amsmath}
\begin{document}
If $z=a+bi$ then\\ $\operatorname{Re}(z)=a$ and $\operatorname{Im}(z)=b$.
\end{document}

enter image description here

Option 3

\documentclass[preview,border=12pt,12pt,varwidth]{standalone}
\usepackage{amsmath,amssymb}
\begin{document}
If $z=a+bi$ then\\ $\operatorname{\mathbb{R}e}\{z\}=a$ and $\operatorname{\mathbb{I}m}\{z\}=b$.
\end{document}

enter image description here

1
  • In Option 1, \Im{z} allegedly produces actual braces in the output. This isn't so; the input should be \Im\{z\} as in the other examples. Feb 1 at 18:53
17

These are the relevant lines in fontmath.ltx, the file that contains the basic math settings for LaTeX:

\DeclareSymbolFont{symbols}{OMS}{cmsy}{m}{n}

\DeclareMathSymbol{\Re}{\mathord}{symbols}{"3C}
\DeclareMathSymbol{\Im}{\mathord}{symbols}{"3D}

This is the corresponding part in plain.tex:

\font\tensy=cmsy10 % math symbols
\font\sevensy=cmsy7
\font\fivesy=cmsy5

\textfont2=\tensy \scriptfont2=\sevensy \scriptscriptfont2=\fivesy

\mathchardef\Re="023C
\mathchardef\Im="023D

So the two definition point exactly to the same symbol in the same font (when the default Computer Modern fonts are used). This predates amsmath, because equivalent definitions were already in LaTeX 2.09 (which simply copied the math settings from Plain TeX).

The reason is simple: Knuth likes that notation.

There's no difficulty in changing it to give “Re” and “Im”, when amsmath is loaded:

\renewcommand{\Re}{\operatorname{Re}}
\renewcommand{\Im}{\operatorname{Im}}

Doing so has the advantage that, if a publisher prefers ℜ and ℑ, they just need to comment out the redefinition. There's nothing sacred in those symbols: one may like them or not (I don't).

6
  • 1
    unfortunately that isn't quite behaving in the same way, with Re being a symbol you can do $X_\Re$ tray that with your redefinition Jul 23, 2014 at 9:20
  • 3
    @FrankMittelbach The LaTeX manual always uses _{...} for a reason. ;-)
    – egreg
    Jul 23, 2014 at 9:22
  • 3
    but it also says to use \"{o} ... anyway plain TeX does and in reality nobody does $x_{i}$ normally. But was just making a general comment that this kind of changes the nature of the beast. One can live with it but it might be worth mentioning. Jul 23, 2014 at 12:23
  • @FrankMittelbach Bitte, T\"{u}r schlie\ss en
    – egreg
    Jul 23, 2014 at 12:35
  • 1
    @manooooh Isn’t it shown?
    – egreg
    May 14, 2019 at 8:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .