LaTeX Tip: Operator Names

I’ve always written:

P(X>Y)
E[X=3]

Which gives you something like this:

P(X>Y)\\E[X=3]

The problem here is that the probability and expected value operators are italicized as if they were variables. I should have been writing:

\operatorname{P}(X>Y)
\operatorname{E}[X=3]

Which will render them in the plain old Roman font like \lim or \min.

Wikibooks has a nice snippet on it with some more details.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>