Section ListDenotePred.
Context {A B : Type}.
Variables (f : A -> pred B) (b : pred B).
Proof with auto.
induction l; simpl... apply extensionality; intro x.
apply prop_ext; split; intro H. right... destruct H... inversion H.
rewrite IHl, union_assoc...
Qed.
Proof with auto.
induction l; simpl... intros [C D].
solve[rewrite listd_app; apply H; split; auto].
Qed.
Proof with simpl; try solve[exfalso; auto]; auto.
induction l... intro C; split; [ solve [apply (C a); left; auto] | ].
apply IHl...
Qed.
Proof with try solve[exfalso; auto]; auto.
revert a; induction l; simpl; intros a' C D...
destruct D as [D|D]; [rewrite <- D|].
solve [destruct C as [C1 C2]; auto]. solve[destruct C; apply IHl; auto].
Qed.
Proof with simpl; try solve[exfalso; auto|congruence]; auto.
induction l... intros [[a [C D]]|E]... intros [[a0 [C D]]|E]...
destruct C; subst. left... right; apply IHl; eauto.
right; eapply IHl...
Qed.
Proof with try solve[exfalso; auto|congruence]; auto.
induction l... destruct 1. left; exists a; split; simpl...
spec IHl H. destruct IHl as [[a0 [C D]]|E].
left; exists a0; split; simpl... right...
Qed.
(* todo: add map/fold_right lems for prop, etc. *)
Proof with try solve [exfalso; auto]; auto.
induction l... simpl; intros [? ?]; split...
Qed.
Proof with simpl; try solve [exfalso; auto]; auto.
induction l... simpl; intros [? ?]. spec H a. destruct (h a)... split...
Qed.
Proof with try solve [exfalso; auto]; auto.
revert c0 H; induction l... simpl; intros c0 H C [D E]. apply H...
Qed.
Proof with try solve [exfalso; auto]; auto.
revert c0 H; induction l... simpl; intros c0 H C [D E]; apply IHl...
Qed.
Proof with try solve [exfalso; auto]; auto.
induction l... simpl. intros [H1 H2]. if_tac... simpl... split...
Qed.

Lemma listd_partition_pred h l xs ys s (H : partition h l = (xs, ys)) :
listd f inter TT l s ->
listd f inter TT xs s /\ listd f inter TT ys s.