author | huffman |
Tue, 16 Dec 2008 21:31:55 -0800 | |
changeset 29138 | 661a8db7e647 |
parent 27413 | 3154f3765cc7 |
child 29530 | 9905b660612b |
permissions | -rw-r--r-- |
15600 | 1 |
(* Title: HOLCF/Cprod.thy |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
2 |
Author: Franz Regensburger |
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
3 |
*) |
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
4 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
5 |
header {* The cpo of cartesian products *} |
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
6 |
|
15577 | 7 |
theory Cprod |
25910 | 8 |
imports Bifinite |
15577 | 9 |
begin |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
10 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
11 |
defaultsort cpo |
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
12 |
|
16008 | 13 |
subsection {* Type @{typ unit} is a pcpo *} |
14 |
||
26025 | 15 |
instantiation unit :: sq_ord |
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
16 |
begin |
16008 | 17 |
|
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
18 |
definition |
16008 | 19 |
less_unit_def [simp]: "x \<sqsubseteq> (y::unit) \<equiv> True" |
20 |
||
26025 | 21 |
instance .. |
22 |
end |
|
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
23 |
|
26025 | 24 |
instance unit :: discrete_cpo |
25 |
by intro_classes simp |
|
16008 | 26 |
|
25815 | 27 |
instance unit :: finite_po .. |
16008 | 28 |
|
29 |
instance unit :: pcpo |
|
30 |
by intro_classes simp |
|
31 |
||
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
32 |
definition |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
33 |
unit_when :: "'a \<rightarrow> unit \<rightarrow> 'a" where |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
34 |
"unit_when = (\<Lambda> a _. a)" |
16008 | 35 |
|
18289 | 36 |
translations |
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
37 |
"\<Lambda>(). t" == "CONST unit_when\<cdot>t" |
18289 | 38 |
|
39 |
lemma unit_when [simp]: "unit_when\<cdot>a\<cdot>u = a" |
|
40 |
by (simp add: unit_when_def) |
|
41 |
||
42 |
||
43 |
subsection {* Product type is a partial order *} |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
44 |
|
26035 | 45 |
instantiation "*" :: (sq_ord, sq_ord) sq_ord |
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
46 |
begin |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
47 |
|
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
48 |
definition |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
49 |
less_cprod_def: "(op \<sqsubseteq>) \<equiv> \<lambda>p1 p2. (fst p1 \<sqsubseteq> fst p2 \<and> snd p1 \<sqsubseteq> snd p2)" |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
50 |
|
26035 | 51 |
instance .. |
52 |
end |
|
53 |
||
54 |
instance "*" :: (po, po) po |
|
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
55 |
proof |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
56 |
fix x :: "'a \<times> 'b" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
57 |
show "x \<sqsubseteq> x" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
58 |
unfolding less_cprod_def by simp |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
59 |
next |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
60 |
fix x y :: "'a \<times> 'b" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
61 |
assume "x \<sqsubseteq> y" "y \<sqsubseteq> x" thus "x = y" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
62 |
unfolding less_cprod_def Pair_fst_snd_eq |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
63 |
by (fast intro: antisym_less) |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
64 |
next |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
65 |
fix x y z :: "'a \<times> 'b" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
66 |
assume "x \<sqsubseteq> y" "y \<sqsubseteq> z" thus "x \<sqsubseteq> z" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
67 |
unfolding less_cprod_def |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
68 |
by (fast intro: trans_less) |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
69 |
qed |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
70 |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
71 |
subsection {* Monotonicity of @{text "(_,_)"}, @{term fst}, @{term snd} *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
72 |
|
26029 | 73 |
lemma prod_lessI: "\<lbrakk>fst p \<sqsubseteq> fst q; snd p \<sqsubseteq> snd q\<rbrakk> \<Longrightarrow> p \<sqsubseteq> q" |
74 |
unfolding less_cprod_def by simp |
|
75 |
||
76 |
lemma Pair_less_iff [simp]: "(a, b) \<sqsubseteq> (c, d) = (a \<sqsubseteq> c \<and> b \<sqsubseteq> d)" |
|
77 |
unfolding less_cprod_def by simp |
|
78 |
||
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
79 |
text {* Pair @{text "(_,_)"} is monotone in both arguments *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
80 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
81 |
lemma monofun_pair1: "monofun (\<lambda>x. (x, y))" |
26029 | 82 |
by (simp add: monofun_def) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
83 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
84 |
lemma monofun_pair2: "monofun (\<lambda>y. (x, y))" |
26029 | 85 |
by (simp add: monofun_def) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
86 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
87 |
lemma monofun_pair: |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
88 |
"\<lbrakk>x1 \<sqsubseteq> x2; y1 \<sqsubseteq> y2\<rbrakk> \<Longrightarrow> (x1, y1) \<sqsubseteq> (x2, y2)" |
26029 | 89 |
by simp |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
90 |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
91 |
text {* @{term fst} and @{term snd} are monotone *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
92 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
93 |
lemma monofun_fst: "monofun fst" |
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
94 |
by (simp add: monofun_def less_cprod_def) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
95 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
96 |
lemma monofun_snd: "monofun snd" |
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
97 |
by (simp add: monofun_def less_cprod_def) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
98 |
|
18289 | 99 |
subsection {* Product type is a cpo *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
100 |
|
26018 | 101 |
lemma is_lub_Pair: |
102 |
"\<lbrakk>range X <<| x; range Y <<| y\<rbrakk> \<Longrightarrow> range (\<lambda>i. (X i, Y i)) <<| (x, y)" |
|
103 |
apply (rule is_lubI [OF ub_rangeI]) |
|
104 |
apply (simp add: less_cprod_def is_ub_lub) |
|
105 |
apply (frule ub2ub_monofun [OF monofun_fst]) |
|
106 |
apply (drule ub2ub_monofun [OF monofun_snd]) |
|
107 |
apply (simp add: less_cprod_def is_lub_lub) |
|
108 |
done |
|
109 |
||
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
110 |
lemma lub_cprod: |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
111 |
fixes S :: "nat \<Rightarrow> ('a::cpo \<times> 'b::cpo)" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
112 |
assumes S: "chain S" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
113 |
shows "range S <<| (\<Squnion>i. fst (S i), \<Squnion>i. snd (S i))" |
26018 | 114 |
proof - |
115 |
have "chain (\<lambda>i. fst (S i))" |
|
116 |
using monofun_fst S by (rule ch2ch_monofun) |
|
117 |
hence 1: "range (\<lambda>i. fst (S i)) <<| (\<Squnion>i. fst (S i))" |
|
26027 | 118 |
by (rule cpo_lubI) |
26018 | 119 |
have "chain (\<lambda>i. snd (S i))" |
120 |
using monofun_snd S by (rule ch2ch_monofun) |
|
121 |
hence 2: "range (\<lambda>i. snd (S i)) <<| (\<Squnion>i. snd (S i))" |
|
26027 | 122 |
by (rule cpo_lubI) |
26018 | 123 |
show "range S <<| (\<Squnion>i. fst (S i), \<Squnion>i. snd (S i))" |
124 |
using is_lub_Pair [OF 1 2] by simp |
|
125 |
qed |
|
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
126 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
127 |
lemma thelub_cprod: |
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
128 |
"chain (S::nat \<Rightarrow> 'a::cpo \<times> 'b::cpo) |
27413 | 129 |
\<Longrightarrow> (\<Squnion>i. S i) = (\<Squnion>i. fst (S i), \<Squnion>i. snd (S i))" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
130 |
by (rule lub_cprod [THEN thelubI]) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
131 |
|
25784
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
132 |
instance "*" :: (cpo, cpo) cpo |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
133 |
proof |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
134 |
fix S :: "nat \<Rightarrow> ('a \<times> 'b)" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
135 |
assume "chain S" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
136 |
hence "range S <<| (\<Squnion>i. fst (S i), \<Squnion>i. snd (S i))" |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
137 |
by (rule lub_cprod) |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
138 |
thus "\<exists>x. range S <<| x" .. |
71157f7e671e
update instance proofs for sq_ord, po; new instance proofs for dcpo
huffman
parents:
25131
diff
changeset
|
139 |
qed |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
140 |
|
25827
c2adeb1bae5c
new instance proofs for classes finite_po, chfin, flat
huffman
parents:
25815
diff
changeset
|
141 |
instance "*" :: (finite_po, finite_po) finite_po .. |
c2adeb1bae5c
new instance proofs for classes finite_po, chfin, flat
huffman
parents:
25815
diff
changeset
|
142 |
|
26025 | 143 |
instance "*" :: (discrete_cpo, discrete_cpo) discrete_cpo |
144 |
proof |
|
145 |
fix x y :: "'a \<times> 'b" |
|
146 |
show "x \<sqsubseteq> y \<longleftrightarrow> x = y" |
|
147 |
unfolding less_cprod_def Pair_fst_snd_eq |
|
148 |
by simp |
|
149 |
qed |
|
150 |
||
18289 | 151 |
subsection {* Product type is pointed *} |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
152 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
153 |
lemma minimal_cprod: "(\<bottom>, \<bottom>) \<sqsubseteq> p" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
154 |
by (simp add: less_cprod_def) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
155 |
|
25908 | 156 |
instance "*" :: (pcpo, pcpo) pcpo |
157 |
by intro_classes (fast intro: minimal_cprod) |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
158 |
|
25908 | 159 |
lemma inst_cprod_pcpo: "\<bottom> = (\<bottom>, \<bottom>)" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
160 |
by (rule minimal_cprod [THEN UU_I, symmetric]) |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
161 |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
162 |
|
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
163 |
subsection {* Continuity of @{text "(_,_)"}, @{term fst}, @{term snd} *} |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
164 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
165 |
lemma cont_pair1: "cont (\<lambda>x. (x, y))" |
26018 | 166 |
apply (rule contI) |
167 |
apply (rule is_lub_Pair) |
|
26027 | 168 |
apply (erule cpo_lubI) |
26018 | 169 |
apply (rule lub_const) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
170 |
done |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
171 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
172 |
lemma cont_pair2: "cont (\<lambda>y. (x, y))" |
26018 | 173 |
apply (rule contI) |
174 |
apply (rule is_lub_Pair) |
|
175 |
apply (rule lub_const) |
|
26027 | 176 |
apply (erule cpo_lubI) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
177 |
done |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
178 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
179 |
lemma contlub_fst: "contlub fst" |
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
180 |
apply (rule contlubI) |
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
181 |
apply (simp add: thelub_cprod) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
182 |
done |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
183 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
184 |
lemma contlub_snd: "contlub snd" |
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
185 |
apply (rule contlubI) |
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
186 |
apply (simp add: thelub_cprod) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
187 |
done |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
188 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
189 |
lemma cont_fst: "cont fst" |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
190 |
apply (rule monocontlub2cont) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
191 |
apply (rule monofun_fst) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
192 |
apply (rule contlub_fst) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
193 |
done |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
194 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
195 |
lemma cont_snd: "cont snd" |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
196 |
apply (rule monocontlub2cont) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
197 |
apply (rule monofun_snd) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
198 |
apply (rule contlub_snd) |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
199 |
done |
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
200 |
|
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
201 |
subsection {* Continuous versions of constants *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
202 |
|
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
203 |
definition |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
204 |
cpair :: "'a \<rightarrow> 'b \<rightarrow> ('a * 'b)" -- {* continuous pairing *} where |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
205 |
"cpair = (\<Lambda> x y. (x, y))" |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
206 |
|
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
207 |
definition |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
208 |
cfst :: "('a * 'b) \<rightarrow> 'a" where |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
209 |
"cfst = (\<Lambda> p. fst p)" |
17834 | 210 |
|
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
211 |
definition |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
212 |
csnd :: "('a * 'b) \<rightarrow> 'b" where |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
213 |
"csnd = (\<Lambda> p. snd p)" |
17834 | 214 |
|
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
215 |
definition |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
216 |
csplit :: "('a \<rightarrow> 'b \<rightarrow> 'c) \<rightarrow> ('a * 'b) \<rightarrow> 'c" where |
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
217 |
"csplit = (\<Lambda> f p. f\<cdot>(cfst\<cdot>p)\<cdot>(csnd\<cdot>p))" |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
218 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
219 |
syntax |
17834 | 220 |
"_ctuple" :: "['a, args] \<Rightarrow> 'a * 'b" ("(1<_,/ _>)") |
221 |
||
222 |
syntax (xsymbols) |
|
223 |
"_ctuple" :: "['a, args] \<Rightarrow> 'a * 'b" ("(1\<langle>_,/ _\<rangle>)") |
|
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
224 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
225 |
translations |
18078
20e5a6440790
change syntax for LAM to use expressions as patterns; define LAM pattern syntax for cpair, spair, sinl, sinr, up
huffman
parents:
18077
diff
changeset
|
226 |
"\<langle>x, y, z\<rangle>" == "\<langle>x, \<langle>y, z\<rangle>\<rangle>" |
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
227 |
"\<langle>x, y\<rangle>" == "CONST cpair\<cdot>x\<cdot>y" |
17834 | 228 |
|
17816
9942c5ed866a
new syntax translations for continuous lambda abstraction
huffman
parents:
16916
diff
changeset
|
229 |
translations |
25131
2c8caac48ade
modernized specifications ('definition', 'abbreviation', 'notation');
wenzelm
parents:
18289
diff
changeset
|
230 |
"\<Lambda>(CONST cpair\<cdot>x\<cdot>y). t" == "CONST csplit\<cdot>(\<Lambda> x y. t)" |
17816
9942c5ed866a
new syntax translations for continuous lambda abstraction
huffman
parents:
16916
diff
changeset
|
231 |
|
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
232 |
|
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
233 |
subsection {* Convert all lemmas to the continuous versions *} |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
234 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
235 |
lemma cpair_eq_pair: "<x, y> = (x, y)" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
236 |
by (simp add: cpair_def cont_pair1 cont_pair2) |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
237 |
|
25910 | 238 |
lemma pair_eq_cpair: "(x, y) = <x, y>" |
239 |
by (simp add: cpair_def cont_pair1 cont_pair2) |
|
240 |
||
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
241 |
lemma inject_cpair: "<a,b> = <aa,ba> \<Longrightarrow> a = aa \<and> b = ba" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
242 |
by (simp add: cpair_eq_pair) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
243 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
244 |
lemma cpair_eq [iff]: "(<a, b> = <a', b'>) = (a = a' \<and> b = b')" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
245 |
by (simp add: cpair_eq_pair) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
246 |
|
18077
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
247 |
lemma cpair_less [iff]: "(<a, b> \<sqsubseteq> <a', b'>) = (a \<sqsubseteq> a' \<and> b \<sqsubseteq> b')" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
248 |
by (simp add: cpair_eq_pair less_cprod_def) |
16057
e23a61b3406f
added lemma cpair_eq, made cfst_strict and csnd_strict into simp rules
huffman
parents:
16008
diff
changeset
|
249 |
|
18077
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
250 |
lemma cpair_defined_iff [iff]: "(<x, y> = \<bottom>) = (x = \<bottom> \<and> y = \<bottom>)" |
16916 | 251 |
by (simp add: inst_cprod_pcpo cpair_eq_pair) |
252 |
||
25913 | 253 |
lemma cpair_strict [simp]: "\<langle>\<bottom>, \<bottom>\<rangle> = \<bottom>" |
18077
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
254 |
by simp |
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
255 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
256 |
lemma inst_cprod_pcpo2: "\<bottom> = <\<bottom>, \<bottom>>" |
16916 | 257 |
by (rule cpair_strict [symmetric]) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
258 |
|
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
259 |
lemma defined_cpair_rev: |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
260 |
"<a,b> = \<bottom> \<Longrightarrow> a = \<bottom> \<and> b = \<bottom>" |
18077
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
261 |
by simp |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
262 |
|
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
263 |
lemma Exh_Cprod2: "\<exists>a b. z = <a, b>" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
264 |
by (simp add: cpair_eq_pair) |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
265 |
|
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
266 |
lemma cprodE: "\<lbrakk>\<And>x y. p = <x, y> \<Longrightarrow> Q\<rbrakk> \<Longrightarrow> Q" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
267 |
by (cut_tac Exh_Cprod2, auto) |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
268 |
|
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
269 |
lemma cfst_cpair [simp]: "cfst\<cdot><x, y> = x" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
270 |
by (simp add: cpair_eq_pair cfst_def cont_fst) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
271 |
|
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
272 |
lemma csnd_cpair [simp]: "csnd\<cdot><x, y> = y" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
273 |
by (simp add: cpair_eq_pair csnd_def cont_snd) |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
274 |
|
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
275 |
lemma cfst_strict [simp]: "cfst\<cdot>\<bottom> = \<bottom>" |
25913 | 276 |
unfolding inst_cprod_pcpo2 by (rule cfst_cpair) |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
277 |
|
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
278 |
lemma csnd_strict [simp]: "csnd\<cdot>\<bottom> = \<bottom>" |
25913 | 279 |
unfolding inst_cprod_pcpo2 by (rule csnd_cpair) |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
280 |
|
25910 | 281 |
lemma cpair_cfst_csnd: "\<langle>cfst\<cdot>p, csnd\<cdot>p\<rangle> = p" |
282 |
by (cases p rule: cprodE, simp) |
|
283 |
||
284 |
lemmas surjective_pairing_Cprod2 = cpair_cfst_csnd |
|
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
285 |
|
16750 | 286 |
lemma less_cprod: "x \<sqsubseteq> y = (cfst\<cdot>x \<sqsubseteq> cfst\<cdot>y \<and> csnd\<cdot>x \<sqsubseteq> csnd\<cdot>y)" |
16315 | 287 |
by (simp add: less_cprod_def cfst_def csnd_def cont_fst cont_snd) |
288 |
||
16750 | 289 |
lemma eq_cprod: "(x = y) = (cfst\<cdot>x = cfst\<cdot>y \<and> csnd\<cdot>x = csnd\<cdot>y)" |
290 |
by (auto simp add: po_eq_conv less_cprod) |
|
291 |
||
25879 | 292 |
lemma cfst_less_iff: "cfst\<cdot>x \<sqsubseteq> y = x \<sqsubseteq> <y, csnd\<cdot>x>" |
293 |
by (simp add: less_cprod) |
|
294 |
||
295 |
lemma csnd_less_iff: "csnd\<cdot>x \<sqsubseteq> y = x \<sqsubseteq> <cfst\<cdot>x, y>" |
|
296 |
by (simp add: less_cprod) |
|
297 |
||
298 |
lemma compact_cfst: "compact x \<Longrightarrow> compact (cfst\<cdot>x)" |
|
299 |
by (rule compactI, simp add: cfst_less_iff) |
|
300 |
||
301 |
lemma compact_csnd: "compact x \<Longrightarrow> compact (csnd\<cdot>x)" |
|
302 |
by (rule compactI, simp add: csnd_less_iff) |
|
303 |
||
304 |
lemma compact_cpair: "\<lbrakk>compact x; compact y\<rbrakk> \<Longrightarrow> compact <x, y>" |
|
17837 | 305 |
by (rule compactI, simp add: less_cprod) |
306 |
||
25879 | 307 |
lemma compact_cpair_iff [simp]: "compact <x, y> = (compact x \<and> compact y)" |
308 |
apply (safe intro!: compact_cpair) |
|
309 |
apply (drule compact_cfst, simp) |
|
310 |
apply (drule compact_csnd, simp) |
|
311 |
done |
|
312 |
||
25905 | 313 |
instance "*" :: (chfin, chfin) chfin |
25921 | 314 |
apply intro_classes |
25905 | 315 |
apply (erule compact_imp_max_in_chain) |
316 |
apply (rule_tac p="\<Squnion>i. Y i" in cprodE, simp) |
|
317 |
done |
|
318 |
||
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
319 |
lemma lub_cprod2: |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
320 |
"chain S \<Longrightarrow> range S <<| <\<Squnion>i. cfst\<cdot>(S i), \<Squnion>i. csnd\<cdot>(S i)>" |
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
321 |
apply (simp add: cpair_eq_pair cfst_def csnd_def cont_fst cont_snd) |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
322 |
apply (erule lub_cprod) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
323 |
done |
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
324 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
325 |
lemma thelub_cprod2: |
27413 | 326 |
"chain S \<Longrightarrow> (\<Squnion>i. S i) = <\<Squnion>i. cfst\<cdot>(S i), \<Squnion>i. csnd\<cdot>(S i)>" |
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
327 |
by (rule lub_cprod2 [THEN thelubI]) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
328 |
|
18077
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
329 |
lemma csplit1 [simp]: "csplit\<cdot>f\<cdot>\<bottom> = f\<cdot>\<bottom>\<cdot>\<bottom>" |
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
330 |
by (simp add: csplit_def) |
f1f4f951ec8d
make cpair_less, cpair_defined_iff into iff rules; add lemma csplit1
huffman
parents:
17837
diff
changeset
|
331 |
|
16081
81a4b4a245b0
cleaned up, added cpair_less and cpair_eq_pair, removed some obsolete stuff
huffman
parents:
16070
diff
changeset
|
332 |
lemma csplit2 [simp]: "csplit\<cdot>f\<cdot><x,y> = f\<cdot>x\<cdot>y" |
15593
24d770bbc44a
reordered and arranged for document generation, cleaned up some proofs
huffman
parents:
15577
diff
changeset
|
333 |
by (simp add: csplit_def) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
334 |
|
16553 | 335 |
lemma csplit3 [simp]: "csplit\<cdot>cpair\<cdot>z = z" |
25910 | 336 |
by (simp add: csplit_def cpair_cfst_csnd) |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
337 |
|
16210
5d1b752cacc1
changed to use new contlubI, monofun_def; renamed cfst2, csnd2 to cfst_cpair, csnd_cpair; added lemma cpair_strict
huffman
parents:
16093
diff
changeset
|
338 |
lemmas Cprod_rews = cfst_cpair csnd_cpair csplit2 |
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
339 |
|
25910 | 340 |
subsection {* Product type is a bifinite domain *} |
341 |
||
26962
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
342 |
instantiation "*" :: (profinite, profinite) profinite |
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
343 |
begin |
25910 | 344 |
|
26962
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
345 |
definition |
25910 | 346 |
approx_cprod_def: |
26962
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
347 |
"approx = (\<lambda>n. \<Lambda>\<langle>x, y\<rangle>. \<langle>approx n\<cdot>x, approx n\<cdot>y\<rangle>)" |
25910 | 348 |
|
26962
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
349 |
instance proof |
25910 | 350 |
fix i :: nat and x :: "'a \<times> 'b" |
27310 | 351 |
show "chain (approx :: nat \<Rightarrow> 'a \<times> 'b \<rightarrow> 'a \<times> 'b)" |
25910 | 352 |
unfolding approx_cprod_def by simp |
353 |
show "(\<Squnion>i. approx i\<cdot>x) = x" |
|
354 |
unfolding approx_cprod_def |
|
355 |
by (simp add: lub_distribs eta_cfun) |
|
356 |
show "approx i\<cdot>(approx i\<cdot>x) = approx i\<cdot>x" |
|
357 |
unfolding approx_cprod_def csplit_def by simp |
|
358 |
have "{x::'a \<times> 'b. approx i\<cdot>x = x} \<subseteq> |
|
359 |
{x::'a. approx i\<cdot>x = x} \<times> {x::'b. approx i\<cdot>x = x}" |
|
360 |
unfolding approx_cprod_def |
|
361 |
by (clarsimp simp add: pair_eq_cpair) |
|
362 |
thus "finite {x::'a \<times> 'b. approx i\<cdot>x = x}" |
|
363 |
by (rule finite_subset, |
|
364 |
intro finite_cartesian_product finite_fixes_approx) |
|
365 |
qed |
|
366 |
||
26962
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
367 |
end |
c8b20f615d6c
use new class package for classes profinite, bifinite; remove approx class
huffman
parents:
26407
diff
changeset
|
368 |
|
25910 | 369 |
instance "*" :: (bifinite, bifinite) bifinite .. |
370 |
||
371 |
lemma approx_cpair [simp]: |
|
372 |
"approx i\<cdot>\<langle>x, y\<rangle> = \<langle>approx i\<cdot>x, approx i\<cdot>y\<rangle>" |
|
373 |
unfolding approx_cprod_def by simp |
|
374 |
||
375 |
lemma cfst_approx: "cfst\<cdot>(approx i\<cdot>p) = approx i\<cdot>(cfst\<cdot>p)" |
|
376 |
by (cases p rule: cprodE, simp) |
|
377 |
||
378 |
lemma csnd_approx: "csnd\<cdot>(approx i\<cdot>p) = approx i\<cdot>(csnd\<cdot>p)" |
|
379 |
by (cases p rule: cprodE, simp) |
|
380 |
||
15576
efb95d0d01f7
converted to new-style theories, and combined numbered files
huffman
parents:
diff
changeset
|
381 |
end |