src/HOL/Metis.thy
author blanchet
Thu Sep 11 18:54:36 2014 +0200 (2014-09-11)
changeset 58306 117ba6cbe414
parent 56946 10d9bd4ea94f
child 58818 ee85e7b82d00
permissions -rw-r--r--
renamed 'rep_datatype' to 'old_rep_datatype' (HOL)
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
blanchet@39946
    11
begin
blanchet@39946
    12
wenzelm@56281
    13
declare [[ML_print_depth = 0]]
wenzelm@48891
    14
ML_file "~~/src/Tools/Metis/metis.ML"
wenzelm@56281
    15
declare [[ML_print_depth = 10]]
wenzelm@48891
    16
blanchet@56946
    17
blanchet@45511
    18
subsection {* Literal selection and lambda-lifting helpers *}
blanchet@42349
    19
blanchet@42349
    20
definition select :: "'a \<Rightarrow> 'a" where
blanchet@54148
    21
"select = (\<lambda>x. x)"
blanchet@42349
    22
blanchet@42349
    23
lemma not_atomize: "(\<not> A \<Longrightarrow> False) \<equiv> Trueprop A"
blanchet@42349
    24
by (cut_tac atomize_not [of "\<not> A"]) simp
blanchet@42349
    25
blanchet@42349
    26
lemma atomize_not_select: "(A \<Longrightarrow> select False) \<equiv> Trueprop (\<not> A)"
blanchet@42349
    27
unfolding select_def by (rule atomize_not)
blanchet@42349
    28
blanchet@42349
    29
lemma not_atomize_select: "(\<not> A \<Longrightarrow> select False) \<equiv> Trueprop A"
blanchet@42349
    30
unfolding select_def by (rule not_atomize)
blanchet@42349
    31
blanchet@42349
    32
lemma select_FalseI: "False \<Longrightarrow> select False" by simp
blanchet@42349
    33
blanchet@45511
    34
definition lambda :: "'a \<Rightarrow> 'a" where
blanchet@54148
    35
"lambda = (\<lambda>x. x)"
blanchet@45511
    36
blanchet@45511
    37
lemma eq_lambdaI: "x \<equiv> y \<Longrightarrow> x \<equiv> lambda y"
blanchet@45511
    38
unfolding lambda_def by assumption
blanchet@45511
    39
blanchet@42349
    40
blanchet@42349
    41
subsection {* Metis package *}
blanchet@42349
    42
wenzelm@48891
    43
ML_file "Tools/Metis/metis_generate.ML"
wenzelm@48891
    44
ML_file "Tools/Metis/metis_reconstruct.ML"
wenzelm@48891
    45
ML_file "Tools/Metis/metis_tactic.ML"
blanchet@39980
    46
blanchet@44651
    47
setup {* Metis_Tactic.setup *}
blanchet@39946
    48
blanchet@56946
    49
hide_const (open) select fFalse fTrue fNot fComp fconj fdisj fimplies fAll fEx fequal lambda
blanchet@56946
    50
hide_fact (open) select_def not_atomize atomize_not_select not_atomize_select select_FalseI
blanchet@56946
    51
  fFalse_def fTrue_def fNot_def fconj_def fdisj_def fimplies_def fAll_def fEx_def fequal_def
blanchet@56946
    52
  fTrue_ne_fFalse fNot_table fconj_table fdisj_table fimplies_table fAll_table fEx_table
blanchet@56946
    53
  fequal_table fAll_table fEx_table fNot_law fComp_law fconj_laws fdisj_laws fimplies_laws
blanchet@56946
    54
  fequal_laws fAll_law fEx_law lambda_def eq_lambdaI
blanchet@45511
    55
blanchet@39946
    56
end