1 (**************************************************************************)
4 (* ||A|| A project by Andrea Asperti *)
6 (* ||I|| Developers: *)
7 (* ||T|| The HELM team. *)
8 (* ||A|| http://helm.cs.unibo.it *)
10 (* \ / This file is distributed under the terms of the *)
11 (* v GNU General Public License Version 2 *)
13 (**************************************************************************)
15 include "o-basic_pairs.ma".
16 include "o-saturations.ma".
18 lemma xxx : ∀x.carr x → carr1 (setoid1_of_setoid x). intros; assumption; qed.
21 record concrete_space : Type ≝
23 downarrow: unary_morphism (oa_P (form bp)) (oa_P (form bp));
24 downarrow_is_sat: is_saturation ? downarrow;
26 or_f_minus ?? (⊩) q1 ∧ or_f_minus ?? (⊩) q2 =
27 or_f_minus ?? (⊩) ((downarrow q1) ∧ (downarrow q2));
28 all_covered: (*⨍^-_bp*) or_f_minus ?? (⊩) (oa_one (form bp)) = oa_one (concr bp);
29 il2: ∀I:setoid.∀p:ums I (oa_P (form bp)).
30 downarrow (oa_join ? I (mk_unary_morphism ?? (λi:I. downarrow (p i)) ?)) =
31 oa_join ? I (mk_unary_morphism ?? (λi:I. downarrow (p i)) ?)
34 definition bp': concrete_space → basic_pair ≝ λc.bp c.
38 record convergent_relation_pair (CS1,CS2: concrete_space) : Type ≝
39 { rp:> arrows1 ? CS1 CS2;
42 extS ?? rp \sub\c (BPextS CS2 (b ↓ c)) =
43 BPextS CS1 ((extS ?? rp \sub\f b) ↓ (extS ?? rp \sub\f c));
45 extS ?? rp\sub\c (BPextS CS2 (form CS2)) = BPextS CS1 (form CS1)
48 definition rp' : ∀CS1,CS2. convergent_relation_pair CS1 CS2 → relation_pair CS1 CS2 ≝
49 λCS1,CS2,c. rp CS1 CS2 c.
53 definition convergent_relation_space_setoid: concrete_space → concrete_space → setoid1.
56 [ apply (convergent_relation_pair c c1)
59 apply (relation_pair_equality c c1 c2 c3);
60 | intros 1; apply refl1;
61 | intros 2; apply sym1;
62 | intros 3; apply trans1]]
65 definition rp'': ∀CS1,CS2.convergent_relation_space_setoid CS1 CS2 → arrows1 BP CS1 CS2 ≝
70 definition convergent_relation_space_composition:
71 ∀o1,o2,o3: concrete_space.
73 (convergent_relation_space_setoid o1 o2)
74 (convergent_relation_space_setoid o2 o3)
75 (convergent_relation_space_setoid o1 o3).
76 intros; constructor 1;
77 [ intros; whd in c c1 ⊢ %;
79 [ apply (fun1 ??? (comp1 BP ???)); [apply (bp o2) |*: apply rp; assumption]
81 change in ⊢ (? ? ? (? ? ? (? ? ? %) ?) ?) with (c1 \sub \c ∘ c \sub \c);
82 change in ⊢ (? ? ? ? (? ? ? ? (? ? ? ? ? (? ? ? (? ? ? %) ?) ?)))
83 with (c1 \sub \f ∘ c \sub \f);
84 change in ⊢ (? ? ? ? (? ? ? ? (? ? ? ? ? ? (? ? ? (? ? ? %) ?))))
85 with (c1 \sub \f ∘ c \sub \f);
86 apply (.= (extS_com ??????));
87 apply (.= (†(respects_converges ?????)));
88 apply (.= (respects_converges ?????));
89 apply (.= (†(((extS_com ??????) \sup -1)‡(extS_com ??????)\sup -1)));
91 | change in ⊢ (? ? ? (? ? ? (? ? ? %) ?) ?) with (c1 \sub \c ∘ c \sub \c);
92 apply (.= (extS_com ??????));
93 apply (.= (†(respects_all_covered ???)));
94 apply (.= respects_all_covered ???);
97 change with (b ∘ a = b' ∘ a');
98 change in H with (rp'' ?? a = rp'' ?? a');
99 change in H1 with (rp'' ?? b = rp ?? b');
104 definition CSPA: category1.
106 [ apply concrete_space
107 | apply convergent_relation_space_setoid
108 | intro; constructor 1;
112 apply (.= (equalset_extS_id_X_X ??));
113 apply (.= (†((equalset_extS_id_X_X ??)\sup -1‡
114 (equalset_extS_id_X_X ??)\sup -1)));
116 | apply (.= (equalset_extS_id_X_X ??));
118 | apply convergent_relation_space_composition
120 change with (a34 ∘ (a23 ∘ a12) = (a34 ∘ a23) ∘ a12);
124 change with (a ∘ id1 ? o1 = a);
125 apply (.= id_neutral_right1 ????);
128 change with (id1 ? o2 ∘ a = a);
129 apply (.= id_neutral_left1 ????);