3

This:

 \left\{
  \begin{array}{l}
   \frac{da}{dt}=\sum\limits_kJ_k\sin(D_{ok})\\
   \frac d{dt}\left\{\begin{array}{c}e\\i\end{array}\right\}=A+\sum\limits_kJ_k\sin(D_{ok})\\
   \frac d{dt}\left\{\begin{array}{c}\epsilon\\\Pi\\\Omega\end{array}\right\}=\underbrace{B-\sum\limits_kK_k\cos(D_{ok})}_{\mbox{functions }F\mbox{ from (2)}}
  \end{array}
 \right.

looks like this:

enter image description here

but I want it looking like this:

enter image description here

  • Do you have the images mixed up? – Werner Mar 26 '14 at 17:02
  • No, they're ok. – xkasienka Mar 26 '14 at 18:00
  • Strange, since neither of the answers provide the output you "want", yet you've accepted one...? – Werner Mar 26 '14 at 18:07
  • I just want the biggest brace no to contain the horizontal one. Is my english so bad? I can't see what I wrote wrong... – xkasienka Mar 26 '14 at 18:12
  • The important part is that you received an answer that satisfied your request. – Werner Mar 26 '14 at 18:31
3

Using a simple \smash won't do, because the spacing below the display would be wrong.

I'll exploit the fact that the material to be underbraced is small in height with respect to the line it belongs to.

\documentclass{article}
\usepackage{mathtools}
\usepackage{lipsum} % just for the example

\newcommand{\smashlastub}[1]{%
  \sbox0{\let\smash\relax$#1$}
  \vphantom{\usebox0}
  \sbox2{$#1$}
  \raisebox{\dimexpr(\ht0-\ht2)}{\usebox2}
}

\begin{document}
\lipsum*[2]
\[
\smashlastub{
 \begin{dcases}
 \frac{da}{dt}=\sum\limits_kJ_k\sin(D_{ok})\\
 \frac{d}{dt}\begin{Bmatrix}e\\i\end{Bmatrix}=A+\sum\limits_kJ_k\sin(D_{ok})\\
 \frac{d}{dt}\begin{Bmatrix}\epsilon\\\Pi\\\Omega\end{Bmatrix}=
   \smash{\underbrace{B-\sum_{k}K_k\cos(D_{ok})}_{\text{functions $F$ from (2)}}}
 \end{dcases}}
\]
\lipsum[3]
\end{document}

So the whole display is typeset twice, one without smashing the underbrace, one smashing it. The difference in height is taken into account for raising the second box.

enter image description here

Note how using amsmath and mathtools environments improves the overall appearance.

  • It looks fantastic :) – xkasienka Mar 26 '14 at 17:21
  • Ok, in my document it isn't so fantastic. I don't what I've done wrog, but now all \underbrace and \overbrace are looking like this: link – xkasienka Mar 26 '14 at 17:54
  • @xkasienka That's really strange. Are you perhaps using unicode-math? – egreg Mar 26 '14 at 18:11
  • I think I'm not, because I don't even know what it is. – xkasienka Mar 26 '14 at 18:16
  • @xkasienka If this happened after adding mathtools some more information is needed; please, try making a minimal example and open a new question with it. – egreg Mar 26 '14 at 18:19
5

\smash is your friend:

output of example code

\documentclass{article}
\begin{document}
\[
\left\{
  \begin{array}{l}
   \frac{da}{dt}=\sum\limits_kJ_k\sin(D_{ok})\\
   \frac d{dt}\left\{\begin{array}{c}e\\i\end{array}\right\}=A+\sum\limits_kJ_k\sin(D_{ok})\\
   \frac d{dt}\left\{\begin{array}{c}\epsilon\\\Pi\\
   \Omega\end{array}\right\}=
   \smash{\underbrace{B-\sum\limits_kK_k\cos(D_{ok})}_{\mbox{functions }F\mbox{ from (2)}}}
  \end{array}
 \right.
\]
\end{document}

i didn't move the brace lower, since it seems to apply to only the last expression.

  • ...nor did you use amsmath! :) – Werner Mar 26 '14 at 17:05
  • But now the text under this equation overlaps 'functions F from (2)' I can put empty line beneath and its ok :) – xkasienka Mar 26 '14 at 17:14

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.