7

I'm trying to accomplish something like this: enter image description here

I went through the comprehensive latex symbol list and didn't manage to find a symbol that looks suitably like this.

Notice the symbol is basically a normal paren symbol cut in half:

enter image description here

where the bit in red is the segment of the symbol I want. The first picture posted was done in word (unicode apparently allows you to insert these sorts of paren segments).. Haven't figured out how to do this in Latex yet though..

Is there some way (package, etc) to accomplish this?

6

One option

enter image description here

\documentclass{scrartcl}

\usepackage{mathtools,amssymb}
\usepackage{scalerel,adjustbox}

\newcommand*\lpasymbolaux[1]{\adjustbox{clip,trim=0pt 0pt 0pt {.45\totalheight}}{\ensuremath{#1(}}}
\newcommand*\rpasymbolaux[1]{\adjustbox{clip,trim=0pt 0pt 0pt {.45\totalheight}}{\ensuremath{#1)}}}
\newcommand\lpa[1][]{\mathopen{\stretchrel*{\lpasymbolaux{#1}}{#1(}}}
\newcommand\rpa[1][]{\mathclose{\stretchrel*{\rpasymbolaux{#1}}{#1(}}}

\begin{document}

$\lpa a,b\rpa$

\end{document}

You can also use the optional argument to declare the size: \[ \lpa[\bigg]\frac{a}{b}\rpa[\bigg] \]. Of couse, you could and should define a semantic command for, probably, the pair of them, like \abs{x} instead of |x|, well \whatever{a,b} and \whatever[\bigg]{a,b} rather than \lpa a,b\rpa.

  • Very nice. You may consider adding the optional argument of \stretchrel* to limit the aspect ratio, e.g., \stretchrel*[100]{}{} – Steven B. Segletes Sep 15 '16 at 0:54
  • 1
    You might also add/demonstrate that it immediately works as well in \scriptstyle and \scriptscriptstyle. – Steven B. Segletes Sep 15 '16 at 2:04
4

With LuaLaTeX (not XeLaTeX, where the closing symbol is misplaced):

\documentclass{article}
\usepackage{unicode-math}
\setmainfont{XITS}
\setmathfont{XITS Math}

\newcommand{\llp}{\mathopen{\mathpalette\xcen\lparenlend}}
\newcommand{\rlp}{\mathclose{\mathpalette\xcen\rparenlend}}
\newcommand{\xcen}[2]{\vcenter{\hbox{$#1#2$}}}

\begin{document}

$\llp a,b\rlp$

\end{document}

enter image description here

With pdflatex

\documentclass{article}
\usepackage{amsmath}

\DeclareMathSymbol{\xllp}{\mathord}{largesymbols}{`@}
\DeclareMathSymbol{\xrlp}{\mathord}{largesymbols}{`A}
\newcommand{\llp}{\mathopen{\mathpalette\xcen\xllp}}
\newcommand{\rlp}{\mathclose{\mathpalette\xcen\xrlp}}
\newcommand{\xcen}[2]{%
  \vcenter{\hbox{$
    \ifx#1\displaystyle\scriptstyle\else
      \ifx#1\textstyle\scriptstyle\else
        \ifx#1\scriptstyle\scriptscriptstyle\else
          \scriptscriptstyle
        \fi
      \fi
    \fi
    #2
  $}}%
}

\begin{document}

$\llp a,b\rlp_{\llp a,b\rlp}$

\end{document}

enter image description here

3

The symbols are there really to make up large brackets, you can access them but as the smaller size brackets have complete gyphs the partial symbols are quite large, depending on your use case you could scale them and/or raise them a bit more

enter image description here

\documentclass{article}
\usepackage{exscale}

\DeclareMathSymbol{\zl}{\mathopen}{largesymbols}{`@}
\DeclareMathSymbol{\zr}{\mathclose}{largesymbols}{`A}
\begin{document}

$\zl\textstyle a,b\zr$

$\scriptscriptstyle\zl\textstyle a,b\scriptscriptstyle\zr$



\end{document}
  • I'd see well some \vcenter here. – egreg Sep 14 '16 at 21:33
  • @egreg perhaps or maybe raise by hand to optically centre or .... – David Carlisle Sep 15 '16 at 0:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.