proposition: Theorem make_list63ir l1 l2 c p ll : (Zpos p <= 63)%Z -> int63i c p = true -> In (l1,l2,p) (int63it _ make_list l1 l2 ll c).
proof: Proof. rewrite int63it_naive; unfold naive_int63it; generalize l1 l2 c p ll; clear l1 l2 c p ll. assert(F: forall m p l1 l2 c ll p1, (Z_of_nat m + Zpos p = 63)%Z -> (Zpos p <= Zpos p1 <= 63)%Z -> int63i c p1 = true -> In (l1,l2,p1) (naive_int63it_aux _ (fun s l1 l2 p => s ++ (l1,l2,p) :: nil) m p c l1 l2 ll)). intros m; elim m; clear m. intros p l1 l2 c ll p1 H H1 H2. replace p with p1. simpl naive_int63it_aux; rewrite H2. now apply in_or_app; right; auto with datatypes. assert (H3: (Zpos p = Zpos p1)%Z). now simpl in H; auto with zarith. now injection H3; auto. intros m Hrec p l1 l2 c ll p1. rewrite inj_S; intros H [H1 H2] H3. rewrite naive_auxS. case (Zle_lt_or_eq _ _ H1); intros H4. apply Hrec; auto. now rewrite Zpos_succ_morphism; auto with zarith. now rewrite Zpos_succ_morphism; auto with zarith. replace p with p1. rewrite H3. replace (ll ++ (l1,l2,p1) :: nil) with ((ll ++ (l1,l2,p1) :: nil) ++ nil); auto with datatypes. rewrite naive_auxA. apply in_or_app; left. now apply in_or_app; right; auto with datatypes. now injection H4; auto. intros; apply F; auto with zarith. Qed.
imports: PrimInt63 Cyclic63 List BasicRubik