From 57d183c7955fb54b3eb6dd431f5aec338131266b Mon Sep 17 00:00:00 2001 From: Josh Chen Date: Fri, 22 Feb 2019 23:45:50 +0100 Subject: Cleanups and reorganization --- Prod.thy | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'Prod.thy') diff --git a/Prod.thy b/Prod.thy index ff62ee6..059932c 100644 --- a/Prod.thy +++ b/Prod.thy @@ -70,23 +70,6 @@ lemmas Prod_comp [comp] = Prod_cmp Prod_uniq lemmas Prod_cong [cong] = Prod_form_eq Prod_intro_eq -section \Universal quantification\ - -text \ -It will often be useful to convert a proof goal asserting the inhabitation of a dependent product to one that instead uses Pure universal quantification. - -Method @{theory_text quantify_all} converts the goal -@{text "t: \x1: A1. ... \xn: An. B x1 ... xn"}, -where @{term B} is not a product, to -@{text "\x1 ... xn . \x1: A1; ...; xn: An\ \ ?b x1 ... xn: B x1 ... xn"}. - -Method @{theory_text "quantify k"} does the same, but only for the first k unknowns. -\ - -method quantify_all = (rule Prod_intro)+ -method_setup quantify = \repeat (fn ctxt => Method.rule_tac ctxt [@{thm Prod_intro}] [] 1)\ - - section \Function composition\ definition compose :: "[t, t, t] \ t" @@ -146,4 +129,21 @@ by (derive lems: assms cong) abbreviation id :: "t \ t" where "id A \ \x: A. x" + +section \Universal quantification\ + +text \ +It will often be useful to convert a proof goal asserting the inhabitation of a dependent product to one that instead uses Pure universal quantification. + +Method @{theory_text quantify_all} converts the goal +@{text "t: \x1: A1. ... \xn: An. B x1 ... xn"}, +where @{term B} is not a product, to +@{text "\x1 ... xn . \x1: A1; ...; xn: An\ \ ?b x1 ... xn: B x1 ... xn"}. + +Method @{theory_text "quantify k"} does the same, but only for the first k unknowns. +\ + +method quantify_all = (rule Prod_intro)+ +method_setup quantify = \repeat (fn ctxt => Method.rule_tac ctxt [@{thm Prod_intro}] [] 1)\ + end -- cgit v1.2.3