LaTeX forum ⇒ Math & Sciencemulti-line underset text

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
whoburg
Posts: 6
Joined: Mon Nov 29, 2010 11:03 pm

multi-line underset text

Postby whoburg » Mon Apr 04, 2011 7:43 pm

Hi All,
I am undersetting some text under an equation, and I would like that text to span multiple lines. Here is my specific example:

  1. \begin{equation}
  2. \label{CD}
  3. C_D \geq \underbrace{\frac{C_L^2}{\pi e AR}}_{\textrm{induced drag}} + \underbrace{c_d(C_L, Re, \tau)}_{\textrm{wing profile drag}} + \underbrace{\frac{CDA_0}{S}}_{\textrm{non-wing form drag}}
  4. \end{equation}


I would like the text 'non-wing form drag' to be split into two lines, so that it fits under that term in the equation better. I have tried adding a \newline and adding a \\ between 'wing' and 'form', to no avail.

Thank you for any ideas!
Last edited by whoburg on Mon Apr 04, 2011 9:39 pm, edited 1 time in total.

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Mon Apr 04, 2011 8:09 pm

You can put the concerned text into a \parbox of a certain width to enable automatic line break.


Thorsten
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

whoburg
Posts: 6
Joined: Mon Nov 29, 2010 11:03 pm

Postby whoburg » Mon Apr 04, 2011 8:35 pm

That successfully created the line break; thanks very much for the advice! I do have a follow on question though. The vertical spacing between lines is quite large. Is there any way to decrease that within the parbox?

\begin{equation}
\label{CD}
C_D \geq \underbrace{\frac{C_L^2}{\pi e AR}}_{\textrm{induced drag}} + \underbrace{c_d(C_L, Re, \tau)}_{\textrm{\parbox{.8in}{\vspace{4pt} wing profile drag}}} + \underbrace{\frac{CDA_0}{S}}_{\textrm{\parbox{.47in}{non-wing form drag}}}
\end{equation}

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Mon Apr 04, 2011 8:49 pm

The interline spacing inside the \parbox is determined by the default font size. You can try another approach to balance that.
  1. \begin{equation}\label{CD}
  2. C_D \geq \underbrace{\frac{C_L^2}{\pi e AR}}_{\textrm{induced drag}} + \underbrace{c_d(C_L, Re, \tau)}_{\textrm{\parbox{.8in}{\vspace{4pt} wing profile drag}}} + \underbrace{\frac{CDA_0}{S}}_{\textrm{\shortstack{non-wing\\[-1ex] form drag}}}
  3. \end{equation}
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

whoburg
Posts: 6
Joined: Mon Nov 29, 2010 11:03 pm

Postby whoburg » Mon Apr 04, 2011 9:38 pm

That is perfect. Thank you so much for your help.


Return to “Math & Science”

Who is online

Users browsing this forum: No registered users and 1 guest