0

I am working with an align environment and would like to add some hints at the equality signs by specifying the used equation number at some steps. However, if I do that the equality signs don't align anymore. Is there a way to get the equality signs to align instead of the whole stack relation? See below for a minimal example.

\documentclass{book}

\usepackage{amsmath}

\begin{document}

\chapter{Test align equality}

\begin{equation}\label{eq::ac} a=c \end{equation}

\begin{align} a &= b \ &\stackrel{(\ref{eq::ac})}{=} c \end{align} \end{document}

Mike
  • 149

1 Answers1

2

You can have it using the \mathclap command from mathtools (which loads amsmath), but I propose another solution without \stackrel, which looks better, in my opinion:

\documentclass{book}

\usepackage{mathtools}

\begin{document}

\chapter{Test align equality}

\begin{equation}\label{eq::ac} a=c \end{equation}

\begin{align} a &= b \ &\stackrel{\mathclap{\eqref{eq::ac}}}{=} c \end{align}

\begin{align} a &= b \ &= c\rlap{ \qquad by \eqref{eq::ac}} \end{align}

\end{document}

enter image description here

Bernard
  • 271,350