[Tex/LaTex] Italic in theorem environment

amsthmitalicmath-modetheorems

Consider the following theorem:

\begin{theorem}
   If $x=0$, then $xy$ is equal to 0.
\end{theorem}

The first "0" will be typeset in upright typeface and the second one in italic. Including amsthm has no effect. Is this a bug? I personally think it look very weird.

I think I know how to fix this, and this question is more about the why it is not fixed by default. However, if you have a clever trick for avoiding this, feel free to share it.

Best Answer

The reason it is in italic is because the theorem style is to typeset the text in italic. Just write $0$ to have the 0 be treated as math and thus be upright.

Related Question