0

I am referring to David Carlisle's answer to the question on how one can achieve the same spacing around \middle| as around \mid. Please note, that I am using unicode-math and LuaLaTeX.

The answer is to use the unicode versions \Uleft, \Umiddle and \Uright and state the class explicitly, e.g.

\documentclass{article}
\begin{document}
$\Uleft( A \Umiddle class 2 | B \Uright)$
\end{document}

Now, I have

\renewcommand{\left}{\Uleft}
\renewcommand{\right}{\Uright}
\renewcommand{\middle}{\Umiddle class 2 }

after \begin{document} and I am quite happy with the spacing.

However, sometimes I need to resort to the explicit sizes \big, \bigg, ... and so on and their respective left and right counterparts. My naive hope was that their are also unicode variants and \Ubig class 2 \vert would do the trick. But those commands do not exist.

How do I get a class-2 spacing for \big, \bigg, ... and so on?

1
  • @DavidCarlisle - Doesn't \biggm| (or \biggm\vert) work out to the same as \mathrel{\bigg|}?
    – Mico
    Commented Feb 21, 2020 at 21:16

1 Answer 1

1

since you want a class 2 (\mathbin) \Big | you can simply use

 a  \mathbin{\Big|}  b

which would work in luatex as in pdftex.

for class3 (\mathrel) latex already defines \Bigm.

4
  • OK. Actually, I hoped for an answer which would allow me to redefine \big, ... and so on once in the beginning of the document such that I do not need scan for all occurrences in my document (its >300 pages). Unfortunately, the usual trick \let\obig\big and \def\big#1{\mathbin{\obig #1}} did not work, because \bigl is defined as \mathopen\big and than things go terrible wrong, because I end up with \mathopen\mathbin for \bigl. :-(
    – nagmat84
    Commented Feb 21, 2020 at 18:56
  • I thought \Bigr is of type \mathclose and not \mathrel? :-o
    – nagmat84
    Commented Feb 21, 2020 at 18:58
  • @nagmat84 \let\foo=\big \def\big{\mathbin\foo} should work Commented Feb 21, 2020 at 18:58
  • @nagmat84 Bigr -> Bigm fixed :-) Commented Feb 21, 2020 at 18:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .