(* Contribution to the Coq Library   V6.3 (July 1999)                    *)
(****************************************************************************)
(* This contribution was updated for Coq V5.10 by the COQ workgroup.        *)
(* January 1995                                                             *)
(****************************************************************************)
(*                                                                          *)
(*      Coq V5.8                                                            *)
(*                                                                          *)
(*                                                                          *)
(*      Alternating Bit Protocol                                            *)
(*                                                                          *)
(*      Jan Friso Groote                                                    *)
(*      Utrecht University                                                  *)
(*                                                                          *)
(*      November 1992                                                       *)
(*                                                                          *)
(* From bezem@phil.ruu.nl Fri Apr  2 13:14:31 1993                          *)
(*                                                                          *)
(****************************************************************************)
(*                               abp_lem25.v                                *)
(****************************************************************************)
intros.
elim EXPH4.
elim Lmers6.
elim LmerK.
elim LmerTnd.
pattern (R i) at 1 3 4 5 in |- *.
elim ProcR.
elim LmerRn.
elim CommTn_dK.
elim (SC3 (seq (Rn e1) (seq (Rn e0) (R i))) (K i)).
elim CommKRn.
elim
(SC3 (seq (Rn e1) (seq (Rn e0) (R i))) (seq (Tn_d d e0) (seq (Sn e1) (S i)))).
elim CommTn_dRn.
elim CommKs6.
elim CommRns6.
pattern e1 at 1 2 in |- *.
elimtype (toggle e0 = e1).
elim CommTn_ds6_b.
repeat elim A6.
repeat elim A6'.
unfold X1 in |- *.
elim
(SC6 (mer (seq (Sn_d d e0) (seq (Sn e1) (S i))) (mer (R i) (K i))) (L i)).
elim SC7.
elim SC7.
elim (SC6 (mer (K i) (L i)) (R i)).
elim SC7.
apply refl_equal.
elim Toggle1.
apply refl_equal.
Qed.
intros.
elim EXPH4.
elim Lmers6.
elim LmerK.
elim LmerTnd.
pattern (R i) at 1 3 4 5 in |- *.
elim ProcR.
elim LmerRn.
elim CommTn_dK.
elim (SC3 (seq (Rn e1) (seq (Rn e0) (R i))) (K i)).
elim CommKRn.
elim
(SC3 (seq (Rn e1) (seq (Rn e0) (R i))) (seq (Tn_d d e0) (seq (Sn e1) (S i)))).
elim CommTn_dRn.
elim CommKs6.
elim CommRns6.
elim CommTn_ds6_sce.
repeat elim A6.
repeat elim A6'.
unfold X1 in |- *.
elim
(SC6 (mer (seq (Sn_d d e0) (seq (Sn e1) (S i))) (mer (R i) (K i))) (L i)).
elim SC7.
elim SC7.
elimtype (mer (K i) (mer (L i) (R i)) = mer (R i) (mer (K i) (L i))).
apply refl_equal.
elim (SC6 (mer (K i) (L i)) (R i)).
elim SC7.
apply refl_equal.
Qed.

Theorem Lem12 :
forall d : D,
seq (ia Frame c2 (Tuple e0 d))
(alt
(seq (ia one int i)
(seq (ia Frame c3 (Tuple e0 d)) (seq (ia D s4 d) (X2 d))))
(seq (ia one int i)
(seq (ia Frame c3 lce)
(seq (ia frame c5 (tuple e1))
(seq
(alt (seq (ia one int i) (ia frame c6 (tuple e1)))
(seq (ia one int i) (ia frame c6 sce)))
(X1 d)))))) = X1 d.