6 Isar is already part of Isabelle (as of version Isabelle99, or later). The
7 \texttt{isabelle} binary provides option \texttt{-I} to run the Isar
8 interaction loop at startup, rather than the plain ML top-level. Thus the
9 quickest way to do anything with Isabelle/Isar is as follows:
11 isabelle -I HOL\medskip
12 \out{> Welcome to Isabelle/HOL (Isabelle99)}\medskip
14 constdefs foo :: nat "foo == 1";
15 lemma "0 < foo" by (simp add: foo_def);
18 Note that any Isabelle/Isar command may be retracted by \texttt{undo}.
20 Plain TTY-based interaction like this used to be quite feasible with
21 traditional tactic based theorem proving, but developing Isar documents
22 demands some better user-interface support. \emph{Proof~General}\index{Proof
23 General} of LFCS Edinburgh \cite{proofgeneral} offers a generic Emacs-based
24 environment for interactive theorem provers that does all the cut-and-paste
25 and forward-backward walk through the document in a very neat way. Note that
26 in Isabelle/Isar, the current position within a partial proof document is more
27 informative than the actual proof state. Thus Proof~General provides the
28 canonical working environment for Isabelle/Isar, both for getting acquainted
29 (e.g.\ by replaying existing Isar documents) and serious production work.
33 The easiest way to use Proof~General is to make it the default Isabelle user
34 interface. Just say something like this in your Isabelle settings file (cf.\
37 ISABELLE_INTERFACE=\$ISABELLE_HOME/contrib/ProofGeneral/isar/interface
38 PROOFGENERAL_OPTIONS=""
40 You may have to change \texttt{\$ISABELLE_HOME/contrib/ProofGeneral} to the
41 actual installation directory of Proof~General. Now the capital
42 \texttt{Isabelle} executable refers to the \texttt{ProofGeneral/isar}
43 interface. It's usage is as follows:
45 Usage: interface [OPTIONS] [FILES ...]
48 -l NAME logic image name (default $ISABELLE_LOGIC=HOL)
49 -p NAME Emacs program name (default xemacs)
50 -u BOOL use .emacs file (default false)
51 -w BOOL use window system (default true)
53 Starts Proof General for Isabelle/Isar with proof documents FILES
54 (default Scratch.thy).
56 Note that the defaults for these options may be overridden via the
57 \texttt{PROOFGENERAL_OPTIONS} setting. For example, GNU
58 Emacs\footnote{Version 20.x required.} with loading of the startup file
59 enabled may be configured as follows:\footnote{The interface disables
60 \texttt{.emacs} by default to ensure successful startup despite any strange
61 commands that tend to occur there.}
63 PROOFGENERAL_OPTIONS="-p emacs -u true"
66 With the proper Isabelle interface setup, Isar documents may now be edited by
67 visiting appropriate theory files, e.g.\
69 Isabelle \({\langle}isabellehome{\rangle}\)/src/HOL/Isar_examples/BasicLogic.thy
71 Users of XEmacs may note the tool bar for navigating forward and backward
72 through the text. Consult the Proof~General documentation \cite{proofgeneral}
73 for further basic commands, such as \texttt{c-c return} or \texttt{c-c u}.
76 \section{How to write Isar proofs anyway?}
78 This is one of the key questions, of course. Isar offers a rather different
79 approach to formal proof documents than plain old tactic scripts. Experienced
80 users of existing interactive theorem proving systems may have to learn
81 thinking different in order to make effective use of Isabelle/Isar. On the
82 other hand, Isabelle/Isar comes much closer to existing mathematical practice
83 of formal proof, so users with less experience in old-style tactical proving,
84 but a good understanding of mathematical proof might cope with Isar even
87 Unfortunately, there is no tutorial on Isabelle/Isar available yet. This
88 document really is a \emph{reference manual}. Nevertheless, we will give some
89 discussions of the general principles underlying Isar in
90 chapter~\ref{ch:basics}, and provide some clues of how these may be put into
91 practice. Some more background information on Isar is given in
92 \cite{Wenzel:1999:TPHOL}. Furthermore, there are several examples distributed
93 with Isabelle (see directory \texttt{HOL/Isar_examples}).
98 %%% TeX-master: "isar-ref"