Overlapping vertical spacing in math mode
You wrote,
If a better method exists to only get the equation tag on the last line ..., please let me know.
I think you need a combination of an equation
environment, an aligned[b]
environment, and a \smash[t]{...}
directive.
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{equation} \label{eq.14}
\begin{aligned}[b] % 'b' means "place equation number on bottom line"
1 \uparrow 1 &= {}^1 1 = 1 \\
2 \uparrow\uparrow 2 &= {}^2 2 = 4 \\
3 \uparrow\uparrow \uparrow 3 &=
\smash[t]{ {}^{{}^{{}^3\!}} {}^3 3
= 3 \uparrow\uparrow 3 \uparrow\uparrow 3
= \underbrace{3^{3^{3^{3^{3^{3^{.^{.^{.^{3}}}}}}}}}}_{3^{3^3}\text{ threes}}
}
\end{aligned}
\end{equation}
\end{document}
Addendum: Here's an additional solution, which (a) employs an alignedat
environment to perform alignment on both the first and second instance of =
, (b) changes the math status of \uparrow
, \uparrow\uparrow
, and \uparrow\uparrow\uparrow
to math-bin
(the default math status is math-rel
), and (c) implements @egreg's suggestion to provide a bit more distance between the rows and to enlarge the contents of the _{...}
component of the \underbrace
directive in row 3.
\documentclass{article}
\usepackage{mathtools}
\begin{document}
\begin{equation} \label{eq.14}
\addtolength\jot{4pt}
\begin{alignedat}[b]{2} % 'b' means "place equation number on bottom line"
1 \mathbin{\uparrow} 1 &= {}^1 1 &&= 1 \\
2 \mathbin{\uparrow\uparrow} 2 &= {}^2 2 &&= 4 \\
3 \mathbin{\uparrow\uparrow\uparrow} 3 &=
\smash[t]{ {}^{{}^{{}^3\!}} {}^3 3}
&&= \smash[t]{3 \mathbin{\uparrow\uparrow} 3 \mathbin{\uparrow\uparrow} 3
= \underbrace{3^{3^{3^{3^{3^{3^{.^{.^{.^{3}}}}}}}}}}_{\mathclap{\textstyle 3^{3^3}\text{ threes}}}
}
\end{alignedat}
\end{equation}
\end{document}
The main idea is the same as Mico's about smashing the top of the big object, but with some improvements on spacing and size of characters.
\documentclass{article}
\usepackage{amsmath}
\ExplSyntaxOn
\NewDocumentCommand{\hyop}{m}
{
\mathbin{ \prg_replicate:nn { #1 } { \uparrow } }
}
\ExplSyntaxOff
\newcommand{\preexp}[2]{\vphantom{#2}^{#1}\kern-\scriptspace#2}
\begin{document}
\begin{equation} \label{eq.14}
\begin{aligned}[b] % 'b' means "place equation number on bottom line"
1 \hyop{1} 1 &= \preexp{1}{1} = 1 \\
2 \hyop{2} 2 &= \preexp{2}{2} = 4 \vphantom{\preexp{\preexp{3}{3}}{3}}\\
3 \hyop{3} 3 &= \preexp{\preexp{3}{3}}{3}
= 3 \hyop{2} ( 3 \hyop{2} 3 )
= \smash[t]{
\underbrace{
3^{3^{3^{3^{3^{3^{{\cdot}^{{\cdot}^{{\cdot}^{3}}}}}}}}}
}_{\text{$\displaystyle 3^{3^3}$ threes}}
}
\end{aligned}
\end{equation}
\end{document}