src/FOL/cladata.ML
author oheimb
Wed Feb 25 20:29:58 1998 +0100 (1998-02-25)
changeset 4653 d60f76680bf4
parent 4466 305390f23734
child 5929 890f2f9b926d
permissions -rw-r--r--
renamed rep_claset to rep_cs
paulson@2469
     1
(*  Title:      FOL/cladata.ML
paulson@2469
     2
    ID:         $Id$
paulson@2469
     3
    Author:     Tobias Nipkow
paulson@2469
     4
    Copyright   1996  University of Cambridge
paulson@2469
     5
paulson@2469
     6
Setting up the classical reasoner 
paulson@2469
     7
*)
paulson@2469
     8
paulson@2469
     9
paulson@2469
    10
section "Classical Reasoner";
paulson@2469
    11
paulson@2844
    12
paulson@2469
    13
(*** Applying ClassicalFun to create a classical prover ***)
paulson@2469
    14
structure Classical_Data = 
paulson@2469
    15
  struct
paulson@2469
    16
  val sizef     = size_of_thm
paulson@2469
    17
  val mp        = mp
paulson@2469
    18
  val not_elim  = notE
paulson@2469
    19
  val classical = classical
paulson@2469
    20
  val hyp_subst_tacs=[hyp_subst_tac]
paulson@2469
    21
  end;
paulson@2469
    22
paulson@2469
    23
structure Cla = ClassicalFun(Classical_Data);
paulson@2469
    24
open Cla;
paulson@2469
    25
paulson@2844
    26
(*Better for fast_tac: needs no quantifier duplication!*)
paulson@2844
    27
qed_goal "alt_ex1E" IFOL.thy
wenzelm@3835
    28
    "[| EX! x. P(x);                                              \
paulson@2844
    29
\       !!x. [| P(x);  ALL y y'. P(y) & P(y') --> y=y' |] ==> R  \
paulson@2844
    30
\    |] ==> R"
paulson@2844
    31
 (fn major::prems =>
paulson@2844
    32
  [ (rtac (major RS ex1E) 1),
paulson@2844
    33
    (REPEAT (ares_tac (allI::prems) 1)),
paulson@2844
    34
    (etac (dup_elim allE) 1),
paulson@2844
    35
    (IntPr.fast_tac 1)]);
paulson@2844
    36
paulson@2844
    37
paulson@4305
    38
(*Propositional rules*)
paulson@2469
    39
val prop_cs = empty_cs addSIs [refl,TrueI,conjI,disjCI,impI,notI,iffI] 
paulson@4305
    40
                       addSEs [conjE,disjE,impCE,FalseE,iffCE];
paulson@2469
    41
paulson@2469
    42
(*Quantifier rules*)
paulson@2844
    43
val FOL_cs = prop_cs addSIs [allI,ex_ex1I] addIs [exI] 
paulson@2844
    44
                     addSEs [exE,alt_ex1E] addEs [allE];
paulson@2469
    45
wenzelm@4095
    46
claset_ref() := FOL_cs;
paulson@2469
    47
berghofe@3610
    48
paulson@2867
    49
(*** Applying BlastFun to create Blast_tac ***)
paulson@2867
    50
structure Blast_Data = 
paulson@2867
    51
  struct
paulson@2867
    52
  type claset	= Cla.claset
paulson@2867
    53
  val notE	= notE
paulson@2867
    54
  val ccontr	= ccontr
paulson@2867
    55
  val contr_tac = Cla.contr_tac
paulson@2867
    56
  val dup_intr	= Cla.dup_intr
paulson@4466
    57
  val hyp_subst_tac = Hypsubst.blast_hyp_subst_tac
paulson@2867
    58
  val claset	= Cla.claset
oheimb@4653
    59
  val rep_cs    = Cla.rep_cs
paulson@2867
    60
  end;
paulson@2867
    61
paulson@2867
    62
structure Blast = BlastFun(Blast_Data);
paulson@2867
    63
paulson@2867
    64
val Blast_tac = Blast.Blast_tac
paulson@2867
    65
and blast_tac = Blast.blast_tac;
paulson@2867
    66
paulson@2867
    67