--- a/Nominal/Ex/Lambda.thy Thu Jun 02 16:41:09 2011 +0900
+++ b/Nominal/Ex/Lambda.thy Thu Jun 02 12:14:03 2011 +0100
@@ -10,6 +10,36 @@
| App "lam" "lam"
| Lam x::"name" l::"lam" bind x in l ("Lam [_]. _" [100, 100] 100)
+lemma cheat: "P" sorry
+
+nominal_primrec
+ f
+where
+ "f f1 f2 f3 (Var x) = f1 x"
+| "f f1 f2 f3 (App t1 t2) = f2 t1 t2 (f f1 f2 f3 t1) (f f1 f2 f3 t2)"
+| "atom x \<sharp> (f1,f2,f3) \<Longrightarrow> f f1 f2 f3 (Lam [x].t) = f3 x t (f f1 f2 f3 t)"
+unfolding eqvt_def f_graph_def
+apply (rule, perm_simp, rule)
+apply(case_tac x)
+apply(simp)
+apply(rule_tac y="d" in lam.exhaust)
+apply(auto)[1]
+apply(auto simp add: lam.distinct lam.eq_iff)[3]
+apply(blast)
+apply(rule cheat) (* this can be solved *)
+apply(simp)
+apply(simp)
+apply(simp)
+apply(simp)
+apply(simp)
+sorry (*this could be defined *)
+
+termination sorry
+
+thm f.simps
+
+
+
inductive
triv :: "lam \<Rightarrow> nat \<Rightarrow> bool"