0
|
1 |
(* Title: 91/Modal/ROOT
|
|
2 |
ID: $Id$
|
|
3 |
Author: Martin Coen
|
|
4 |
Copyright 1991 University of Cambridge
|
|
5 |
*)
|
|
6 |
|
|
7 |
val banner = "Modal Logic (over LK)";
|
|
8 |
writeln banner;
|
|
9 |
|
72
|
10 |
set_loadpath [".", "../LK"];
|
|
11 |
|
0
|
12 |
use_thy "modal0";
|
|
13 |
|
|
14 |
structure Modal0_rls =
|
|
15 |
struct
|
|
16 |
|
|
17 |
val rewrite_rls = [Modal0.strimp_def,Modal0.streqv_def];
|
|
18 |
|
|
19 |
local
|
|
20 |
val iffR = prove_goal thy
|
|
21 |
"[| $H,P |- $E,Q,$F; $H,Q |- $E,P,$F |] ==> $H |- $E, P <-> Q, $F"
|
|
22 |
(fn prems=>
|
|
23 |
[ (rewrite_goals_tac [iff_def]),
|
|
24 |
(REPEAT (resolve_tac (prems@[conjR,impR]) 1)) ]);
|
|
25 |
|
|
26 |
val iffL = prove_goal thy
|
|
27 |
"[| $H,$G |- $E,P,Q; $H,Q,P,$G |- $E |] ==> $H, P <-> Q, $G |- $E"
|
|
28 |
(fn prems=>
|
|
29 |
[ rewrite_goals_tac [iff_def],
|
|
30 |
(REPEAT (resolve_tac (prems@[conjL,impL,basic]) 1)) ])
|
|
31 |
in
|
|
32 |
val safe_rls = [basic,conjL,conjR,disjL,disjR,impL,impR,notL,notR,iffL,iffR];
|
|
33 |
val unsafe_rls = [allR,exL];
|
|
34 |
val bound_rls = [allL,exR];
|
|
35 |
end
|
|
36 |
|
|
37 |
end;
|
|
38 |
|
|
39 |
use "prover.ML";
|
|
40 |
|
|
41 |
use_thy"T";
|
|
42 |
|
|
43 |
local open Modal0_rls T
|
|
44 |
in structure MP_Rule : MODAL_PROVER_RULE =
|
|
45 |
struct
|
|
46 |
val rewrite_rls = rewrite_rls
|
|
47 |
val safe_rls = safe_rls
|
|
48 |
val unsafe_rls = unsafe_rls @ [boxR,diaL]
|
|
49 |
val bound_rls = bound_rls @ [boxL,diaR]
|
|
50 |
val aside_rls = [lstar0,lstar1,lstar2,rstar0,rstar1,rstar2]
|
|
51 |
end
|
|
52 |
end;
|
|
53 |
structure T_Prover = Modal_ProverFun(MP_Rule);
|
|
54 |
|
|
55 |
use_thy"S4";
|
|
56 |
|
|
57 |
local open Modal0_rls S4
|
|
58 |
in structure MP_Rule : MODAL_PROVER_RULE =
|
|
59 |
struct
|
|
60 |
val rewrite_rls = rewrite_rls
|
|
61 |
val safe_rls = safe_rls
|
|
62 |
val unsafe_rls = unsafe_rls @ [boxR,diaL]
|
|
63 |
val bound_rls = bound_rls @ [boxL,diaR]
|
|
64 |
val aside_rls = [lstar0,lstar1,lstar2,rstar0,rstar1,rstar2]
|
|
65 |
end;
|
|
66 |
end;
|
|
67 |
structure S4_Prover = Modal_ProverFun(MP_Rule);
|
|
68 |
|
|
69 |
use_thy"S43";
|
|
70 |
|
|
71 |
local open Modal0_rls S43
|
|
72 |
in structure MP_Rule : MODAL_PROVER_RULE =
|
|
73 |
struct
|
|
74 |
val rewrite_rls = rewrite_rls
|
|
75 |
val safe_rls = safe_rls
|
|
76 |
val unsafe_rls = unsafe_rls @ [pi1,pi2]
|
|
77 |
val bound_rls = bound_rls @ [boxL,diaR]
|
|
78 |
val aside_rls = [lstar0,lstar1,lstar2,rstar0,rstar1,rstar2,S43pi0,S43pi1,S43pi2]
|
|
79 |
end;
|
|
80 |
end;
|
|
81 |
structure S43_Prover = Modal_ProverFun(MP_Rule);
|
|
82 |
|
|
83 |
val Modal_build_completed = (); (*indicate successful build*)
|
|
84 |
|
|
85 |
(*printing functions are inherited from LK*)
|