1

Is \mid equivalent to \, | \, ?

I am asking this because, \mid does not cooperate with \big. However \,\big| \, works fine. I typically use these expressions when defining sets, for instance: enter image description here

Surb
  • 319

1 Answers1

4

They're not equivalent. The space around \mid is \thickmuskip, which is normally twice as big as \thinmuskip (which is what's inserted by \,).

If you want a bigger bar as a relation symbol, use

\Bigm|

(the m stands for “middle” and, by convention, this yields a relation symbol).

If you're on LaTeX, don't use $$. You should also use \Bigl for left delimiters and \Bigr for right delimiters.

Let's compare the results:

\documentclass{article}
\usepackage{amsmath}

\begin{document}

\begin{gather}
\Bigl\{ \sum_{k=1}^n k \,\Big|\, n\leq 5 \Bigr\} \\
\Bigl\{ \sum_{k=1}^n k \Bigm| n\leq 5 \Bigr\} \\
\Bigl\{\, \sum_{k=1}^n k \Bigm| n\leq 5 \Bigr\}
\end{gather}

\end{document}

In the last one I added a thin space to avoid a clash by moving the brace slightly farther than the summation.

enter image description here

egreg
  • 1,121,712