-
Notifications
You must be signed in to change notification settings - Fork 0
/
Propiedad_semidistributiva_de_la_interseccion_sobre_la_union_2.thy
109 lines (100 loc) · 3.26 KB
/
Propiedad_semidistributiva_de_la_interseccion_sobre_la_union_2.thy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
(* Propiedad_semidistributiva_de_la_interseccion_sobre_la_union_2.lean
(s ∩ t) ∪ (s ∩ u) ⊆ s ∩ (t ∪ u)
José A. Alonso Jiménez
Sevilla, 22 de febrero de 2024
---------------------------------------------------------------------
*)
(* ---------------------------------------------------------------------
-- Demostrar que
-- (s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)
-- ------------------------------------------------------------------ *)
theory Propiedad_semidistributiva_de_la_interseccion_sobre_la_union_2
imports Main
begin
(* 1\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
proof (rule subsetI)
fix x
assume "x \<in> (s \<inter> t) \<union> (s \<inter> u)"
then show "x \<in> s \<inter> (t \<union> u)"
proof (rule UnE)
assume xst : "x \<in> s \<inter> t"
then have xs : "x \<in> s"
by (simp only: IntD1)
have xt : "x \<in> t"
using xst by (simp only: IntD2)
then have xtu : "x \<in> t \<union> u"
by (simp only: UnI1)
show "x \<in> s \<inter> (t \<union> u)"
using xs xtu by (simp only: IntI)
next
assume xsu : "x \<in> s \<inter> u"
then have xs : "x \<in> s"
by (simp only: IntD1)
have xt : "x \<in> u"
using xsu by (simp only: IntD2)
then have xtu : "x \<in> t \<union> u"
by (simp only: UnI2)
show "x \<in> s \<inter> (t \<union> u)"
using xs xtu by (simp only: IntI)
qed
qed
(* 2\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
proof
fix x
assume "x \<in> (s \<inter> t) \<union> (s \<inter> u)"
then show "x \<in> s \<inter> (t \<union> u)"
proof
assume xst : "x \<in> s \<inter> t"
then have xs : "x \<in> s"
by simp
have xt : "x \<in> t"
using xst by simp
then have xtu : "x \<in> t \<union> u"
by simp
show "x \<in> s \<inter> (t \<union> u)"
using xs xtu by simp
next
assume xsu : "x \<in> s \<inter> u"
then have xs : "x \<in> s"
by (simp only: IntD1)
have xt : "x \<in> u"
using xsu by simp
then have xtu : "x \<in> t \<union> u"
by simp
show "x \<in> s \<inter> (t \<union> u)"
using xs xtu by simp
qed
qed
(* 3\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
proof
fix x
assume "x \<in> (s \<inter> t) \<union> (s \<inter> u)"
then show "x \<in> s \<inter> (t \<union> u)"
proof
assume "x \<in> s \<inter> t"
then show "x \<in> s \<inter> (t \<union> u)"
by simp
next
assume "x \<in> s \<inter> u"
then show "x \<in> s \<inter> (t \<union> u)"
by simp
qed
qed
(* 4\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
proof
fix x
assume "x \<in> (s \<inter> t) \<union> (s \<inter> u)"
then show "x \<in> s \<inter> (t \<union> u)"
by auto
qed
(* 5\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
by auto
(* 6\<ordfeminine> demostración *)
lemma "(s \<inter> t) \<union> (s \<inter> u) \<subseteq> s \<inter> (t \<union> u)"
by (simp only: distrib_inf_le)
end