0

I want the \Leftrightarrow to be directely above the \kappa from the last line. If this is not possible i would be ok if one can put the \Leftrightarrow directely above the equals sign (from the last line).

\documentclass[]{article}
\usepackage{amsmath}
\begin{document}

\begin{alignat*}{3}
\hat \pi_t & = \kappa \Tilde{y_t} + \beta E_t[\hat \pi_{t+1}] \quad &\Leftrightarrow \qquad \qquad \gamma_\pi a_t &= \kappa \gamma_y a_t + \beta \gamma_\pi a_{t+1} \\
\gamma_\pi a_t &= \kappa \gamma_y a_t + \beta \gamma_\pi \rho_a a_t   \quad &\Leftrightarrow \quad \gamma_\pi - \beta \gamma_\pi \rho_a &= \kappa \gamma_y \\
&&\gamma_\pi = \frac{\kappa}{(1-\beta \rho_a)} \gamma_y
\end{alignat*}
\end{document}

enter image description here

3
  • Please clarify what "align the last lines kappa (or equals-) sign with the equivalents signs above" means. Right now, the red lines drawn between rows 2 and 3 make it look like the \Leftrightarrow symbol in row 2 is supposed to be aligned simultaneously with = and \kappa in row 3, which cannot be what you're intending.
    – Mico
    Sep 3, 2020 at 18:40
  • @Mico thanks for your help, i tried to specify my question. Sep 3, 2020 at 18:45
  • 1
    I'm not sure that any of the symbols should be aligned, except for the two \Leftrightarrow symbols. The look is very unbalanced and awkward to read. In my opinion, an encompassing gather* with alignedat for the first two rows, using left alignment for the equations and centering the third row, with some vertical space added would be better. Here's a picture (click)
    – egreg
    Sep 3, 2020 at 20:03

1 Answer 1

1

Here is a solution with eqparbox , to have the = of the last equation centred w.r.t. \Leftrightarrow and mathtools:

\documentclass[]{article}
\usepackage{mathtools}
\usepackage{eqparbox}
\newcommand*{\eqmathbox}[2][M]{\eqmakebox[#1]{$\displaystyle#2$}}

\begin{document}

\begin{alignat*}{3}
\hat \pi_t & = \kappa \Tilde{y_t} + \beta E_t[\hat \pi_{t+1}] & &\Leftrightarrow &\gamma_\pi a_t &= \kappa \gamma_y a_t + \beta \gamma_\pi a_{t+1} \\
\gamma_\pi a_t &= \kappa \gamma_y a_t + \beta \gamma_\pi \rho_a a_t & &\eqmathbox{{}\Leftrightarrow{}} &\gamma_\pi - \beta \gamma_\pi \rho_a &= \kappa \gamma_y \\
&& \mathllap{\gamma_\pi} &\eqmathbox{=} \mathrlap{\frac{\kappa}{(1-\beta \rho_a)} \gamma_y}
\end{alignat*}

\end{document} 

enter image description here

3
  • This is going into the right direction. However i want the \gamma a_t in the first line to be right aligned (near to the equal sign on the right) without space. Sep 3, 2020 at 18:35
  • @Armenthus: Please see my edited answer. It was enough to move the last but one & in the first two rows. B.t.w., you should know that 3 alignment columns require 5 &, not 3.
    – Bernard
    Sep 3, 2020 at 18:47
  • Thx i somehow messed up lines and rows :) Sep 3, 2020 at 18:48

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.