# Proof Split Over Two Pages

I have a proof that should take up only just over half a page; however, when I compile it, only the first few sentences appear in the bottom half of the page where my proof starts, and the rest is moved to the next page. I rather would want text to only appear on the next page after the available white space has been used (as is usually the case).

Here is the proof:

\documentclass{article}
\usepackage{amsthm}
\usepackage{amsmath}
\usepackage{lipsum}
\begin{document}

\lipsum[1-3]
\begin{enumerate}
\item Show Rank($A$) = Rank($B$), for $A = {^S}B$.
\begin{proof}
For $S^{-1}AS$ to be defined, $A$ must be $n \times n$ for S $n \times n$, and as $S^{-1}AS = B$, $B$ is also $n \times n$. By the Rank-Nullity theorem, Rank($A$) = n $-$ Null($A$). Hence, it suffices to show Null($A$) = Null($B$), as both $A$ and $B$ have $n$ columns.
\begin{align*}
\mathbf{0} & = B\mathbf{x} = S^{-1}AS\mathbf{x},\ \mathbf{x} \in \mathrm{Ker}(B) \\
& = SS^{-1}AS\mathbf{x},\ \text{as}\ S\mathbf{0} = \mathbf{0} \\
& = I_{n \times n}AS\mathbf{x} \\
& = AS\mathbf{x} \\
& \Rightarrow S\mathbf{x} \in \mathrm{Ker}(A) \tag{71.a.1} \\
\mathbf{0} & = A\mathbf{x} = SBS^{-1}\mathbf{x},\ \mathbf{x} \in \mathrm{Ker}(A) \\
& = S^{-1}SBS^{-1}\mathbf{x},\ \text{as}\ S^{-1}\mathbf{0} = \mathbf{0} \\
& = I_{n \times n}BS^{-1}\mathbf{x} \\
& = BS^{-1}\mathbf{x} \\
& \Rightarrow S^{-1}\mathbf{x} \in \mathrm{Ker}(B) \tag{71.a.2} \\
\mathbf{0} & = c_1\mathbf{v_1} + \dotsb + c_p\mathbf{v_p} \Rightarrow c_i = 0\ \text{for}\ \bigl\{v_i \vert i \in \{1,\dotsc,p\}\bigr\}\ \text{a basis of $B$} \\
& = c_1S\mathbf{v_1} + \dotsb + c_nS\mathbf{v_p},\ \text{as $S$ is linear} \\
& \Rightarrow S\mathbf{v_i}\ \text{are linearly independent} \bigl(\text{in}\ \mathrm{Ker}(A)\ \text{by (71.a.1)}\bigr),\ \text{as $c_i$ are unchanged and all zero} \\
& \Rightarrow \mathrm{dim}\bigl(\mathrm{Ker}(A)\bigr) \geq \mathrm{dim}\bigl(\mathrm{Ker}(B)\bigr) = p \tag{71.b.1} \\
\mathbf{0} & = c_1\mathbf{w_1} + \dotsb + c_q\mathbf{w_q} \Rightarrow c_i = 0\ \text{for}\ \bigl\{w_i \vert i \in \{1,\dotsc,q\}\bigr\}\ \text{a basis of $A$} \\
& = c_1S^{-1}\mathbf{w_1} + \dotsb + c_qS^{-1}\mathbf{w_q},\ \text{as $S^{-1}$ is linear} \\
& \Rightarrow S^{-1}\mathbf{w_i}\ \text{are linearly independent}\ \bigl(\text{in}\ \mathrm{Ker}(B)\ \text{by (71.a.2)}\bigr),\ \text{as $c_i$ are unchanged and all zero} \\
& \Rightarrow \mathrm{dim}\bigl(\mathrm{Ker}(B)\bigr) \geq \mathrm{dim}\bigl(\mathrm{Ker}(A)\bigr) = q \tag{71.b.2}
\end{align*}
Combining (71.b.1) and (71.b.2), as $p \geq q$ and $q \geq p$, by the antisymmetric property of the order relation, $p = q$, and Nul($A$) = Nul($B$).
\end{proof}
\end{enumerate}
\end{document}


This is being used within an enumerate environment with many other questions, though I checked, and the problem still persists even without the enumerate environment.

Thanks for any suggestions anyone can provide.

My full code (using the afterpage package suggested here) is here: http://pastebin.com/HZhB5x4i

-
Without a full compilable example it's hard to tell, but I guess your alignment is so huge that it doesn't fit onto the first page. – Hendrik Vogt Mar 3 '11 at 14:16
@Sara: It's recommended to post a minimal example that illustrates your problem. However, I compiled your code and didn't see any problems in the output! – Hendrik Vogt Mar 3 '11 at 15:04
@Hendrik I probably could make my example more minimal, but I've at least removed a section of text that didn't pertain to the issue at hand. Hope that helps. You didn't see the proof I mentioned being labeled by a letter instead of a separate number? – Sara Fauzia Mar 3 '11 at 15:15
@Sara: I think you just shouldn't use \afterpage and have a look at Herbert's answer. – Hendrik Vogt Mar 3 '11 at 15:19
As a side note, you might consider using \DeclareMathOperator\Rank{Rank} \DeclareMathOperator\Ker{Ker} and then use \Rank and \Ker and similarly for \Null (and any other operators I might have missed). \dim already exists. That first line should probably be Show $\Rank(A) = \Rank(B)$, for $A = {^S}B$. – TH. Mar 3 '11 at 17:28

Write into the preamble after laoding amsmath
\allowdisplaybreaks