5

I'm having a bit too much horizontal space in this MWE, and want a normal spacing:

\documentclass[11pt,letterpaper,twoside]{book}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{mathtools}

\begin{document}

\begin{subequations}
\begin{alignat}{2}
    \phi \quad &\Rightarrow \quad \tilde{\phi} &&= e^{-\, i q \vartheta} \, \phi, \\[1ex]
    A_{\mu} \quad &\Rightarrow \quad \tilde{A}_{\mu} &&= A_{\mu} + \partial_{\mu} \, \vartheta,
\end{alignat}
\end{subequations}

\end{document}

Here's a preview of the problem, shown in red:

enter image description here

I need the arrows and the equal signs to be aligned, and I want the same normal space on each sides of these symbols. Currently, there's too much space after the \phi symbol. How can I fix that without hacking (i.e. without adding phantom tricks)?

2 Answers 2

4

You can move the &'s.

\documentclass[11pt,letterpaper,twoside]{book}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{mathtools}

\begin{document}

\begin{subequations}
\begin{alignat}{2}
    \phi    \quad & \Rightarrow \quad & \tilde{\phi}    & = e^{-\, i q \vartheta} \, \phi, \\[1ex]
    A_{\mu} \quad & \Rightarrow \quad & \tilde{A}_{\mu} & = A_{\mu} + \partial_{\mu} \, \vartheta,
\end{alignat}
\end{subequations}

\end{document}

1
  • Ow! That was easy! I didn't knew that we could move the & around like this. Thanks!
    – Cham
    Mar 20, 2020 at 15:22
4

Move one of alignment signs & in front of the \phi and A.

\documentclass[11pt,letterpaper,twoside]{book}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{mathtools}

\begin{document}

\begin{subequations}
\begin{alignat}{2}
    \phi \quad &\Rightarrow \quad &\tilde{\phi} &= e^{-\, i q \vartheta} \, \phi, \\[1ex]
    A_{\mu} \quad &\Rightarrow \quad &\tilde{A}_{\mu} &= A_{\mu} + \partial_{\mu} \, \vartheta,
\end{alignat}
\end{subequations}

\end{document}
1
  • That was very easy. Thanks a lot!
    – Cham
    Mar 20, 2020 at 15:22

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.