4905
|
1 |
|
17248
|
2 |
(* $Id$ *)
|
|
3 |
|
|
4 |
header {* Example 3.8 *}
|
4905
|
5 |
|
17248
|
6 |
theory Ex2
|
|
7 |
imports LCF
|
|
8 |
begin
|
4905
|
9 |
|
|
10 |
consts
|
17248
|
11 |
P :: "'a => tr"
|
|
12 |
F :: "'a => 'a"
|
|
13 |
G :: "'a => 'a"
|
|
14 |
H :: "'a => 'b => 'b"
|
|
15 |
K :: "('a => 'b => 'b) => ('a => 'b => 'b)"
|
4905
|
16 |
|
17248
|
17 |
axioms
|
|
18 |
F_strict: "F(UU) = UU"
|
|
19 |
K: "K = (%h x y. P(x) => y | F(h(G(x),y)))"
|
|
20 |
H: "H = FIX(K)"
|
|
21 |
|
19755
|
22 |
declare F_strict [simp] K [simp]
|
|
23 |
|
|
24 |
lemma example: "ALL x. F(H(x::'a,y::'b)) = H(x,F(y))"
|
|
25 |
apply (simplesubst H)
|
|
26 |
apply (tactic {* induct_tac "K:: ('a=>'b=>'b) => ('a=>'b=>'b)" 1 *})
|
|
27 |
apply (simp (no_asm))
|
|
28 |
apply (simp (no_asm_simp) split: COND_cases_iff)
|
|
29 |
done
|
4905
|
30 |
|
|
31 |
end
|