# HG changeset patch # User blanchet # Date 1300985367 -3600 # Node ID 22e37d9bc21c4b78d1db503752908a9559c1d221 # Parent 6066a35f66784ef9adfec339156d1f4066ff3a4a made one more Metis example use the new Skolemizer diff -r 6066a35f6678 -r 22e37d9bc21c src/HOL/Metis_Examples/TransClosure.thy --- a/src/HOL/Metis_Examples/TransClosure.thy Thu Mar 24 17:49:27 2011 +0100 +++ b/src/HOL/Metis_Examples/TransClosure.thy Thu Mar 24 17:49:27 2011 +0100 @@ -9,13 +9,15 @@ imports Main begin -types addr = nat +declare [[metis_new_skolemizer]] + +type_synonym addr = nat datatype val = Unit -- "dummy result value of void expressions" | Null -- "null reference" | Bool bool -- "Boolean value" - | Intg int -- "integer value" + | Intg int -- "integer value" | Addr addr -- "addresses of objects in the heap" consts R :: "(addr \ addr) set" @@ -32,7 +34,7 @@ assume A4: "(b, c) \ R\<^sup>*" have F1: "f c \ f b" using A2 A1 by metis have F2: "\u. (b, u) \ R \ (a, u) \ R\<^sup>*" using A3 by (metis transitive_closure_trans(6)) - have F3: "\x. (b, x R b c) \ R \ c = b" using A4 by (metis converse_rtranclE) + have F3: "\x. (b, x b c R) \ R \ c = b" using A4 by (metis converse_rtranclE) have "c \ b" using F1 by metis hence "\u. (b, u) \ R" using F3 by metis thus "\c. (b, c) \ R \ (a, c) \ R\<^sup>*" using F2 by metis @@ -53,7 +55,7 @@ thus "\c. (b, c) \ R \ (a, c) \ R\<^sup>*" using F1 by (metis transitive_closure_trans(6)) qed -lemma "\f c = Intg x; \y. f b = Intg y \ y \ x; (a, b) \ R\<^sup>*; (b, c) \ R\<^sup>*\ +lemma "\f c = Intg x; \y. f b = Intg y \ y \ x; (a, b) \ R\<^sup>*; (b, c) \ R\<^sup>*\ \ \c. (b, c) \ R \ (a, c) \ R\<^sup>*" apply (erule_tac x = b in converse_rtranclE) apply metis