7

I am looking for a 'double' brace symbol (aka Blackboard or Doublestroke) like this - but for curly braces instead of square brackets.

The symbol is used to denote the average in discontinuous Galerkin methods.

(I have tried de-texify and can't identify it)

It should look similar to:

$$\{\hspace{-4.9pt}\{ u_x \}\hspace{-5pt}\}$$
  • 1
    Could this be of interest? – d125q Jun 28 '15 at 11:48
  • 1
    Could you give an example how exactly the symbol should look like? – phx Jun 28 '15 at 11:48
  • There's no such predefined symbols, as far as I know. Do you need it scalable around the subformula in between the two symbols? – egreg Jun 28 '15 at 12:11
7

My eyes bleed, but here it is:

\documentclass{article}
\usepackage{xparse}

\NewDocumentCommand{\dgal}{sO{}m}{%
  \IfBooleanTF{#1}
    {\dgalext{#3}}
    {\dgalx[#2]{#3}}%
}

\NewDocumentCommand{\dgalext}{m}{%
  \sbox0{%
    \mathsurround=0pt % just for safety
    $\left\{\vphantom{#1}\right.\kern-\nulldelimiterspace$%
  }%
  \sbox2{\{}%
  \ifdim\ht0=\ht2
    \{\kern-.625\wd2 \{#1\}\kern-.625\wd2 \}%
  \else
    \left\{\kern-.7\wd0\left\{#1\right\}\kern-.7\wd0\right\}%
  \fi
}

\NewDocumentCommand{\dgalx}{om}{%
  \sbox0{\mathsurround=0pt$#1\{$}%
  \sbox2{\{}%
  \ifdim\ht0=\ht2
    \{\kern-.625\wd2 \{#2\}\kern-.625\wd2 \}%
  \else
    \mathopen{#1\{\kern-.7\wd0 #1\{}
    #2
    \mathclose{#1\}\kern-.7\wd0 #1\}}
  \fi
}


\begin{document}

\def\test#1{#1|xxx}

$\dgal*{\test{}}$
$\dgal*{\test{\big}}$
$\dgal*{\test{\Big}}$
$\dgal*{\test{\bigg}}$
$\dgal*{\test{\Bigg}}$

$\dgal{xxx}$
$\dgal[\big]{xxx}$
$\dgal[\Big]{xxx}$
$\dgal[\bigg]{xxx}$
$\dgal[\Bigg]{xxx}$

\end{document}

enter image description here

If I change .625 into .45 and .7 into .5, the result seems better:

\documentclass{article}
\usepackage{xparse}

\NewDocumentCommand{\dgal}{sO{}m}{%
  \IfBooleanTF{#1}
    {\dgalext{#3}}
    {\dgalx[#2]{#3}}%
}

\NewDocumentCommand{\dgalext}{m}{%
  \sbox0{%
    \mathsurround=0pt % just for safety
    $\left\{\vphantom{#1}\right.\kern-\nulldelimiterspace$%
  }%
  \sbox2{\{}%
  \ifdim\ht0=\ht2
    \{\kern-.45\wd2 \{#1\}\kern-.45\wd2 \}%
  \else
    \left\{\kern-.5\wd0\left\{#1\right\}\kern-.5\wd0\right\}%
  \fi
}

\NewDocumentCommand{\dgalx}{om}{%
  \sbox0{\mathsurround=0pt$#1\{$}%
  \sbox2{\{}%
  \ifdim\ht0=\ht2
    \{\kern-.45\wd2 \{#2\}\kern-.45\wd2 \}%
  \else
    \mathopen{#1\{\kern-.5\wd0 #1\{}
    #2
    \mathclose{#1\}\kern-.5\wd0 #1\}}
  \fi
}


\begin{document}

\def\test#1{#1|xxx}

$\dgal*{\test{}}$
$\dgal*{\test{\big}}$
$\dgal*{\test{\Big}}$
$\dgal*{\test{\bigg}}$
$\dgal*{\test{\Bigg}}$

$\dgal{xxx}$
$\dgal[\big]{xxx}$
$\dgal[\Big]{xxx}$
$\dgal[\bigg]{xxx}$
$\dgal[\Bigg]{xxx}$

\end{document}

enter image description here

  • Thanks! I will use this option, I just hope that the journal will accept it for printing. – GCon Jun 28 '15 at 14:16
6

this is U+2983 U+2984 and \lBrace, \rBrace in stix or unicode-math packages

enter image description here

\documentclass{article}
\usepackage{stix}

\begin{document}

\[\lBrace zzz \rBrace\]

\end{document}
  • Very fast indeed, but no dice, I already saw that question. I am looking for a double brace, as in two braces. – GCon Jun 28 '15 at 12:01
  • @GCon It wasn't clear from the original description:-) I think that is the nearest there is in Unicode. Just use \{\!\{ ? – David Carlisle Jun 28 '15 at 12:11

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.