A more beautiful output of \under- and \overbrace
I would like to suggest you load the mathtools
package and use its \mathclap
macro to "smash" the widths of the explanatory strings "\text{Menge aller $x$ aus $\mathbb{Z}$}
" and "\text{mit der Eigenschaft}
". I would use an \overset
directive instead of \overbrace
to typeset the (stacked) material above the vertical bar. (An overbrace is just too wide relative to the vertical bar.)
With this approach, the explanatory strings will be typeset in \scriptstyle
, i.e., with a font that's 30% smaller than the main math font style (which is \textstyle
).
Separately, do note that the vertical bar should be of type mathrel
. If it's written as \vert
or as |
, it should be surrounded by thickspaces (\;
). Or, more simply, just write \mid
.
\documentclass{article}
\usepackage{mathtools} % for \mathclap macro
\usepackage{amsfonts} % for \mathbb macro
\begin{document}
\[ \{\,
\underbrace{x \in \mathbb{Z}}_{%
\mathclap{\text{Menge aller $x$ aus $\mathbb{Z}$}}}
\overset{\mathclap{\substack{%
\text{mit der Eigenschaft}\\ \downarrow}}}{\mid}
-1 \le x \le 2 % wrap the minus symbol in braces so that it acts as a unary operator
\,\} \]
\end{document}
Here is a solution with mathtools
(an extension of amsmath
) and stackengine
. For short underbraces, \underbracket
looks nicer:
\documentclass{article}
\usepackage{mathtools, stackengine}
\usepackage{amsfonts}
\setstackEOL{\\}
\begin{document}
\begin{picture}(300,20)
\put(50,10){\vector(2,-3){20}}
\put(50,10){\vector(2,-1){60}}
\put(-10,15){these guys \textbf{here} must be eliminated. The next one \textbf{here} too, of course.}
\put(230,10){\vector(-2,-3){20}}
\end{picture}
\[ \bigl\{ \underbracket[0.5pt]{x \in \mathbb{Z}}_{\clap{\footnotesize Menge aller $x$ aus $\mathbb{Z}$}} \stackrel{\Shortstack {\clap{\footnotesize mit der Eigenschaft}\\$\downarrow $}}{\mid} -1 \le x \le 2\bigr\} \]
\\[1cm]
And I want to get it like this:
\[ \{x \in \mathbb{Z} \ | \ -1 \le x \le 2 \}, \]
where the \verb|\overbrace| doesn't wait till the \verb|\underbrace| is going to have the work done.
\end{document}