\:$m_0\=m$.
\:While $n>1$: \cmt{We will call iterations of this loop \df{phases}.}
\::$F\=\emptyset$. \cmt{forest built in the current phase}
-\::$t\=2^{2m_0/n}$. \cmt{the limit on the heap size}
+\::$t\=2^{2m_0/n}$. \cmt{the limit on heap size}
\::While there is a~vertex $v_0\not\in F$:
\:::Run the improved Jarn\'\i{}k's algorithm (\ref{jarniktwo}) from~$v_0$, stop when:
\::::all vertices have been processed, or
However the choice of the parameter~$t$ can seem mysterious, the following
lemma makes the reason clear:
-\lemma
-The $i$-th phase of the Iterated Jarn\'\i{}k's algorithm runs in time~$\O(m_i)$.
+\lemma\id{ijphase}%
+The $i$-th phase of the Iterated Jarn\'\i{}k's algorithm runs in time~$\O(m)$.
\proof
During the phase, the heap always contains at most~$t_i$ elements, so it takes
time~$\O(\log t_i)=\O(m/n_i)$ to delete an~element from the heap. The trees~$R_i^j$
are disjoint, so there are at most~$n_i$ \<DeleteMin>'s over the course of the phase.
Each edge is considered at most twice (once per its endpoint), so the number
-of the other heap operations is~$\O(m_i)$. Together, it equals $\O(m_i + n_i\log t_i) = \O(m_i)$.
+of the other heap operations is~$\O(m_i)$. Together, it equals $\O(m_i + n_i\log t_i) = \O(m_i+m) = \O(m)$.
\qed
\lemma
Unless the $i$-th phase is final, the forest~$F_i$ consists of at most $2m_i/t_i$ trees.
\proof
-As every edge of~$G_i$ is incident with at most two such trees, it is sufficient
+As every edge of~$G_i$ is incident with at most two trees of~$F_i$, it is sufficient
to establish that there are at least~$t_i$ edges incident with the vertices of every
such tree~(*).
-The forest~$F_i$ evolves by additions of the trees~$R_i^j$. There are three possibilities
+The forest~$F_i$ evolves by additions of the trees~$R_i^j$. Let us consider the possibilities
how the algorithm could have stopped growing the tree~$R_i^j$:
\itemize\ibull
\:the heap had more than~$t_i$ elements (step~10): since the elements stored in the heap correspond
instead of edges incident with the tree itself, because we needed the tree edges
to be counted as well.}
\:all vertices have been processed (step~8): this can happen only in the final phase.
+\qeditem
\endlist
-\>In all three cases, there are sufficiently many incident edges.
-\qed
\thm\id{itjarthm}%
The Iterated Jarn\'\i{}k's algorithm finds the MST of the input graph in time
2m_i/t_i$. Then $t_{i+1} = 2^{2m/n_{i+1}} \ge 2^{2m/(2m_i/t_i)} = 2^{(m/m_i)\cdot t_i} \ge 2^{t_i}$,
therefore:
$$
-t_i \ge 2^{2^{2^{\vdots^{m/n}}}}
+\left. \vcenter{\hbox{$\displaystyle t_i \ge 2^{2^{\scriptstyle 2^{\scriptstyle\vdots^{\scriptstyle m/n}}}} $}}\;\right\}
+\,\hbox{a~tower of~$i$ exponentials.}
$$
-and as soon as~$t_i\ge n$, the $i$-th phase must be final, because at that time
-there is enough space in the heap to process the whole graph.
+As soon as~$t_i\ge n$, the $i$-th phase must be final, because at that time
+there is enough space in the heap to process the whole graph. So~there are
+at most~$\beta(m,n)$ phases and we already know (Lemma~\ref{ijphase}) that each
+phase runs in linear time.
\qed
-\FIXME{The notation is clumsy and so is the proof, at least typographically.}
-
\cor
The Iterated Jarn\'\i{}k's algorithm runs in time $\O(m\log^* n)$.
+
% use \para
% G has to be connected, so m=O(n)
% mention Steiner trees