5

I am introducing a formula in my paper and would like to have two \underbraces below two parts of the formula. Now it looks kind of odd, as the second \underbrace is way higher than the first. Do you have any ideas ho to fix it without needing to eliminate the fraction?

I print my code below:

\begin{equation}\label{eq:underbrace}
            x_{t} = \underbrace{\beta_{0} + \beta_{1} t + \gamma_{1} \cos(t * \frac{2\pi}{365})   +  \delta_{1} d_{t}}_{s_{t}}  + \underbrace{\epsilon_{t}}_{y_{t}}
\end{equation}
7

You can use \vphantoms to achieve similar heights for constructions:

enter image description here

\documentclass{article}

\begin{document}

\[
  x_t = \underbrace{
    \beta_0 + \beta_1 t + \gamma_1 \cos(t \times \frac{2\pi}{365}) + \delta_1 d_t
  }_{s_t} + 
  \underbrace{\epsilon_t \vphantom{\frac{2\pi}{365}}}_{y_t}
\]

\end{document}

I'd probably be inclined to drop the use of such a large (display) \frac and instead use:

enter image description here

\documentclass{article}

\begin{document}

\[
  x_t = \underbrace{
    \beta_0 + \beta_1 t + \gamma_1 \cos(2 \pi t / 365) + \delta_1 d_t
  }_{s_t} + 
  \underbrace{\epsilon_t \mathstrut}_{y_t}
\]

\end{document}
| improve this answer | |

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.