# Spacing around divide (|) symbol [duplicate]

LaTex by default sets fairly small spaces around "divide" symbol (|). Is there a way to force larger skip (e. g. force LaTex to treat | as binary operator or = symbol)? MWE would be fairly simple:

\documentclass{article}
\begin{document}
What is set by default:

$a|b$

What I want:

$a\hspace{0.28em}|\hspace{0.28em}b$ %for some reason I can't use mu in \hspace, but 1mu=1/18 em and 0.28em=5mu=\thickmuskip.
\end{document}


## marked as duplicate by egreg math-mode StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); Feb 15 at 14:30

• \mid is what you want. $a\mid b$ – Sigur Feb 15 at 13:08
• By default, LaTeX inserts no whitespace at all around the | symbol. In contrast, if you employ the macro \mid, LaTeX inserts a thickspace -- as is appropriate for a relational operator -- around the vertical bar. – Mico Feb 15 at 13:15
• The | symbol is most commonly used for absolute values, as in |x|, where no extra spaces are desired. – Harald Hanche-Olsen Feb 15 at 14:06