src/HOL/Metis.thy
author wenzelm
Thu Mar 15 22:08:53 2012 +0100 (2012-03-15)
changeset 46950 d0181abdbdac
parent 46641 8801a24f9e9a
child 47946 33afcfad3f8d
permissions -rw-r--r--
declare command keywords via theory header, including strict checking outside Pure;
blanchet@39946
     1
(*  Title:      HOL/Metis.thy
blanchet@39946
     2
    Author:     Lawrence C. Paulson, Cambridge University Computer Laboratory
blanchet@39946
     3
    Author:     Jia Meng, Cambridge University Computer Laboratory and NICTA
blanchet@39946
     4
    Author:     Jasmin Blanchette, TU Muenchen
blanchet@39946
     5
*)
blanchet@39946
     6
blanchet@39946
     7
header {* Metis Proof Method *}
blanchet@39946
     8
blanchet@39946
     9
theory Metis
blanchet@43085
    10
imports ATP
wenzelm@46950
    11
keywords "try0" :: diag
blanchet@39946
    12
uses "~~/src/Tools/Metis/metis.ML"
blanchet@46320
    13
     ("Tools/Metis/metis_generate.ML")
blanchet@39946
    14
     ("Tools/Metis/metis_reconstruct.ML")
blanchet@44651
    15
     ("Tools/Metis/metis_tactic.ML")
blanchet@46641
    16
     ("Tools/try0.ML")
blanchet@39946
    17
begin
blanchet@39946
    18
blanchet@45511
    19
subsection {* Literal selection and lambda-lifting helpers *}
blanchet@42349
    20
blanchet@42349
    21
definition select :: "'a \<Rightarrow> 'a" where
blanchet@42349
    22
[no_atp]: "select = (\<lambda>x. x)"
blanchet@42349
    23
blanchet@42349
    24
lemma not_atomize: "(\<not> A \<Longrightarrow> False) \<equiv> Trueprop A"
blanchet@42349
    25
by (cut_tac atomize_not [of "\<not> A"]) simp
blanchet@42349
    26
blanchet@42349
    27
lemma atomize_not_select: "(A \<Longrightarrow> select False) \<equiv> Trueprop (\<not> A)"
blanchet@42349
    28
unfolding select_def by (rule atomize_not)
blanchet@42349
    29
blanchet@42349
    30
lemma not_atomize_select: "(\<not> A \<Longrightarrow> select False) \<equiv> Trueprop A"
blanchet@42349
    31
unfolding select_def by (rule not_atomize)
blanchet@42349
    32
blanchet@42349
    33
lemma select_FalseI: "False \<Longrightarrow> select False" by simp
blanchet@42349
    34
blanchet@45511
    35
definition lambda :: "'a \<Rightarrow> 'a" where
blanchet@45511
    36
[no_atp]: "lambda = (\<lambda>x. x)"
blanchet@45511
    37
blanchet@45511
    38
lemma eq_lambdaI: "x \<equiv> y \<Longrightarrow> x \<equiv> lambda y"
blanchet@45511
    39
unfolding lambda_def by assumption
blanchet@45511
    40
blanchet@42349
    41
blanchet@42349
    42
subsection {* Metis package *}
blanchet@42349
    43
blanchet@46320
    44
use "Tools/Metis/metis_generate.ML"
blanchet@39946
    45
use "Tools/Metis/metis_reconstruct.ML"
blanchet@44651
    46
use "Tools/Metis/metis_tactic.ML"
blanchet@39980
    47
blanchet@44651
    48
setup {* Metis_Tactic.setup *}
blanchet@39946
    49
blanchet@45511
    50
hide_const (open) fFalse fTrue fNot fconj fdisj fimplies fequal select lambda
blanchet@41140
    51
hide_fact (open) fFalse_def fTrue_def fNot_def fconj_def fdisj_def fimplies_def
blanchet@42349
    52
    fequal_def select_def not_atomize atomize_not_select not_atomize_select
blanchet@45511
    53
    select_FalseI lambda_def eq_lambdaI
blanchet@45511
    54
blanchet@39953
    55
blanchet@46641
    56
subsection {* Try0 *}
blanchet@41042
    57
blanchet@46641
    58
use "Tools/try0.ML"
blanchet@41042
    59
blanchet@46641
    60
setup {* Try0.setup *}
blanchet@41042
    61
blanchet@39946
    62
end