13

What is a simple way to have \ll on top of \gg with equal size and vertically center aligned and have them work as a binary relation symbol like \lessgtr? The commands \underset and \overset cannot be used because they do not treat the two symbols equally, and they do not vertically center.

yo'
  • 51,322
sawa
  • 357

4 Answers4

14

You can try substack

\documentclass{article}

\usepackage{amsmath, amssymb}
\begin{document}

\newcommand{\ggll}{\mathrel{\substack{\ll\\[-.05em]\gg}}}

$x\ggll x$

$x\substack{\ll\\\gg}x$

\end{document}

I added amsmath for \lessgtr but it also needed for substack. You may read more about this command in the amsmath documentation or in the mathmode paper. As @tohecz pointed out, one may need some spacing correction by mathrel. Furthermore i added a vertical correction with the optional argument of \\. This makes the symbol a little bit more like belonging together (and might be a thing of personal taste too).

l#1: with corrections; l#2: without

bloodworks
  • 10,178
10

I doubt that you really want such an ugly symbol, but here are two proposals:

\documentclass{article}
\usepackage{amssymb}
\newcommand{\llgg}{\mathrel{\mathpalette\llggi\relax}}
\newcommand{\llggi}[2]{\vcenter{\offinterlineskip\hbox{$#1\ll$}\hbox{$#1\gg$}}}

\newcommand{\sllgg}{\mathrel{\mathpalette\sllggi\relax}}
\newcommand{\sllggi}[2]{\vcenter{\offinterlineskip\hbox{$\mkern2mu#1\ll$}\hbox{$#1\gg\mkern2mu$}}}

\begin{document}
$a\llgg b \lessgtr c_{\llgg}$

$a\sllgg b \lessgtr c_{\sllgg}$
\end{document}

enter image description here

One might add some vertical space in the first version, but I'd prefer the second one, in which I add instead a little horizontal shift.

egreg
  • 1,121,712
  • Thank you! Your answer has helped me to concoct a \preceqq sign without loading extra fonts packages! I ended up doing

    \newcommand{\preceqq}{\mathrel{\mathpalette\preceqqi\relax}}

    \newcommand{\preceqqi}[2]{\vcenter{\offinterlineskip\lineskip1pt\hbox{$#1\prec$}\hbox{$#1=$}}}

    – mathreader Aug 14 '17 at 23:03
7

I would suggest putting two \lessgtr in a roll, with a good space inbetween so that the lines join each other nicely:

enter image description here

\documentclass{article}

\usepackage{amsmath, amssymb}
\newcommand\llgg{\lessgtr\mkern-5.7mu\lessgtr}

\begin{document}
$a\llgg b$

$f_{a\llgg b}$

$g_{h_{a\llgg b}}$
\end{document}
yo'
  • 51,322
2

I use stackrel or stackbin commands.

\documentclass{article}

\usepackage{amsmath, amssymb,stackrel}

\begin{document}

$$ A\stackbin[\text{and}]{}{+} B \stackrel[x]{!}{=} C$$

$$ A\stackbin{\ll}{\gg} B $$

\end{document}

You can find useful the following post

Cheers.

Dox
  • 5,729
  • 2
    Have you tried to compile the code? It doesn't really look like one complicated relational symbol. The upper part is smaller. – yo' Jan 04 '13 at 12:10