chiark / gitweb /
strategy: reachable is going well
[topbloke-formulae.git] / trav-proofs.tex
index 981483e1c92c77f7c9d94811efe23b87e4e3ff58..421bb61c296fb8979b9d0744f067921eed0c0e0d 100644 (file)
@@ -3,7 +3,45 @@
 For each operation called for by the traversal algorithms, we prove
 that the commit generation preconditions are met.
 
-WIP WHAT ABOUT PROVING ALL THE TRAVERSAL RESULTS
+\subsection{Reachability and coverage}
+
+We ensure Tip Covers Reachable as follows:
+
+\begin{itemize}
+\item  We do not generate any commits $\in \py$ other than
+       during $\alg{Merge-Tip}(\py)$;
+\item  So at the start of $\alg{Merge-Tip}(\py)$,
+       $ \pendsof{\allreach}{\py} = \pendsof{\allsrcs}{\py} $
+\item  $\alg{Merge-tip}$ arranges that when it is done
+       $\tippy \ge \pendsof{\allreach}{\py}$ --- see below.
+\end{itemize}
+
+A corrolary is as follows:
+\statement{Tip Covers Superior Reachable} {
+  \bigforall_{\pd \isdep \pc}
+    \tipdy \ge \pendsof{\allreachof{\pcy}}{\pdy}
+}
+\proof{
+  No commits $\in \pdy$ are created other than during
+  $\alg{Merge-Tip}(\pd)$, which runs (and has thus completed)
+  before $\alg{Merge-Tip}(\pcy)$
+  So $\pendsof{\allreachof{\pcy}}{\pdy} =
+      \pendsof{\allreachof{\pdy}}{\pdy}$.
+}
+
+\subsection{Traversal Lemmas}
+
+\statement{Tip Correct Contents}{
+  \tipcy \haspatch \pa E
+    \equiv
+  \pa E = \pc \lor \pa E \isdep \pc
+}
+\proof{
+  For $\pc = \pa E$, Tip Own Contents suffices.
+  For $\pc \neq \pa E$, Exclusive Tip Contents
+  gives $D \isin \tipcy \equiv D \isin \baseof{\tipcy}$
+  which by Correct Base $\equiv D \isin \tipcn$.
+}
 
 \subsection{Base Dependency Merge, Base Sibling Merge}
 
@@ -17,8 +55,28 @@ WIP WHAT ABOUT PROVING ALL THE TRAVERSAL RESULTS
 
 \subsection{Recreate Base Beginning}
 
-WHAT IF $\pendsof{L}{\pqy} \neq \{\}$ ?
-FIX BY CHANGE PRECOND OF CREATE BASE
+To recap we are executing Create Base with
+$L = \tipdy$ and $\pq = \pc$.
+
+\subsubsection{Create Acyclic}
+
+By Tip Correct Contents of $L$,
+$L \haspatch \pa E \equiv \pa E = \pd \lor \pa E \isdep \pd$.
+Now $\pd \isdirdep \pc$,
+so by Coherence, and setting $\pa E = \pc$,
+$L \nothaspatch \pc$. I.e. $L \nothaspatch \pq$. OK.
+
+That's everything for Create Base.  $\qed$
+
+\subsection{Recreate Base Final Declaration}
+
+\subsubsection{Base Only} $\patchof{W} = \patchof{L} = \pn$.  OK.
+
+\subsubsection{Unique Tips}
+
+Want to prove that for any $\p \isin C$, $\tipdy$ is a suitable $T$.
+
+WIP
 
 \subsection{Tip Base Merge}