To insert text in mathmode, there are a couple of commands:
\mathrm
for Roman script,\mathbf
for bold weight,\mathit
for italic shape,\mathsf
for the sans serif variant,
and so on. Now, sometimes I would like to have some math entities typeset upright (see for example How to best typeset "special" constants (complex unit i, Euler's number e,...)?).
I understand that \mathrm
sets the text in Roman and upright, but in some cases I do not want serifs (e.g., in presentations). The command \mathup
does not seem to exist.
What is recommended way to set upright text in math mode?
\mathsf
? See this.\upshape
.\mathup
: Is \mathrm really preferable to \text?\newcommand{\mathup}[1]{\text{\textup{#1}}}
? This works for me.