1911
|
1 |
theory SingleLet
|
2024
|
2 |
imports "../NewParser"
|
1596
|
3 |
begin
|
|
4 |
|
|
5 |
atom_decl name
|
|
6 |
|
2288
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
7 |
ML {* print_depth 50 *}
|
2299
|
8 |
declare [[STEPS = 8]]
|
2288
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
9 |
|
2294
|
10 |
|
1911
|
11 |
nominal_datatype trm =
|
|
12 |
Var "name"
|
|
13 |
| App "trm" "trm"
|
2024
|
14 |
| Lam x::"name" t::"trm" bind_set x in t
|
|
15 |
| Let a::"assg" t::"trm" bind_set "bn a" in t
|
2296
|
16 |
| Foo x::"name" y::"name" t::"trm" bind_set x in y t
|
|
17 |
| Bar x::"name" y::"name" t::"trm" bind y x in t x y
|
1911
|
18 |
and assg =
|
|
19 |
As "name" "trm"
|
1596
|
20 |
binder
|
1911
|
21 |
bn::"assg \<Rightarrow> atom set"
|
1596
|
22 |
where
|
1911
|
23 |
"bn (As x t) = {atom x}"
|
|
24 |
|
2296
|
25 |
|
2302
|
26 |
thm permute_trm_raw_permute_assg_raw.simps[no_vars]
|
2293
|
27 |
thm fv_trm_raw.simps[no_vars] fv_assg_raw.simps[no_vars] fv_bn_raw.simps[no_vars] bn_raw.simps[no_vars]
|
2295
|
28 |
thm alpha_trm_raw_alpha_assg_raw_alpha_bn_raw.intros[no_vars]
|
|
29 |
|
2302
|
30 |
ML {* val {inducts, ... } = Function.get_info @{context} @{term "fv_trm_raw"}*}
|
|
31 |
ML {* Rule_Cases.strict_mutual_rule @{context} (the inducts) *}
|
|
32 |
|
|
33 |
(*
|
|
34 |
lemma empty_eqvt[eqvt]:
|
|
35 |
shows "p \<bullet> {} = {}"
|
|
36 |
unfolding empty_def
|
|
37 |
by (perm_simp) (rule refl)
|
|
38 |
*)
|
|
39 |
lemma
|
|
40 |
"(p \<bullet> {}) = {}"
|
|
41 |
thm eqvts_raw
|
|
42 |
thm eqvts
|
|
43 |
apply(perm_strict_simp)
|
|
44 |
|
|
45 |
|
|
46 |
lemma
|
|
47 |
shows "p1 \<bullet> fv_trm_raw trm_raw = fv_trm_raw (p1 \<bullet> trm_raw)"
|
|
48 |
and "p1 \<bullet> fv_assg_raw assg_raw = fv_assg_raw (p1 \<bullet> assg_raw)"
|
|
49 |
and "p1 \<bullet> fv_bn_raw assg_raw = fv_bn_raw (p1 \<bullet> assg_raw)"
|
|
50 |
apply(induct trm_raw and assg_raw and assg_raw rule: fv_trm_raw_fv_assg_raw_fv_bn_raw.induct)
|
|
51 |
apply(simp_all)
|
|
52 |
apply(perm_simp)
|
|
53 |
apply(rule refl)
|
|
54 |
apply(perm_simp)
|
|
55 |
apply(rule refl)
|
|
56 |
apply(perm_simp)
|
|
57 |
apply(rule refl)
|
|
58 |
apply(simp add: fv_trm_raw.simps)
|
|
59 |
|
2288
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
60 |
|
2296
|
61 |
|
2107
5686d83db1f9
ingnored parameters in equivariance; added a proper interface to be called from ML
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
62 |
ML {* Inductive.the_inductive *}
|
1911
|
63 |
thm trm_assg.fv
|
|
64 |
thm trm_assg.supp
|
2024
|
65 |
thm trm_assg.eq_iff
|
1911
|
66 |
thm trm_assg.bn
|
|
67 |
thm trm_assg.perm
|
|
68 |
thm trm_assg.induct
|
|
69 |
thm trm_assg.inducts
|
|
70 |
thm trm_assg.distinct
|
|
71 |
ML {* Sign.of_sort @{theory} (@{typ trm}, @{sort fs}) *}
|
2288
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
72 |
|
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
73 |
(* TEMPORARY
|
2024
|
74 |
thm trm_assg.fv[simplified trm_assg.supp(1-2)]
|
2288
3b83960f9544
new fv/fv_bn function (supp breaks now); exported raw perms and raw funs into separate ML-files
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
75 |
*)
|
2064
2725853f43b9
solved the problem with equivariance by first eta-normalising the goal
Christian Urban <urbanc@in.tum.de>
diff
changeset
|
76 |
|
1596
|
77 |
|
2146
|
78 |
|
1596
|
79 |
end
|
|
80 |
|
|
81 |
|
|
82 |
|