author | nipkow |
Thu, 14 Sep 2000 17:46:00 +0200 | |
changeset 9957 | 78822f2d921f |
parent 9941 | fe05af7ec816 |
child 10223 | 31346d22bb54 |
permissions | -rw-r--r-- |
7897 | 1 |
|
7981 | 2 |
\chapter{Isabelle/Isar Quick Reference}\label{ap:refcard} |
7897 | 3 |
|
7974 | 4 |
\section{Proof commands} |
5 |
||
6 |
\subsection{Primitives and basic syntax} |
|
7 |
||
8 |
\begin{tabular}{ll} |
|
8511 | 9 |
$\FIX{\vec x}$ & augment context by $\All {\vec x} \Box$ \\ |
10 |
$\ASSUME{a}{\vec\phi}$ & augment context by $\vec\phi \Imp \Box$ \\ |
|
7974 | 11 |
$\THEN$ & indicate forward chaining \\ |
12 |
$\HAVE{a}{\phi}$ & prove local result \\ |
|
13 |
$\SHOW{a}{\phi}$ & prove local result, establishing some goal \\ |
|
14 |
$\PROOF{m@1}~\dots~\QED{m@2}$ & apply proof methods \\ |
|
15 |
$\BG~\dots~\EN$ & declare explicit blocks \\ |
|
8447 | 16 |
$\NEXT$ & switch implicit blocks \\ |
8511 | 17 |
$\NOTE{a}{\vec b}$ & reconsider facts \\ |
9695 | 18 |
$\LET{p = t}$ & \Text{abbreviate terms by higher-order matching} \\ |
7974 | 19 |
\end{tabular} |
20 |
||
21 |
\begin{matharray}{rcl} |
|
7987 | 22 |
theory{\dsh}stmt & = & \THEOREM{name}{prop} ~proof \\ |
23 |
& \Or & \LEMMA{name}{prop}~proof \\ |
|
7974 | 24 |
& \Or & \TYPES~\dots \Or \CONSTS~\dots \Or \DEFS~\dots \Or \dots \\[1ex] |
25 |
proof & = & \PROOF{method}~stmt^*~\QED{method} \\[1ex] |
|
26 |
stmt & = & \BG~stmt^*~\EN \\ |
|
8447 | 27 |
& \Or & \NEXT \\ |
7974 | 28 |
& \Or & \NOTE{name}{name^+} \\ |
29 |
& \Or & \LET{term = term} \\[0.5ex] |
|
30 |
& \Or & \FIX{var^+} \\ |
|
7987 | 31 |
& \Or & \ASSUME{name}{prop^+}\\ |
7974 | 32 |
& \Or & \THEN~goal{\dsh}stmt \\ |
33 |
& \Or & goal{\dsh}stmt \\ |
|
7987 | 34 |
goal{\dsh}stmt & = & \HAVE{name}{prop}~proof \\ |
35 |
& \Or & \SHOW{name}{prop}~proof \\ |
|
7974 | 36 |
\end{matharray} |
37 |
||
38 |
||
39 |
\subsection{Abbreviations and synonyms} |
|
40 |
||
41 |
\begin{matharray}{rcl} |
|
42 |
\BYY{m@1}{m@2} & \equiv & \PROOF{m@1}~\QED{m@2} \\ |
|
43 |
\DDOT & \equiv & \BY{rule} \\ |
|
8195 | 44 |
\DOT & \equiv & \BY{this} \\ |
7974 | 45 |
\HENCENAME & \equiv & \THEN~\HAVENAME \\ |
46 |
\THUSNAME & \equiv & \THEN~\SHOWNAME \\ |
|
8511 | 47 |
\FROM{\vec a} & \equiv & \NOTE{this}{\vec a}~\THEN \\ |
48 |
\WITH{\vec a} & \equiv & \FROM{\vec a~this} \\[1ex] |
|
7974 | 49 |
\FROM{this} & \equiv & \THEN \\ |
50 |
\FROM{this}~\HAVENAME & \equiv & \HENCENAME \\ |
|
51 |
\FROM{this}~\SHOWNAME & \equiv & \THUSNAME \\ |
|
52 |
\end{matharray} |
|
53 |
||
54 |
||
55 |
\subsection{Derived elements} |
|
56 |
||
57 |
\begin{matharray}{rcl} |
|
58 |
\ALSO@0 & \approx & \NOTE{calculation}{this} \\ |
|
59 |
\ALSO@{n+1} & \approx & \NOTE{calculation}{trans~[OF~calculation~this]} \\ |
|
8511 | 60 |
\FINALLY & \approx & \ALSO~\FROM{calculation} \\[0.5ex] |
8619 | 61 |
\MOREOVER & \approx & \NOTE{calculation}{calculation~this} \\ |
62 |
\ULTIMATELY & \approx & \MOREOVER~\FROM{calculation} \\[0.5ex] |
|
63 |
\PRESUME{a}{\vec\phi} & \approx & \ASSUME{a}{\vec\phi} \\ |
|
9695 | 64 |
% & & \Text{(permissive assumption)} \\ |
8619 | 65 |
\DEF{a}{x \equiv t} & \approx & \FIX{x}~\ASSUME{a}{x \equiv t} \\ |
9695 | 66 |
% & & \Text{(definitional assumption)} \\ |
8619 | 67 |
\OBTAIN{\vec x}{a}{\vec\phi} & \approx & \dots~\FIX{\vec x}~\ASSUME{a}{\vec\phi} \\ |
9695 | 68 |
% & & \Text{(generalized existence)} \\ |
8619 | 69 |
\CASE{c} & \approx & \FIX{\vec x}~\ASSUME{c}{\vec\phi} \\ |
9695 | 70 |
% & & \Text{(named context)} \\[0.5ex] |
8511 | 71 |
\SORRY & \approx & \BY{cheating} \\ |
7974 | 72 |
\end{matharray} |
73 |
||
74 |
||
75 |
\subsection{Diagnostic commands} |
|
76 |
||
77 |
\begin{matharray}{ll} |
|
9695 | 78 |
\isarkeyword{pr} & \Text{print current state} \\ |
79 |
\isarkeyword{thm}~\vec a & \Text{print theorems} \\ |
|
80 |
\isarkeyword{term}~t & \Text{print term} \\ |
|
81 |
\isarkeyword{prop}~\phi & \Text{print meta-level proposition} \\ |
|
82 |
\isarkeyword{typ}~\tau & \Text{print meta-level type} \\ |
|
7974 | 83 |
\end{matharray} |
84 |
||
85 |
||
86 |
\section{Proof methods} |
|
87 |
||
88 |
\begin{tabular}{ll} |
|
7976 | 89 |
\multicolumn{2}{l}{\textbf{Single steps (forward-chaining facts)}} \\[0.5ex] |
7987 | 90 |
$assumption$ & apply some assumption \\ |
8195 | 91 |
$this$ & apply current facts \\ |
8513 | 92 |
$rule~\vec a$ & apply some rule \\ |
7974 | 93 |
$rule$ & apply standard rule (default for $\PROOFNAME$) \\ |
8447 | 94 |
$contradiction$ & apply $\neg{}$ elimination rule (any order) \\ |
8547 | 95 |
$cases~t$ & case analysis (provides cases) \\ |
96 |
$induct~\vec x$ & proof by induction (provides cases) \\[2ex] |
|
7974 | 97 |
|
7976 | 98 |
\multicolumn{2}{l}{\textbf{Repeated steps (inserting facts)}} \\[0.5ex] |
9695 | 99 |
$-$ & \Text{no rules} \\ |
100 |
$intro~\vec a$ & \Text{introduction rules} \\ |
|
101 |
$intro_classes$ & \Text{class introduction rules} \\ |
|
102 |
$elim~\vec a$ & \Text{elimination rules} \\ |
|
103 |
$unfold~\vec a$ & \Text{definitions} \\[2ex] |
|
7974 | 104 |
|
105 |
\multicolumn{2}{l}{\textbf{Automated proof tools (inserting facts, or even prems!)}} \\[0.5ex] |
|
9603 | 106 |
$simp$, $simp_all$ & Simplifier (+ Splitter) \\ |
7987 | 107 |
$blast$, $fast$ & Classical Reasoner \\ |
9603 | 108 |
$auto$, $force$ & Simplifier + Classical Reasoner \\ |
7974 | 109 |
$arith$ & Arithmetic procedure \\ |
110 |
\end{tabular} |
|
111 |
||
112 |
||
113 |
\section{Attributes} |
|
114 |
||
115 |
\begin{tabular}{ll} |
|
9905 | 116 |
\multicolumn{2}{l}{\textbf{Operations}} \\[0.5ex] |
117 |
$OF~\vec a$ & rule applied to facts (skipping ``$_$'') \\ |
|
118 |
$of~\vec t$ & rule applied to terms (skipping ``$_$'') \\ |
|
119 |
$symmetric$ & resolution with symmetry of equality \\ |
|
120 |
$THEN~b$ & resolution with other rule \\ |
|
9941
fe05af7ec816
renamed atts: rulify to rule_format, elimify to elim_format;
wenzelm
parents:
9905
diff
changeset
|
121 |
$rule_format$ & result put into standard rule format \\ |
fe05af7ec816
renamed atts: rulify to rule_format, elimify to elim_format;
wenzelm
parents:
9905
diff
changeset
|
122 |
$elim_format$ & destruct rule turned into elimination rule format \\ |
9905 | 123 |
$standard$ & result put into standard form \\[1ex] |
7974 | 124 |
|
9905 | 125 |
\multicolumn{2}{l}{\textbf{Declarations}} \\[0.5ex] |
126 |
$simp$ & Simplifier rule \\ |
|
127 |
$intro$, $elim$, $dest$ & Classical Reasoner rule \\ |
|
128 |
$iff$ & Simplifier + Classical Reasoner rule \\ |
|
129 |
$split$ & case split rule \\ |
|
130 |
$trans$ & transitivity rule \\ |
|
7974 | 131 |
\end{tabular} |
132 |
||
8511 | 133 |
|
134 |
\section{Emulating tactic scripts} |
|
135 |
||
8547 | 136 |
\subsection{Commands} |
8511 | 137 |
|
138 |
\begin{tabular}{ll} |
|
8547 | 139 |
$\isarkeyword{apply}~(m)$ & apply proof method at initial position \\ |
140 |
$\isarkeyword{apply_end}~(m)$ & apply proof method near terminal position \\ |
|
9615 | 141 |
$\isarkeyword{done}$ & complete proof \\ |
8511 | 142 |
$\isarkeyword{defer}~n$ & move subgoal to end \\ |
143 |
$\isarkeyword{prefer}~n$ & move subgoal to beginning \\ |
|
144 |
$\isarkeyword{back}$ & backtrack last command \\ |
|
9615 | 145 |
$\isarkeyword{declare}$ & declare rules in current theory \\ |
8511 | 146 |
\end{tabular} |
147 |
||
8547 | 148 |
\subsection{Methods} |
8511 | 149 |
|
150 |
\begin{tabular}{ll} |
|
9615 | 151 |
$rule_tac~insts$ & resolution (with instantiation) \\ |
152 |
$erule_tac~insts$ & elim-resolution (with instantiation) \\ |
|
153 |
$drule_tac~insts$ & destruct-resolution (with instantiation) \\ |
|
154 |
$frule_tac~insts$ & forward-resolution (with instantiation) \\ |
|
155 |
$cut_tac~insts$ & insert facts (with instantiation) \\ |
|
156 |
$thin_tac~\phi$ & delete assumptions \\ |
|
157 |
$subgoal_tac~\phi$ & new claims \\ |
|
158 |
$rename_tac~\vec x$ & rename suffix of goal parameters \\ |
|
159 |
$rotate_tac~n$ & rotate assumptions of goal \\ |
|
160 |
$tactic~text$ & arbitrary ML tactic \\ |
|
8691 | 161 |
$case_tac~t$ & exhaustion (datatypes) \\ |
162 |
$induct_tac~\vec x$ & induction (datatypes) \\ |
|
9615 | 163 |
$ind_cases~t$ & exhaustion + simplification (inductive sets) \\ |
8511 | 164 |
\end{tabular} |
165 |
||
166 |
||
9615 | 167 |
%%% Local Variables: |
7897 | 168 |
%%% mode: latex |
169 |
%%% TeX-master: "isar-ref" |
|
9615 | 170 |
%%% End: |