X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fmatita%2Fcontribs%2Fdama%2Fdama%2Fordered_uniform.ma;h=e724dc2e6ba4b7613b011973f483f89109096b63;hb=1ee5193677b8e2a80d4f068ee79ecac335de1196;hp=c9b5e7da6ecf6fded8e8250e1bba68ae2126a2e2;hpb=3c1ca5620048ad842144fba291f8bc5f0dca7061;p=helm.git diff --git a/helm/software/matita/contribs/dama/dama/ordered_uniform.ma b/helm/software/matita/contribs/dama/dama/ordered_uniform.ma index c9b5e7da6..e724dc2e6 100644 --- a/helm/software/matita/contribs/dama/dama/ordered_uniform.ma +++ b/helm/software/matita/contribs/dama/dama/ordered_uniform.ma @@ -30,120 +30,165 @@ unfold bishop_set_OF_ordered_uniform_space_; |5: cases (with_ X); simplify; apply (us_phi4 (ous_us_ X))] qed. -coercion cic:/matita/dama/ordered_uniform/ous_unifspace.con. +coercion ous_unifspace. record ordered_uniform_space : Type ≝ { ous_stuff :> ordered_uniform_space_; ous_convex: ∀U.us_unifbase ous_stuff U → convex ous_stuff U }. +(* +definition Type_of_ordered_uniform_space : ordered_uniform_space → Type. +intro; compose ordered_set_OF_ordered_uniform_space with os_l. +apply (hos_carr (f o)); +qed. + +definition Type_of_ordered_uniform_space_dual : ordered_uniform_space → Type. +intro; compose ordered_set_OF_ordered_uniform_space with os_r. +apply (hos_carr (f o)); +qed. -lemma segment_square_of_O_square: - ∀O:ordered_set.∀u,v:O.∀x:O square. - fst x ∈ [u,v] → snd x ∈ [u,v] → {[u,v]} square. -intros; split; exists; [1: apply (fst x) |3: apply (snd x)] assumption; +coercion Type_of_ordered_uniform_space_dual. +coercion Type_of_ordered_uniform_space. +*) +definition half_ordered_set_OF_ordered_uniform_space : ordered_uniform_space → half_ordered_set. +intro; compose ordered_set_OF_ordered_uniform_space with os_l. apply (f o); qed. -coercion cic:/matita/dama/ordered_uniform/segment_square_of_O_square.con 0 2. +definition invert_os_relation ≝ + λC:ordered_set.λU:C squareO → Prop. + λx:C squareO. U 〈\snd x,\fst x〉. + +interpretation "relation invertion" 'invert a = (invert_os_relation _ a). +interpretation "relation invertion" 'invert_symbol = (invert_os_relation _). +interpretation "relation invertion" 'invert_appl a x = (invert_os_relation _ a x). + +lemma segment_square_of_ordered_set_square: + ∀O:ordered_set.∀u,v:O.∀x:O squareO. + \fst x ∈ [u,v] → \snd x ∈ [u,v] → {[u,v]} squareO. +intros; split; exists; [1: apply (\fst x) |3: apply (\snd x)] assumption; +qed. -alias symbol "pi1" (instance 4) = "sigma pi1". -alias symbol "pi1" (instance 2) = "sigma pi1". -lemma O_square_of_segment_square : - ∀O:ordered_set.∀u,v:O.{[u,v]} square → O square ≝ - λO:ordered_set.λu,v:O.λb:{[u,v]} square.〈fst(fst b),fst(snd b)〉. +coercion segment_square_of_ordered_set_square with 0 2 nocomposites. -coercion cic:/matita/dama/ordered_uniform/O_square_of_segment_square.con. +alias symbol "pi1" (instance 4) = "exT \fst". +alias symbol "pi1" (instance 2) = "exT \fst". +lemma ordered_set_square_of_segment_square : + ∀O:ordered_set.∀u,v:O.{[u,v]} squareO → O squareO ≝ + λO:ordered_set.λu,v:O.λb:{[u,v]} squareO.〈\fst(\fst b),\fst(\snd b)〉. + +coercion ordered_set_square_of_segment_square nocomposites. lemma restriction_agreement : - ∀O:ordered_uniform_space.∀l,r:O.∀P:{[l,r]} square → Prop.∀OP:O square → Prop.Prop. -apply(λO:ordered_uniform_space.λl,r:O.λP:{[l,r]} square → Prop.λOP:O square → Prop. - ∀b:O square.∀H1,H2. - (P b → OP b) ∧ (OP b → P b)); + ∀O:ordered_uniform_space.∀l,r:O.∀P:{[l,r]} squareO → Prop.∀OP:O squareO → Prop.Prop. +apply(λO:ordered_uniform_space.λl,r:O. + λP:{[l,r]} squareO → Prop. λOP:O squareO → Prop. + ∀b:O squareO.∀H1,H2.(P b → OP b) ∧ (OP b → P b)); [5,7: apply H1|6,8:apply H2]skip; qed. -lemma unrestrict: ∀O:ordered_uniform_space.∀l,r:O.∀U,u.∀x:{[l,r]} square. +lemma unrestrict: ∀O:ordered_uniform_space.∀l,r:O.∀U,u.∀x:{[l,r]} squareO. restriction_agreement ? l r U u → U x → u x. -intros 7; cases x (b b1); cases b; cases b1; -cases (H 〈x1,x2〉 H1 H2) (L _); intros; apply L; assumption; +intros 7; cases x (b b1); cases b (w1 H1); cases b1 (w2 H2); clear b b1 x; +cases (H 〈w1,w2〉 H1 H2) (L _); intro Uw; apply L; apply Uw; qed. -lemma restrict: ∀O:ordered_uniform_space.∀l,r:O.∀U,u.∀x:{[l,r]} square. +lemma restrict: ∀O:ordered_uniform_space.∀l,r:O.∀U,u.∀x:{[l,r]} squareO. restriction_agreement ? l r U u → u x → U x. -intros 6; cases x (b b1); cases b; cases b1; intros (X); -cases (X 〈x1,x2〉 H H1) (_ R); apply R; assumption; +intros 6; cases x (b b1); cases b (w1 H1); cases b1 (w2 H2); clear b1 b x; +intros (Ra uw); cases (Ra 〈w1,w2〉 H1 H2) (_ R); apply R; apply uw; qed. lemma invert_restriction_agreement: - ∀O:ordered_uniform_space.∀l,r:O.∀U:{[l,r]} square → Prop.∀u. + ∀O:ordered_uniform_space.∀l,r:O. + ∀U:{[l,r]} squareO → Prop.∀u:O squareO → Prop. restriction_agreement ? l r U u → - restriction_agreement ? l r (inv U) (inv u). + restriction_agreement ? l r (\inv U) (\inv u). intros 9; split; intro; -[1: apply (unrestrict ????? (segment_square_of_O_square ??? 〈snd b,fst b〉 H2 H1) H H3); -|2: apply (restrict ????? (segment_square_of_O_square ??? 〈snd b,fst b〉 H2 H1) H H3);] +[1: apply (unrestrict ????? (segment_square_of_ordered_set_square ??? 〈\snd b,\fst b〉 H2 H1) H H3); +|2: apply (restrict ????? (segment_square_of_ordered_set_square ??? 〈\snd b,\fst b〉 H2 H1) H H3);] qed. - -lemma bs_of_ss: - ∀O:ordered_set.∀u,v:O.{[u,v]} square → (bishop_set_of_ordered_set O) square ≝ - λO:ordered_set.λu,v:O.λb:{[u,v]} square.〈fst(fst b),fst(snd b)〉. -notation < "x \sub \neq" non associative with precedence 91 for @{'bsss $x}. +lemma bs2_of_bss2: + ∀O:ordered_set.∀u,v:O.(bishop_set_of_ordered_set {[u,v]}) squareB → (bishop_set_of_ordered_set O) squareB ≝ + λO:ordered_set.λu,v:O.λb:{[u,v]} squareO.〈\fst(\fst b),\fst(\snd b)〉. + +coercion bs2_of_bss2 nocomposites. + +(* +notation < "x \sub \neq" with precedence 91 for @{'bsss $x}. interpretation "bs_of_ss" 'bsss x = (bs_of_ss _ _ _ x). +*) + +(* +lemma ss_of_bs: + ∀O:ordered_set.∀u,v:O. + ∀b:O squareO.\fst b ∈ [u,v] → \snd b ∈ [u,v] → {[u,v]} squareO ≝ + λO:ordered_set.λu,v:O. + λb:O squareB.λH1,H2.〈≪\fst b,H1≫,≪\snd b,H2≫〉. +*) + +(* +notation < "x \sub \nleq" with precedence 91 for @{'ssbs $x}. +interpretation "ss_of_bs" 'ssbs x = (ss_of_bs _ _ _ x _ _). +*) lemma segment_ordered_uniform_space: ∀O:ordered_uniform_space.∀u,v:O.ordered_uniform_space. intros (O l r); apply mk_ordered_uniform_space; [1: apply (mk_ordered_uniform_space_ {[l,r]}); [1: alias symbol "and" = "constructive and". - letin f ≝ (λP:{[l,r]} square → Prop. ∃OP:O square → Prop. + letin f ≝ (λP:{[l,r]} squareO → Prop. ∃OP:O squareO → Prop. (us_unifbase O OP) ∧ restriction_agreement ??? P OP); apply (mk_uniform_space (bishop_set_of_ordered_set {[l,r]}) f); - [1: intros (U H); intro x; unfold mk_set; simplify; + [1: intros (U H); intro x; simplify; cases H (w Hw); cases Hw (Gw Hwp); clear H Hw; intro Hm; - lapply (us_phi1 ?? Gw x Hm) as IH; - apply (restrict ?????? Hwp IH); + lapply (us_phi1 O w Gw x Hm) as IH; + apply (restrict ? l r ??? Hwp IH); |2: intros (U V HU HV); cases HU (u Hu); cases HV (v Hv); clear HU HV; cases Hu (Gu HuU); cases Hv (Gv HvV); clear Hu Hv; - cases (us_phi2 ??? Gu Gv) (w HW); cases HW (Gw Hw); clear HW; - exists; [apply (λb:{[l,r]} square.w b)] split; + cases (us_phi2 O u v Gu Gv) (w HW); cases HW (Gw Hw); clear HW; + exists; [apply (λb:{[l,r]} squareB.w b)] split; [1: unfold f; simplify; clearbody f; exists; [apply w]; split; [assumption] intro b; simplify; - unfold segment_square_of_O_square; (* ??? *) + unfold segment_square_of_ordered_set_square; cases b; intros; split; intros; assumption; - |2: intros 2 (x Hx); unfold mk_set; cases (Hw ? Hx); split; - [apply (restrict ?????? HuU H)|apply (restrict ?????? HvV H1);]] + |2: intros 2 (x Hx); cases (Hw ? Hx); split; + [apply (restrict O l r ??? HuU H)|apply (restrict O l r ??? HvV H1);]] |3: intros (U Hu); cases Hu (u HU); cases HU (Gu HuU); clear Hu HU; - cases (us_phi3 ?? Gu) (w HW); cases HW (Gw Hwu); clear HW; - exists; [apply (λx:{[l,r]} square.w x)] split; + cases (us_phi3 O u Gu) (w HW); cases HW (Gw Hwu); clear HW; + exists; [apply (λx:{[l,r]} squareB.w x)] split; [1: exists;[apply w];split;[assumption] intros; simplify; intro; - unfold segment_square_of_O_square; (* ??? *) + unfold segment_square_of_ordered_set_square; cases b; intros; split; intro; assumption; - |2: intros 2 (x Hx); apply (restrict ?????? HuU); apply Hwu; - cases Hx (m Hm); exists[apply (fst m)] apply Hm;] + |2: intros 2 (x Hx); apply (restrict O l r ??? HuU); apply Hwu; + cases Hx (m Hm); exists[apply (\fst m)] apply Hm;] |4: intros (U HU x); cases HU (u Hu); cases Hu (Gu HuU); clear HU Hu; - cases (us_phi4 ?? Gu x) (Hul Hur); + cases (us_phi4 O u Gu x) (Hul Hur); split; intros; - [1: apply (restrict ?????? (invert_restriction_agreement ????? HuU)); - apply Hul; apply (unrestrict ?????? HuU H); - |2: apply (restrict ?????? HuU); apply Hur; - apply (unrestrict ?????? (invert_restriction_agreement ????? HuU) H);]] + [1: lapply (invert_restriction_agreement O l r ?? HuU) as Ra; + apply (restrict O l r ?? x Ra); + apply Hul; apply (unrestrict O l r ??? HuU H); + |2: apply (restrict O l r ??? HuU); apply Hur; + apply (unrestrict O l r ??? (invert_restriction_agreement O l r ?? HuU) H);]] |2: simplify; reflexivity;] |2: simplify; unfold convex; intros; cases H (u HU); cases HU (Gu HuU); clear HU H; - lapply (ous_convex ?? Gu (bs_of_ss ? l r p) ? H2 (bs_of_ss ? l r y) H3) as Cu; - [1: apply (unrestrict ?????? HuU); apply H1; - |2: apply (restrict ?????? HuU Cu);]] + lapply (ous_convex ?? Gu p ? H2 y H3) as Cu; + [1: apply (unrestrict O l r ??? HuU); apply H1; + |2: apply (restrict O l r ??? HuU Cu);]] qed. interpretation "Ordered uniform space segment" 'segment_set a b = (segment_ordered_uniform_space _ a b). (* Lemma 3.2 *) -alias symbol "pi1" = "sigma pi1". +alias symbol "pi1" = "exT \fst". lemma restric_uniform_convergence: ∀O:ordered_uniform_space.∀l,u:O. - ∀x:{[l,u]}. - ∀a:sequence {[l,u]}. - (λn.fst (a n)) uniform_converges (fst x) → + ∀x:(segment_ordered_uniform_space O l u). + ∀a:sequence (segment_ordered_uniform_space O l u). + uniform_converge (segment_ordered_uniform_space O l u) + (mk_seq O (λn:nat.\fst (a n))) (\fst x) → True. a uniform_converges x. intros 8; cases H1; cases H2; clear H2 H1; cases (H ? H3) (m Hm); exists [apply m]; intros;