Section sec_map_modalop.
Variable A B: Type.
Proof using.
unfold and_tl; intuition.
Qed.
Proof using.
unfold and_tl; intuition.
Qed.
Proof using.
unfold or_tl; intuition.
Qed.
Proof using.
unfold or_tl; intuition.
Qed.
Proof using.
unfold impl_tl; intuition.
Qed.
Proof using.
unfold impl_tl; intuition.
Qed.
Proof using.
unfold not_tl; intuition.
Qed.
Proof using.
unfold not_tl; intuition.
Qed.
Proof using.
intros f P (x, s) nP; assumption.
Qed.
Proof using.
intros f P (x, s) nP; assumption.
Qed.
Proof using.
intros f P Q PQ [x s]; apply PQ.
Qed.
Proof using.
intros f P Q QP [x s]; apply QP.
Qed.
Proof using.
intros f P (x, (y, s)) nP; assumption.
Qed.
Proof using.
intros f P (x, (y, s)) nP; assumption.
Qed.
Proof using.
intros f P Q PQ. cofix cf.
intros (x, s) a. case (always_Cons a); intros a1 a2. constructor.
- apply PQ. assumption.
- rewrite map_Cons; simpl. apply cf; assumption.
Qed.
Proof using.
intros f J P Q inv JQP. cofix c.
intros [x s] Js a.
rewrite map_Cons in a. case (always_Cons a); intros a1 a2. constructor.
- apply JQP. assumption.
rewrite map_Cons; assumption.
- simpl. apply c.
* apply (inv x). assumption.
* assumption.
Qed.
Proof using.
intros f P Q QP s.
apply (always_map_conv_ext f P Q True_tl); auto.
Qed.

Lemma weak_until_map :
forall (f: A->B) (J P: infseq A->Prop) (K Q: infseq B->Prop),
(forall s, J s -> K (map f s)) ->
(forall s, P s -> Q (map f s)) ->
forall (s: infseq A),
weak_until J P s -> weak_until K Q (map f s).