UserGuide.tex revision 3e0309de8bbb1588c0f976d6ce3f1e615d17da84
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\documentclass{article}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\usepackage[show]{ed} % set to hide for producing a released version
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\usepackage{alltt}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\usepackage{casl}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\usepackage{xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\usepackage{color}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\usepackage{url}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\usepackage{threeparttable,hhline}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\usepackage[pdfborder=0 0 0,bookmarks,
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskipdfauthor={Till Mossakowski, Christian Maeder, Mihai Codescu},
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskipdftitle={Hets User Guide}]
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski{hyperref} %% do not load more packages after this line!!
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\input{xy}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\xyoption{v2}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\QUERY}[1]%{}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski{\marginpar{\raggedright\hspace{0pt}\small #1\\~}}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\eat}[1]{}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newenvironment{EXAMPLE}[1][] {\par#1\begin{EXAMPLEFORMAT}\begin{ITEMS}}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski {\end{ITEMS}\end{EXAMPLEFORMAT}\par}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\IEXT}[1] {\\#1\I}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\IEND} {\I\END}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newenvironment{EXAMPLEFORMAT} {}{}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski%% Added by MB to have some extra vertical space after the ``main'' examples
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski%% following the points (and some others in the text):
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newenvironment{BIGEXAMPLE} {\begin{EXAMPLE}} {\end{EXAMPLE}\medskip}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newenvironment{DETAILS}[1][] {#1\begin{DETAILSFORMAT}}{\end{DETAILSFORMAT}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newenvironment{DETAILSFORMAT} {}{}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newenvironment{META}[1][] {#1\begin{METAFORMAT}}{\end{METAFORMAT}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newenvironment{METAFORMAT} {\medskip\vrule\hspace{1ex}\vrule\hspace{1ex}%
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \begin{minipage}{0.9\textwidth}\it}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski {\end{minipage}\par\medskip}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SLIDESMALL} {}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SLIDESONLY}[1] {}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski% SIMULATING SMALL-CAPS FOR BOLD, EMPH
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\normalTEXTSC}[2]{{#1\scriptsize#2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%% NOT \newcommand{\normalTEXTSC}[2]{{\normalsize#1\scriptsize#2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeTEXTSC} [2]{{\large #1\small #2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\LargeTEXTSC} [2]{{\Large #1\normalsize#2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\LARGETEXTSC} [2]{{\LARGE #1\large #2}}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\hugeTEXTSC} [2]{{\huge #1\Large #2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\HugeTEXTSC} [2]{{\Huge #1\LARGE #2}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%\newcommand {\CASL}{\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeCASL} {\largeTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\LargeCASL} {\LargeTEXTSC{C}{ASL}\xspace}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\LARGECASL} {\LARGETEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\hugeCASL} {\hugeTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\HugeCASL} {\HugeTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%\newcommand {\CoFI}{CoFI\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\MAYA}{\normalTEXTSC{M}{AYA}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeMAYA} {\largeTEXTSC{M}{AYA}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\Hets}{\normalTEXTSC{H}{ETS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeHets} {\largeTEXTSC{H}{ETS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\LARGEHets} {\LARGETEXTSC{H}{ETS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\Cats}{\normalTEXTSC{C}{ATS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeCats} {\largeTEXTSC{C}{ATS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\newcommand {\ELAN}{\normalTEXTSC{E}{LAN}\xspace}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\newcommand{\largeELAN} {\largeTEXTSC{E}{LAN}\xspace}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\newcommand {\HOL}{\normalTEXTSC{H}{OL}\xspace}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\newcommand{\largeHOL} {\largeTEXTSC{H}{OL}\xspace}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\Isabelle}{\normalTEXTSC{I}{SABELLE}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeIsabelle} {\largeTEXTSC{I}{SABELLE}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\SPASS}{\normalTEXTSC{S}{PASS}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\Horn}{\normalTEXTSC{H}{ORN}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%%%% Klaus macros
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\CASLDL}{\textmd{\textsc{Casl-DL}}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\Dolce}{\textmd{\textsc{Dolce}}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SHOIN}{$\mathcal{SHOIN}$(\textbf{D})\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SROIQ}{$\mathcal{SROIQ}$(\textbf{D})\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\DL}{DL\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%%%% end of Klaus macros
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%% Use \ELAN-\CASL, \HOL-\CASL, \Isabelle/\HOL
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\LCF}{LCF\xspace}
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\ASF}{ASF\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%\newcommand {\ASF}{\normalTEXTSC{A}{SF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%\newcommand{\largeASF} {\largeTEXTSC{A}{SF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SDF}{SDF\xspace}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski%%\newcommand {\SDF}{\normalTEXTSC{S}{DF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%%\newcommand{\largeSDF} {\largeTEXTSC{S}{DF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand {\ASFSDF}{\normalTEXTSC{A}{SF}+\normalTEXTSC{S}{DF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeASFSDF} {\largeTEXTSC{A}{SF}+\largeTEXTSC{S}{DF}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
f2d72b2254513ef810b0951f0b13a62c2921cb4dTill Mossakowski\newcommand {\HasCASL}{\normalTEXTSC{H}{AS}\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\largeHasCASL} {\largeTEXTSC{H}{AS}\largeTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%% Do NOT use \ASF+\SDF (it gives a superfluous space in the middle)
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\newcommand{\CCC}{CCC\xspace}
881ab7022a03f9a6fa697d3067d05d61844929cbChristian Maeder
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\CoCASL}{\normalTEXTSC{C}{O}\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\CspCASL}{\normalTEXTSC{C}{SP}-\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\Csp}{\normalTEXTSC{C}{SP}\xspace}
881ab7022a03f9a6fa697d3067d05d61844929cbChristian Maeder\newcommand{\CcsCASL}{CCS-\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\CASLLtl}{\normalTEXTSC{C}{ASL}-\normalTEXTSC{L}{TL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\CASLChart}{\normalTEXTSC{C}{ASL}-\normalTEXTSC{C}{HART}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\SBCASL}{\normalTEXTSC{S}{B}-\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\HetCASL}{\normalTEXTSC{H}{ET}\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\newcommand{\ModalCASL}{\normalTEXTSC{M}{odal}\normalTEXTSC{C}{ASL}\xspace}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{document}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski\title{{\bf \protect{\LARGEHets} User Guide}\\
376b6600e1ccebd180299471f732b008a96027d4Till Mossakowski-- Version 0.95 --}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\author{Till Mossakowski, Christian Maeder,
376b6600e1ccebd180299471f732b008a96027d4Till Mossakowski Mihai Codescu, Dominik L\"{u}cke\\[1em]
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiDFKI Lab Bremen, Bremen, Germany.\\[1em]
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiComments to: hets-users@informatik.uni-bremen.de \\
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski(the latter needs subscription to the mailing list)
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\maketitle
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\section{Introduction}
376b6600e1ccebd180299471f732b008a96027d4Till Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe central idea of the Heterogeneous Tool Set (\protect\Hets) is to
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiprovide a general framework for formal methods integration and proof
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskimanagement. One can think of \Hets acting like a motherboard where
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskidifferent expansion cards can be plugged in, the expansion cards here
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskibeing individual logics (with their analysis and proof tools) as well
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskias logic translations. Individual logics and their analysis and proof
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskitools can be plugged into the \Hets motherboard using an
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiobject-oriented interface based on institutions
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\cite{GoguenBurstall92}. The \Hets motherboard already has plugged in
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskia number of expansion cards (e.g., the theorem provers Isabelle, SPASS
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiand more, as well as model finders). Hence, a variety of tools is
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiavailable, without the need to hard-wire each tool to the logic at
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskihand.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{center}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \includegraphics[width=0.45\textwidth]{hets-motherboard}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\end{center}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\caption{The \Hets motherboard and some expansion cards}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\Hets supports a number of input languages directly, such as \CASL,
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiCommon Logic, OWL-DL, Haskell, and Maude. For heterogeneous
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskispecification, \Hets offers language heterogeneous \CASL.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHeterogeneous \CASL (\HetCASL) generalises the structuring
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiconstructs of
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CASL \cite{CASL-UM,CASL/RefManual} to arbitrary logics
f2d72b2254513ef810b0951f0b13a62c2921cb4dTill Mossakowski(if they are formalised as institutions and plugged into
881ab7022a03f9a6fa697d3067d05d61844929cbChristian Maederthe \Hets motherboard), as well as to heterogeneous
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskicombination of specification written in different logics.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till MossakowskiSee
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiFig.~\ref{fig:lang} for a simple subset of the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\HetCASL syntax, where \emph{basic specifications} are unstructured
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskispecifications or modules written in a specific logic. The graph of
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskicurrently supported logics and logic translations (the latter are also
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskicalled comorphisms) is shown in Fig.~\ref{fig:LogicGraph}, and the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskidegree of support by \Hets in Fig.~\ref{fig:Languages}.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{figure}[ht]
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\centering
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski{\small
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiSPEC ::= BASIC-SPEC
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | SPEC then SPEC
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | SPEC then %implies SPEC
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | SPEC with SYMBOL-MAP
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | SPEC with logic ID
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiDEFINITION ::= logic ID
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | spec ID = SPEC end
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | view ID : SPEC to SPEC = SYMBOL-MAP end
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski | view ID : SPEC to SPEC = with logic ID end
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiLIBRARY = DEFINITION*
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\end{verbatim}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\caption{Syntax of a simple subset of the heterogeneous
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskispecification language.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\texttt{BASIC-SPEC} and \texttt{SYMBOL-MAP} have a logic
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskispecific syntax, while \texttt{ID} stands for some form of
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiidentifiers.\label{fig:lang}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\end{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiWith \emph{heterogeneous structured specifications}, it is possible to
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskicombine and rename specifications, hide parts thereof, and also
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskitranslate them to other logics. \emph{Architectural specifications}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiprescribe the structure of implementations. \emph{Specification
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski libraries} are collections of named structured and architectural
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskispecifications.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\Hets consists of logic-specific tools for the parsing and static
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskianalysis of the different involved logics, as well as a
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskilogic-independent parsing and static analysis tool for structured and
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiarchitectural specifications and libraries. The latter of course needs
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskito call the logic-specific tools whenever a basic specification is
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiencountered.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\Hets is based on the theory of institutions \cite{GoguenBurstall92},
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiwhich formalize the notion of a logic. The theory behind \Hets is laid
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiout in \cite{Habil}. A short overview of \Hets is given in
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\cite{MossakowskiEA06,MossakowskiEtAl07b}.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\section{Logics supported by Hets}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiThe following list of logics (formalized as so-called institutions
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\cite{GoguenBurstall92}) is currently supported by \Hets:
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \begin{center}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \includegraphics[scale=0.4]{LogicGraph}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \end{center}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\caption{Graph of logics currently supported by \Hets. The more an
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiellipse is filled with green, the more stable is the implementation of the logic. Blue indicates a prover-supported logic.}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\label{fig:LogicGraph}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\end{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{figure}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{center}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\begin{tabular}{|l|c|c|c|}\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiLanguage & Parser & Static Analysis & Prover \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CASL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CoCASL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\ModalCASL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\HasCASL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiHaskell & (x) & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CspCASL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CspCASL\_Trace & - & - & x \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CspCASL\_Failure & - & - & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiConstraint\CASL & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiTemporal & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiRelScheme & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiDFOL & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiExtModal & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiLF & x & (x) & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski%Structured specifications & x & x & (x) \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski%Architectural specifications & x & x & -\\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CASLDL & x & - & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiDMU & x & - & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiOWL DL & x & x & - \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiPropositional & x & x & x \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiSoftFOL & x & - & x \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiMaude & x & x & - \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiVSE & x & x & x \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\Isabelle & (x) & - & x \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{tabular}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{center}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\caption{Current degree of \Hets support for the different languages.\label{fig:Languages}}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{figure}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{description}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item[CASL] extends many sorted first-order logic with partial
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski functions and subsorting. It also provides induction sentences,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski expressing the (free) generation of datatypes.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%It is mainly designed and used for the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%specification of requirements for software systems. But it is also
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski%used for the specification of \Dolce (Descriptive Ontology for
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski%Linguistic and Cognitive Engineering), an Upper Ontology for knowledge
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski%representation. \cite{Gangemi:2002:SOD} Further it is now used to
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski%specify calculi for time and space.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till MossakowskiFor more details on \CASL see \cite{CASL/RefManual,CASL-UM}.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski%
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiWe have implemented the \CASL logic in such a way that much of the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiimplementation can be re-used for \CASL extensions as well; this
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiis achieved via ``holes'' (realized via polymorphic variables) in the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskitypes for signatures, morphisms, abstract syntax etc. This eases
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiintegration of \CASL extensions and keeps the effort of integrating
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\CASL extensions quite moderate.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[CoCASL] \cite{MossakowskiEA04} is a coalgebraic extension of \CASL,
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskisuited for the specification of process types and reactive systems.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiThe central proof method is coinduction.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[ModalCASL] \cite{ModalCASL}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski is an extension of \CASL with multi-modalities and
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiterm modalities. It allows the specification of modal systems with
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiKripke's possible worlds semantics. It is also possible to express
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskicertain forms of dynamic logic.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[HasCASL] is a higher order extension of \CASL allowing
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski polymorphic datatypes and functions. It is closely related to the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski programming language Haskell and allows program constructs being
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski embedded in the specification.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski An overview of \HasCASL is given in \cite{Schroeder:2002:HIS};
7e7c1b5990145d02f8abb7c74d3c0d609735b54cTill Mossakowskithe language is summarized in \cite{HasCASL/Summary}, the semantics
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiin \cite{Schroder05b,Schroder-habil}.
7e7c1b5990145d02f8abb7c74d3c0d609735b54cTill Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[Haskell] is a modern, pure and strongly typed functional
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski programming language. It simultaneously is the implementation
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski language of \Hets, such that in the future, \Hets might be applied
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski to itself.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiThe definitive reference for Haskell is \cite{PeytonJones03},
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskisee also \url{www.haskell.org}.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[CspCASL] \cite{Roggenbach06} is a combination of \CASL
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski with the process algebra CSP.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[ConstraintCASL] is an experimental logic for the specification
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiof qualitative constraint calculi.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[OWL DL] is the Web Ontology Language (OWL) recommended by the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski World Wide Web Consortium (W3C, \url{http://www.w3c.org}). It is
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski used for knowledge representation and the Semantic Web
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \cite{berners:2001:SWeb}.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiHets calls an external OWL DL parser
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski written in JAVA to obtain the abstract syntax for an OWL file and its
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski imports. The JAVA parser is also doing a first analysis classifying
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski the OWL ontology into the sublanguages OWL Full, OWL DL and OWL
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski Lite.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski Hets only supports the last two, more restricted variants.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiThe
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski structuring of the OWL imports is displayed as Development Graph.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\item[CASL-DL] \cite{OWL-CASL-WADT2004}
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiis an extension of a restriction of \CASL, realizing
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskia strongly typed variant of OWL DL in \CASL syntax.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till MossakowskiIt extends
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski \CASL with cardinality restrictions for the description of sorts and
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski unary predicates. The restrictions are based on the equivalence
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski between \CASLDL, OWL~DL and \SHOIN. Compared to \CASL only unary
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski and binary predicates, predefined datatypes and concepts (subsorts
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski of the topsort Thing) are allowed. It is used to bring OWL DL and
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \CASL closer together.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski\item[Propositional] is classical propositional logic, with
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowskithe zChaff SAT solver \cite{Herbstritt03} connected to it.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[SoftFOL] \cite{LuettichEA06a} offers three automated theorem
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski proving (ATP) systems for first-order logic with equality: (1) \SPASS
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \cite{WeidenbachEtAl02}; (2) Vampire \cite{RiazanovV02}; and (3)
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski MathServe Broker\footnote{which chooses an appropriate ATP upon a
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski classification of the FOL problem} \cite{ZimmerAutexier06}.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski These together comprise some of the most advanced theorem provers
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski for first-order logic.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[\Isabelle] \cite{NipPauWen02} is an interactive theorem prover
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski for higher-order logic.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{description}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\ednote{TODO Till: update list}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiVarious logics are supported with proof tools. Proof support for the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiother logics can be obtained by using logic translations to a
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiprover-supported logic.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiAn introduction to \CASL can be found in the \CASL User Manual
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\cite{CASL-UM}; the detailed language reference is given in
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskithe \CASL Reference Manual \cite{CASL/RefManual}. These documents
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiexplain both the \CASL logic and language of basic specifications as
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwell as the logic-independent constructs for structured and
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiarchitectural specifications. The corresponding document explaining the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\HetCASL language constructs for \emph{heterogeneous} structured specifications
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiis the \HetCASL language summary \cite{Mossakowski04}; a formal
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskisemantics as well as a user manual with more examples are in preparation.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiSome of \HetCASL's heterogeneous constructs will be illustrated
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiin Sect.~\ref{sec:HetSpec} below.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\section{Logic translations supported
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiby Hets}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\label{comorphisms}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiLogic translations (formalized as institution comorphisms
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\cite{GoguenRosu02}) translate from a given source logic to a given
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskitarget logic. More precisely, one and the same logic translation
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskimay have several source and target \emph{sub}logics: for
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskieach source sublogic, the corresponding sublogic of the target
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic is indicated.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiA graph of the most important logics and sublogics, together with their
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskicomorphisms, is shown in Fig.~\ref{fig:SublogicGraph}.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{figure}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \begin{center}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \includegraphics[scale=0.4]{SublogicGraph}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \end{center}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\caption{Graph of most important sublogics currently supported by \Hets,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskitogether with their comorphisms.}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\label{fig:SublogicGraph}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{figure}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiIn more detail, the following list of logic translations is currently
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskisupported by \Hets:
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\ednote{TODO Mihai,Till: check VSE, Maude, DFOL descr. or ref.}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{tabular}{|l|p{8cm}|}\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiCASL2CoCASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiCASL2CspCASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiCASL2HasCASL & inclusion \\\hline
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiCASL2Isabelle & inclusion on sublogic CFOL=
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski(translation $(7)$ of \cite{Mossakowski02}) \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2Modal & inclusion \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiCASL2PCFOL & coding of subsorting (SubPCFOL=) by injections, see Chap.\ III:3.1 of the CASL Reference Manual \cite{CASL/RefManual} \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiCASL2PCFOLTopSort & coding of subsorting (SulPeCFOL=) by a top sort and unary
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek Makowskipredicates for the subsorts \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2Propositional & translation of propositional FOL \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2SoftFOL & coding of CASL.SuleCFOL=E to SoftFOL \cite{LuettichEA06a},
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek Makowskimapping types to soft types \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2SoftFOLInduction & same as CASL2SoftFOL but with instances of induction
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek Makowskiaxioms for all proof goals \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2SubCFOL & coding of partial functions by error elements
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek Makowski(translation $(4a')$ of \cite{Mossakowski02}, but extended to subsorting, i.e. sublogic SubPCFOL=) \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2VSE & inclusion on sublogic CFOL= \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2VSEImport & inclusion on sublogic CFOL= \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL2VSERefine & refining translation of CASL.CFOL= to VSE \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCASL\_DL2CASL & inclusion \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCoCASL2CoPCFOL & coding of subsorting by injections, similar to CASL2PCFOL \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCoCASL2CoSubCFOL & coding of partial functions by error supersorts, similar to CASL2SubCFOL \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCoCASL2Isabelle & extended translation similar to CASL2Isabelle \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCspCASL2CspCASL\_Failure & inclusion \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCspCASL2CspCASL\_Trace & inclusion \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiCspCASL2Modal & translating the CASL data part to ModalCASL \\\hline
f4dd7b59c284145a320a4b976312de41921d3f9eMaciek MakowskiDFOL2CASL & translating dependent types \\\hline
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiDMU2OWL & interpreting Catia output as OWL \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{tabular}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{tabular}{|l|p{7cm}|}\hline
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiHasCASL2HasCASLNoSubtypes & coding out subtypes \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHasCASL2HasCASLPrograms & coding of \HasCASL axiomatic recursive definitions
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskias \HasCASL recursive program definitions \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHasCASL2Haskell & translation of \HasCASL recursive program definitions to Haskell \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHasCASL2IsabelleOption & coding of HasCASL to Isabelle/HOL \cite{Groening05} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHaskell2Isabelle & coding of Haskell to Isabelle/HOL \cite{TorriniEtAl07} \\\hline
9101c1cc72e8daa5e9b56c7c9e841c377f98402eTill MossakowskiHaskell2IsabelleHOLCF & coding of Haskell to Isabelle/HOLCF \cite{TorriniEtAl07} \\\hline
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiMaude2CASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiModal2CASL & the standard translation of modal logic
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskito first-order logic \cite{blackburn_p-etal:2001a} \\\hline
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiOWL2CASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiPropositional2CASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiRelScheme2CASL & inclusion \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{tabular}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\section{Getting started}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe latest \Hets version can be obtained from the
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\Hets tools home page
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{quote}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\url{http://www.dfki.de/sks/hets}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{quote}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski Since \Hets is being
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiimproved constantly, it is recommended always to use the latest version.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\Hets currently is available (on Intel architectures only) for Linux, Solaris
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiand Mac OS-X.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiThere are three possibilities to install \Hets:
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{enumerate}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item
a8ce558d09f304be325dc89458c9504d3ff7fe80Till MossakowskiThe Java-based \Hets installer. Download a \texttt{.jar} file and
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskistart it with
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{quote}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskijava -jar \texttt{file.jar}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{quote}
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiNote that you need Sun Java 1.4.2 or later. On a Mac, you can just
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskidouble-click on the \texttt{.jar} file.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe installer will lead you through the installation with
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskia graphical interface. It will download and install further
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskisoftware (if not already installed on your computer):
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\medskip
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski{\small
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{tabular}{|l|l|p{5cm}|}\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiHets-lib & specification library & \url{http://www.cofi.info/Libraries}\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiuDraw(Graph) & graph drawing & \url{http://www.informatik.uni-bremen.de/uDrawGraph/en/}\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiTcl/Tk & graphics widget system & (version 8.4 or 8.5 must be installed before)\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\SPASS & theorem prover & \url{http://spass.mpi-sb.mpg.de/}\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiDarwin & theorem prover & should be installed manually from \url{http://combination.cs.uiowa.edu/Darwin/}\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\Isabelle & theorem prover & \url{http://www.cl.cam.ac.uk/Research/HVG/Isabelle/}\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski(X)Emacs & editor (for Isabelle) & (must be installed manually)\\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{tabular}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\medskip
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiIf you do not have Sun Java, you can just download the hets binary.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiYou have to unpack it with \texttt{bunzip2} and then put it at
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskisome place coverd by your \texttt{PATH}. You also have to
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowskiinstall the above mentioned software and set
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiseveral environment variables, as explained on the installation page.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
9101c1cc72e8daa5e9b56c7c9e841c377f98402eTill Mossakowski\item
9101c1cc72e8daa5e9b56c7c9e841c377f98402eTill MossakowskiYou may compile \Hets from the sources, please follow the
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskilink ``Hets: source code and information for developers''
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskion the \Hets web page, download the sources (as tarball or from
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskisvn), and follow the
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiinstructions in the \texttt{INSTALL} file, but be prepared to take some time.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{enumerate}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiDepending on your application further tools are supported and may be
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiinstalled in addition:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\medskip
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski{\small
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{tabular}{|l|l|p{5cm}|}\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskizChaff & SAT solver & \url{http://www.princeton.edu/~chaff/zchaff.html} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskiminisat & SAT solver & \url{http://minisat.se/} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiPellet & OWL reasoner & \url{http://clarkparsia.com/pellet/} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiE-KRHyper & theorem prover
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski & \url{http://userpages.uni-koblenz.de/~bpelzer/ekrhyper/} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiReduce & computer algebra system
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski & \url{http://www.reduce-algebra.com/} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiMaude & rewrite system & \url{http://maude.cs.uiuc.edu/} \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiVSE & theorem prover & (non-public) \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiTwelf & & \url{http://twelf.plparty.org/} \\\hline
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{tabular}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\ednote{TODO Mihai, Till, Luecke: check prover list}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\section{Analysis of Specifications}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiConsider the following \CASL
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskispecification:
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\medskip
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{BIGEXAMPLE}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\I\SPEC \NAME{Strict\_Partial\_Order} =
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski%%PDM\I{} \COMMENTENDLINE{Let's start with a simple example !}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{ITEMS}[\PRED]
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\SORT \( Elem \)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\PRED \( \_\_<\_\_ : Elem \* Elem \)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski% \COMMENTENDLINE{\PRED abbreviates predicate}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{ITEMS}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\(\[ \FORALL x,y,z : Elem \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. \NOT(x < x) \RIGHT{\LABEL{strict}} \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. x < y \IMPLIES \NOT(y < x) \RIGHT{\LABEL{asymmetric}} \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. x < y \A y < z \IMPLIES x < z \RIGHT{\LABEL{transitive}} \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\]\)
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{COMMENT}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiNote that there may exist \(x, y\) such that\\
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskineither \(x < y\) nor \(y < x\).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{COMMENT}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\I\END
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{BIGEXAMPLE}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\Hets can be used for parsing and
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskichecking static well-formedness of specifications.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \index{parsing}%
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \index{static!analysis}%
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \index{analysis, static}%
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiLet us assume that the example is in a file named
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{Order.casl} (actually, this file is provided
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwith the \Hets distribution as \texttt{Hets-lib/UserManual/Chapter3.casl}).
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThen you can check the well-formedness of the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispecification by typing (into some shell):
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{quote}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{hets Order.casl}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{quote}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\Hets checks both the correctness of this specification
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski with respect to the \CASL syntax, as
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwell as its correctness with respect to the static semantics (e.g.\
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwhether all identifiers have been declared before they are used,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwhether operators are applied to arguments of the correct sorts,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwhether the use of overloaded symbols is unambiguous, and so on).
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe following flags are available in this context:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{description}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[\texttt{-p}, \texttt{--just-parse}] Just do the parsing
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski -- the static analysis is skipped and no development is created.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[\texttt{-s}, \texttt{--just-structured}] Do the parsing and the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski static analysis of (heterogeneous) structured specifications, but
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski leave out the analysis of basic specifications. This can be used
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski for prototyping issues, namely to quickly produce a development graph
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski showing the dependencies among the specifications (cf.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski Sect.~\ref{sec:DevGraph}) even if the individual specifications are
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski not correct yet.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[\texttt{-L DIR}, \texttt{--hets-libdir=DIR}]
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiUse \texttt{DIR} as a colon separated list of directories for specification libraries (equivalently, you can set the variable \texttt{HETS\_LIB} before
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskicalling \Hets).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[\texttt{-a ANALYSIS}, \texttt{--casl-amalg=ANALYSIS}]
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski For the analysis of architectural specification (a quite advanced
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski feature of \CASL), the \texttt{ANALYSIS} argument specifies the options for
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski amalgamability checking
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski algorithm for \CASL logic; it is a comma-separated list of zero or
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski more of the following options:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \begin{description}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \item[\texttt{sharing}] perform sharing analysis for sorts,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski operations and predicates.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \item[\texttt{cell}] perform cell condition check; implies
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \texttt{sharing}. With this option on, the subsort embeddings are
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski analyzed.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \item[\texttt{colimit-thinness}] perform colimit thinness check;
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski implies \texttt{sharing}. The colimit thinness check is less
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski complete and usually takes longer than the full cell condition
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski check (\texttt{cell} option), but may prove more efficient in case
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski of certain specifications.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \end{description}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski If \texttt{ANALYSIS} is empty then amalgamability analysis for
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \CASL is skipped.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski The default value for \texttt{--casl-amalg} is
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski \texttt{cell}.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{description}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\section{Heterogeneous Specification} \label{sec:HetSpec}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\Hets accepts plain text input files with the following endings:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\\
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{tabular}{|l|c|c|}\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiEnding & default logic & structuring language\\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.casl} & \CASL & \CASL \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.het} & \CASL & \CASL \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.hs} & Haskell & Haskell\\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.owl} & OWL DL, OWL Lite & OWL\\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.elf} & LF & Twelf \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{.maude} & Maude & Maude \\\hline
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{tabular}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\medskip
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiFurthermore, \texttt{.xml} files are accepted as Catia output if the default
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic is set to DMU before a library import or by the ``\texttt{-l DMU}''
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskicommand line option of \Hets.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiAlthough the endings \texttt{.casl} and \texttt{.het} are
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiinterchangeable, the former should be used for libraries of
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskihomogeneous \CASL specifications and the latter for \HetCASL libraries
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiof heterogeneous specifications (that use the \CASL structuring
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiconstructs). Within a \HetCASL library, the current logic can be changed e.g.\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskito \HasCASL in the following way:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic HasCASL
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe subsequent specifications are then parsed and analysed as
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\HasCASL specifications. Within such specifications,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiit is possible to use references to named \CASL specifications;
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskithese are then automatically translated along the default
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiembedding of \CASL into \HasCASL (cf.\ Fig.~\ref{fig:LogicGraph}).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski(There are also heterogeneous constructs
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskifor explicit translations between logics, see \cite{Mossakowski04}.)
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\eat{
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiA \CspCASL specification consists of a \CASL specification
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskifor the data part and a \Csp process built over this data part.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiTherefore, \HetCASL provides a heterogeneous language construct
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{data} as follows:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilibrary Buffer
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic CASL
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispec List =
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski free type List[Elem] ::= nil | cons(Elem; List[Elem])
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski ops last: List -> ? Elem;
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski rest: List -> ? List
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiend
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic CspCASL
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispec Buffer =
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski data List
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski channel read, write : Elem
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski process Buf(List): read, write, List;
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski EmptyBuffer : read,write, List;
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski Buf(l)= read? x :: Elem -> Buf(cons(x,nil)) []
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski (if l=nil then STOP else
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski write!last(l) -> Buf(rest(l)))
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski EmptyBuffer = Buf(nil)
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiend
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiHere, the construct \texttt{data List} refers to the \CASL specification
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\texttt{List}, which is implicitly embedded into \CspCASL.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe ending \texttt{.hs} is available for directly reading in
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiHaskell programs % and HasSLe specifications,
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiand hence supports the Haskell module system.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiBy contrast, in \HetCASL libraries (ending with \texttt{.het}),
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskithe logic Haskell has to be chosen explicitly, and the \CASL structuring
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskisyntax needs to be used:
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilibrary Factorial
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskilogic Haskell
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispec Factorial =
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski{
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskifac :: Int -> Int
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskifac n = foldl (*) 1 [1..n]
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiend
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{verbatim}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiNote that according to the Haskell syntax, Haskell function
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskideclarations and definitions need to start with the first column of
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskithe text.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\section{Development Graphs}\label{sec:DevGraph}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiDevelopment graphs are a simple kernel formalism for (heterogeneous)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskistructured theorem proving and proof management.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiA development graph consists of a set of nodes (corresponding to whole
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskistructured specifications or parts thereof), and a set of arrows
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskicalled \emph{definition links}, indicating the dependency of each
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiinvolved structured specification on its subparts. Each node is
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiassociated with a signature and some set of local axioms. The axioms
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiof other nodes are inherited via definition links. Definition links
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiare usually drawn as black solid arrows, denoting an import of another
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskispecification.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiComplementary to definition links, which \emph{define} the theories of
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskirelated nodes, \emph{theorem links} serve for \emph{postulating}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskirelations between different theories. Theorem links are the central
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskidata structure to represent proof obligations arising in formal
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskidevelopments.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiTheorem links can be \emph{global} (drawn as solid arrows) or
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\emph{local} (drawn as dashed arrows): a global theorem link
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskipostulates that all axioms of the source node (including the inherited
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiones) hold in the target node, while a local theorem link only postulates
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskithat the local axioms of the source node hold in the target node.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiBoth definition and theorem links can be \emph{homogeneous},
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskii.e. stay within the same logic, or \emph{heterogeneous}, i.e.\ %% such that
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskithe logic changes along the arrow. Technically, this is the case
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskifor Grothendieck signature morphisms $(\rho,\sigma)$ where
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski$\rho\not=id$. This case is indicated with double arrows.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiTheorem links are initially displayed in red.
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till MossakowskiThe \emph{proof
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski calculus} for development graphs
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowski\cite{MossakowskiEtAl05,Habil} is given by rules
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskithat allow for proving global theorem links by decomposing them
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiinto simpler (local and global) ones. Theorem links that have been
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskiproved with this calculus are drawn in green. Local theorem links can
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskibe proved by turning them into \emph{local proof goals}. The latter
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskican be discharged using a logic-specific calculus as given by an
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskientailment system for a specific institution. Open local
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiproof goals are indicated by marking the corresponding node in the
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskidevelopment graph as red; if all local implications are proved, the
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskinode is turned into green. This implementation ultimately is based
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskion a theorem \cite{Habil} stating soundness and relative completeness
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiof the proof calculus for heterogeneous development graphs.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiDetails can be found in the \CASL Reference Manual \cite[IV:4]{CASL/RefManual}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiand in \cite{Habil,MossakowskiEtAl05,MossakowskiEtAl07b}.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiThe following options let \Hets show the development graph of
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskia specification library:
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{description}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[\texttt{-g}, \texttt{--gui}] Shows the development graph in a GUI window
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[\texttt{-u}, \texttt{--uncolored}] no colors in shown graphs
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{description}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiThe following additional options also apply typical rules from the development
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskigraph calculus to the final graph and save applying these rule via the GUI.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{description}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[\texttt{-A}, \texttt{--apply-automatic-rule}] apply the automatic
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski strategy to the development graph. This is what you usual want in order to
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski get goals within nodes for proving.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[\texttt{-N}, \texttt{--normal-form}] compute all normal forms for nodes
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski with incoming hiding links. (This may take long and may not be implemented
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski for all logics.)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{description}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\eat{
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiLet us extend the above library \texttt{Order.casl}. One use of the
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowskilibrary might be to express the fact that the natural numbers form a
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowskistrict partial order as a view, as follows:
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\medskip
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{BIGEXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\SPEC \NAMEREF{Natural} = ~\FREE \TYPE \(Nat ::= 0 \| suc(Nat)\)~\END
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{BIGEXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{EXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\SPEC \NAMEDEFN{Natural\_Order\_2} =
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\IEXT{\NAMEREF{Natural}} \THEN
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{ITEMS}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\PRED \( \_\_<\_\_ : Nat \* Nat\)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{ITEMS}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\(\[ \FORALL x,y:Nat \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. 0 < suc(x) \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. \neg x < 0 \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. suc(x) < suc(y) \IFF x < y
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\]\)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\END
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{EXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{EXAMPLE}%[\SLIDESMALL]
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\VIEW \NAMEDEFN{v1} ~:~ \NAMEREF{Strict\_Partial\_Order} \TO
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\NAMEREF{Natural\_Order\_2} =
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I{} \( Elem \MAPSTO Nat\)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\END
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{EXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiAgain, these specifications can be checked with \Hets. However, this
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskionly checks syntactic and static semantic well-formedness -- it is
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\emph{not} checked whether the predicate `$\_\_<\_\_$' introduced in
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\NAMEREF{Natural\_Order\_2} actually is constrained to be interpreted
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiby a strict partial ordering relation. Checking this requires theorem
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiproving, which will be discussed below.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiHowever, before coming to theorem proving, let us first inspect the
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiproof obligations arising from a specification. This can be done with:
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{quote}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\texttt{hets -g Order.casl}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{quote}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski(assuming that the above two specifications and the view
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskihave been added to the file
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\texttt{Order.casl}).
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\Hets now displays a so-called development graph
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski(which is just an overview graph showing the overall structure
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiof the specifications in the library), see Fig.~\ref{fig:dg0}.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{figure}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{center}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\includegraphics[scale=0.7]{dg-order-0}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{center}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\caption{Sample development graph.\label{fig:dg0}}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{figure}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiNodes in a development graph correspond to \CASL specifications.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiArrows show how specifications are related by the structuring
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiconstructs.
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiThe black arrow denotes an ordinary import of
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskispecifications (generated by the extension), while the red arrow
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskidenotes a proof obligation (corresponding to the view).
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiThis proof obligation needs to be discharged in order to
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskishow that the view is well-formed (then its color turns into green).
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiAs a more complex example, consider the following loose specification
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiof a sorting function, taken from the \CASL User Manual
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\cite{CASL-UM}, Chap.~6:
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{BIGEXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\SPEC \NAMEREF{List\_Order\_Sorted}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\\{} [\,\NAMEREF{Total\_Order} \WITH \SORT \(Elem\), \PRED \(\_\_<\_\_\)\,] =
e8f5a6ef56e210093ad852ed147d7f5f0a24cce9Till Mossakowski\IEXT{\NAMEREF{List\_Selectors} [\,\SORT \(Elem\)\,]} \THEN
e8f5a6ef56e210093ad852ed147d7f5f0a24cce9Till Mossakowski\begin{ITEMS}[\WITHIN]
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\LOCAL
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{ITEMS}[\PRED]
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\PRED \( \_\_is\_sorted : List \)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{ITEMS}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\(\[ \FORALL e,e': Elem; L : List \\
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski \. empty~is\_sorted \\
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski \. cons(e,empty)~is\_sorted \\
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski \. cons(e,cons(e',L))~is\_sorted \IFF
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\\\M (cons(e',L)~is\_sorted \A \NOT(e'<e)) \]\)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\WITHIN
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{ITEMS}[\OP]
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\OP \( order : List \TOTAL List \)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{ITEMS}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\( \FORALL L:List\. \[ order(L)~is\_sorted \]\)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{ITEMS}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\END
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{BIGEXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till MossakowskiThe following specification of sorting by insertion also is taken from
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowskithe \CASL User Manual \cite{CASL-UM}, Chap.~6:
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{BIGEXAMPLE}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\SPEC \NAMEREF{List\_Order}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski [\,\NAMEREF{Total\_Order} \WITH \SORT \(Elem\), \PRED \(\_\_<\_\_\)\,] =
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\phantomsection
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\IEXT{\NAMEREF{List\_Selectors} [\,\SORT \(Elem\)\,]} \THEN
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{ITEMS}[\WITHIN]
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\LOCAL
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{ITEMS}[\OP]
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\OP \( insert : Elem \* List \TOTAL List \)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\end{ITEMS}
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\(\[ \FORALL e,e':Elem; L:List \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. insert(e, empty) = cons(e, empty) \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. insert(e, cons(e',L)) = \[ cons(e', insert(e,L)) \WHEN e' < e\\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \ELSE cons(e, cons(e',L)) \] \\
a231094086321e19f9a689de4745512c91e00e4bTill Mossakowski\]\)
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\I\WITHIN
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski\begin{ITEMS}[\OP]
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\I\OP \( order : List \TOTAL List \)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\end{ITEMS}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\(\[ \FORALL e:Elem; L:List \\
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski \. order(empty) = empty \\
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowski \. order(cons(e,L)) = insert(e, order(L)) \]\)
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{ITEMS}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\I\END
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski\end{BIGEXAMPLE}
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski
47af295501ed5f407848f61b9943d58ccb43be29Till MossakowskiBoth specifications are related. To see this, we first inspect
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowskitheir signatures. This is possible with:
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski\begin{quote}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\texttt{hets -g Sorting.casl}
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski\end{quote}
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowskiassuming that \texttt{Sorting.casl} contains the above specifications.
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowski\Hets now displays a more complex development graph, see Fig.~\ref{fig:dg1}.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
47af295501ed5f407848f61b9943d58ccb43be29Till Mossakowski\begin{figure}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\begin{center}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\includegraphics[scale=0.7]{dg-order-1}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{center}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\caption{Development graph for the two sorting specifications.\label{fig:dg1}}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{figure}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiIn the above-mentioned development graph, we have two types of nodes.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe named ones correspond to named specifications, but there
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiare also unnamed nodes corresponding to anonymous basic
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispecifications like the declaration of the $insert$ operation in
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\NAMEREF{List\_Order} above. Basically, there is an
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiunnamed node for each structured specification that is not named.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiAgain, the black arrows denote an ordinary import of specifications
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski(corresponding to the extensions and unions in the
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskispecifications), while the blue arrows denote hiding (corresponding to
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskithe local specification).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiBy clicking on the nodes, one can inspect their signatures.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiIn this way, we can see that both \NAMEREF{List\_Order\_Sorted} and
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\NAMEREF{List\_Order} have the same signature. Hence, it
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiis legal to add a view:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{EXAMPLE}%[\SLIDESMALL]
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\I\VIEW \NAMEDEFN{v2}[\NAMEREF{Total\_Order}] ~:~ \NAMEREF{List\_Order\_Sorted}[\NAMEREF{Total\_Order}] \TO
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\NAMEREF{List\_Order}[\NAMEREF{Total\_Order}]
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\I\END
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\end{EXAMPLE}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiWe have already added this view to \texttt{Sorting.casl}.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThe corresponding
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiproof obligation between \NAMEREF{List\_Order\_Sorted} and
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\NAMEREF{List\_Order} is displayed in Fig.~\ref{fig:dg1}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski as a red arrow.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiHere is a summary of the types of nodes and links occurring in
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskidevelopment graphs:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\begin{description}
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Named nodes] correspond to a named specification.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Unnamed nodes] correspond to an anonymous specification.
376b6600e1ccebd180299471f732b008a96027d4Till Mossakowski\item[Elliptic nodes] correspond to a specification in the current library.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Rectangular nodes] are external nodes corresponding to a specification
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski downloaded from another library.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Red nodes] have open proof obligations.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item[Yellow nodes] have an open conservativity proof obligations.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Green nodes] have all proof obligations resolved.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Black links] correspond to reference to other specifications (definition
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski links in the sense of \cite[IV:4]{CASL/RefManual}).
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Red links] correspond to open proof obligations (theorem links).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Green links] correspond to proven theorem links.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item[Yellow links] correspond to proven theorem links with open
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski conservativity or to open hiding theorem links.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Blue links] correspond to hiding, free, or cofree definition links.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Violett links] correspond to a mixture of links becoming visible after
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski ``expand'' or ``Show unnamed nodes with open proofs''.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Solid links] correspond to global (definition or theorem)
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskilinks in the sense of \cite[IV:4]{CASL/RefManual}.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item[Dashed links] correspond to local (theorem) links in the sense of
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski \cite[IV:4]{CASL/RefManual}. These are usually created after
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski ``Global-Decomposition'' or only be visible after ``Show newly added proven
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski edges''.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Single line links] have homogeneous signature morphisms (staying within
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski one and the same logic).
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\item[Double line links] have heterogeneous signature morphisms (moving
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski between logics).
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski\end{description}
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowski
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiWe now explain the menus of the development graph window.
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill MossakowskiMost of the pull-down menus of the window are uDraw(Graph)-specific
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskilayout menus;
38a46398edcd7ad7d1777ae646d4cc484cce49bfTill Mossakowskitheir function can be looked up in the uDraw(Graph) documentation\footnote{see
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\url{http://www.informatik.uni-bremen.de/uDrawGraph/en/service/uDG31\_doc/}.}.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiThe exception is the Edit menu. Moreover, the nodes and links
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiof the graph have attached pop-up menus, which appear when
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiclicking with the right mouse button.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\ednote{TODO Mihai: update}\\
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{description}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Edit] This menu has the following submenus:
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\begin{description}
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Undo] Undo the last development graph proof step (see under Proofs)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Redo] Restore the last undone development graph proof step (see
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski under Proofs)
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski\item[Hide/show names/nodes/edges]
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiThe ``Hide/show names/nodes/edges'' menu is a toggle:
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiyou can switch on or off the display of node names, unnamed nodes or
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiproven theorem links.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiWith the ``Hide/show internal node names'' option, the nodes that
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiare initially unnamed get names that
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiare derived from named neighbour nodes.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiWith the ``Hide/show unnamed nodes'' option, it is possible
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskito reveal the unnamed nodes which do not have open proof goals.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiInitially, the complexity of the graph is reduced by hiding all these nodes;
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskionly nodes corresponding to named specifications are displayed.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill MossakowskiPaths between named nodes going through unnamed nodes
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiare displayed as edges; these paths are then expanded when showing the
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowskiunnamed nodes.
9cb7b59cc1442c507b0eac2a795d68b5571788eaTill Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiWhen applying the development graph calculus rules, theorem links that have
a8ce558d09f304be325dc89458c9504d3ff7fe80Till Mossakowskibeen proven are removed from the graph. With the ``Hide/Show newly added
d3f2015ae170a15e5b57d4880ded53073d725ac0Till Mossakowskiproven edges'' option, it is possible to re-display these links; they are marked
91dd24480df03b2cca7c1645bb2866d7000dfdb1Till Mossakowskias proven in the link info (see \emph{Pop-up menu for links}, below).
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski\item[Focus node]
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiThis menu is particularly useful when navigating a large development graph,
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskiwhich does not fit on a single screen. The list of all nodes is displayed:
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowskithe nodes are identified by the internal node number and the internal node name.
5277e290ad70afdf97f359019afd8fb5816f4102Till MossakowskiOnce a node is selected, the view centers on it.
5277e290ad70afdf97f359019afd8fb5816f4102Till Mossakowski
\item[Select Linktypes]
This menu allows to select the type of links that are displayed in the
development graph. A selection window appears, where links are grouped into
three categories: definition links, proven theorem links and unproven
theorem links. It is possible to select/deselect all links or to invert the
current selection.
\item[Consistency checker]
Checks whether the theories of the nodes of the graph are consistent
i.e. have a model. The model finders currently interfaced are
Isabelle-refute, darwin and E-KRHyper.
\item[Proofs] This menu allows to apply some of the deduction rules
for development graphs, see Sect. IV:4.4 of the \CASL Reference
Manual \cite{CASL/RefManual} or one of
\cite{Habil,MossakowskiEtAl05,MossakowskiEtAl07b}. While support for
local and global (definition or theorem) links is stable, support
for hiding links and checking conservativity is still experimental.
In most cases, it is advisable to use ``Automatic'', which
automatically applies the rules in the correct order. As a result,
the the open theorem links (marked in red) will be reduced to local
proof goals, that is, they become green, and instead, some of the
node will get red, indicating open local proof goals.
Besides the deduction rules, the menu contains entries for computing
a colimit approximation for the development graph and for
computing normal forms of all nodes (needed when dealing with hiding).
Also, a \CASL-specific normalisation of free links has been
implemented.
\item[Dump Development Graph] This option is available for
debugging purposes and it prints at the command line informations
about the content of the development graph.
\item[Show Library Graph] This menu displays the library graph, in a separate
window, if the library graph window has been closed after \Hets has been
called.
\item[Save Graph for uDrawGraph] Saves the development graph in a .udg file
which can be later read by uDrawGraph.
\item[Save proof-script] This menu saves the proof rules that have been applied
to the current development graph in a .hpf file which can be later read by
\Hets and thus the action performed on the graph are saved.
\end{description}
\item[Pop-up menu for nodes]
Here, the number of submenus depends on the type of the node:
\begin{description}
\item[Show node info] Shows the local informations of the node: the internal
node name and node number, the xpath \ednote{what is this?}, informations
about consistency of the node, origin of the node and the local theory
i.e. axioms declared locally.
\item[Show theory] Shows the theory of the node (including axioms
imported from other nodes). Notice that axioms imported via hiding links
are not part of the theory; they can be made visible only by re-adding
the hidden symbols, using the normal form of the node, by calling
\emph{Proofs/Compute Normal Form}. For such nodes, a warning is displayed.
\item[Translate theory] Translates the theory of a node to another logic.
A menu with the possible translation paths will be displayed.
\item[Taxonomy graphs] (Only available for some logics) Shows the subsort graph
of the signature of the node.
\item[Show proof status] Show open and proven local proof goals.
\item[Prove] Try to prove the local proof goals. See Section~\ref{sec:Proofs}
for details.
\item[Prove VSE structured] (see \ref{subsec:VSE})
\item[Check conservativity] Checks conservativity of the inclusion
morphism from the empty theory to the theory of the node (see
{\bf Check conervativity} for edges).
\end{description}
For the nodes which are references to specifications from an external library,
the pop-up menu options are reduced to {\bf Show node info, Show theory,
Show proof status} and {\bf Prove} and moroever, the option {\bf Show
referenced library} is added: on selection, it displays in a new window
the development graph of the external library from which the specification has
been downloaded.
\item[Pop-up menu for links]
Again, the number of submenus depends on the type of the link:
\begin{description}
\item[Show info] Shows informations about the edge: internal number and
internal nodes it links, the link type and origin and the
signature morphism of the link. The latter consists
of two components: a logic translation and a signature morphism in the
target logic of the logic translation.
In the (most frequent) case
of an intra-logic signature morphism, the logic translation component is
just the identity.
\item[Check conservativity] (Experimental) Check whether the
theory of the target node of the link
is a conservative extension of the theory of the source node.
\item[Expand]This menu is available only for paths going through unnamed
nodes which are not displayed and it expands the path to the links forming it.
\end{description}
\end{description}
Besides development graphs there are library graph windows displaying the
library hierarchy. The Edit menu has the following submenus:
\begin{description}
\item[Edit] This menu for library graphs has the following submenus:
\begin{description}
\item[Reload Library] Reloads all \HetCASL sources in order to avoid closing
and restarting the application after sources have changed. However, all
previous proof steps will be lost, therefore you have to confirm this
action. (A change management tool to keep proofs is in preparation.)
\item[Translate Library] Translates a library along a comorphism to be chosen.
This only works for a homogeneous library hierarchy. A finer grained
alternative is to use ``Translate theory'' for individual nodes. The
original state and proof steps will be lost, therefore you have to confirm
this action.
\item[Show Logic Graph] Shows the graph of logics and logic comorphisms
currently supported by \Hets. The Edit menu of a logic graph window has the
following submenu:
\begin{description}
\item[Show detailed logic graph] Shows the important sublogics and comorphims
between them, i.e. translation (blue links) and inclusion (black links).
\end{description}
\end{description}
\end{description}
\section{Reading, Writing and Formatting}
\Hets provides several options controlling the types of files
that are read and written.
\begin{description}
\item[\texttt{-i ITYPE}, \texttt{--input-type=ITYPE}] Specify \texttt{ITYPE}
as explicit type of the input file. By default \texttt{env}, \texttt{casl},
or \texttt{het} extensions are tried in this order. An \texttt{env} file
contains a shared ATerm of a development graph, whereas \texttt{casl} or
\texttt{het} files contain plain \HetCASL text. An \texttt{env} file will
always be read if it exists and is consistent (aka newer) than the
corresponding \HetCASL file.
\texttt{exp} files contain a development graph in a new experimental omdoc
format. \texttt{prf} files contain additional development steps (as shared
ATerms) to be applied on top of an underlying development graph created from
a corresponding \texttt{env}, \texttt{casl}, or \texttt{het}
file. \texttt{hpf} files are plain text files representing heterogeneous
proof scripts. The contents of a \texttt{hpf} file must be valid input for
\Hets in interactive mode. (\texttt{gen\_trm} formats are currently not
supported.)
The possible input types are:
\begin{verbatim}
casl|het|owl|hs|exp|maude|elf|prf
|omdoc|hpf|[tree.]gen_trm[.baf]
\end{verbatim}
\item[\texttt{-O DIR}, \texttt{--output-dir=DIR}]
Specify \texttt{DIR} as destination directory for output files.
\item[\texttt{-o OTYPES}, \texttt{--output-types=OTYPES}]
\texttt{OTYPES} is a comma separated list of output types:
\begin{verbatim}
prf
| env
| owl
| omdoc
| xml
| exp
| hs
| thy
| comptable.xml
| (sig|th)[.delta]
| pp.(het|tex|xml)
| graph.(exp.dot|dot)
| dfg[.c]
| tptp[.c]
\end{verbatim}
The \texttt{env} and \texttt{prf} formats are for subsequent reading,
avoiding the need to re-analyse downloaded libraries. \texttt{prf} files
can also be stored or loaded via the GUI's File menu.
The \texttt{owl} option \cite{books/sp/Kohlhase06} will produce OWL files in
Manchester Syntax for each specification of a structured OWL library.
The \texttt{omdoc} format \cite{books/sp/Kohlhase06} is an XML-based
markup format and data model for Open Mathematical Documents. It
serves as semantics-oriented representation format and ontology
language for mathematical knowledge. Currently, \CASL specifications
can be output in this format; support for further logics is planned.
The \texttt{xml} option will produce an XML-version of the development graph
for our change management broker.
The \texttt{exp} format is the new experimental omdoc format.
The \texttt{hs} format is used for Haskell modules. Executable \CASL or
\HasCASL specifications can be translated to Haskell.
When the \texttt{thy} format is selected, \Hets will try to translate
each specification in the library to \Isabelle, and write one \Isabelle
\texttt{.thy} file per specification.
When the \texttt{comptable.xml} format is selected, \Hets will extract
the composition and inverse table of a Tarskian relation algebra from
specification(s) (selected with the \texttt{-n} or \texttt{--spec}
option). It is assumed that the relation algebra is
generated by basic relations, and that the specification is written
in the \CASL logic. A sample specification of a relation
algebra can be found in the \Hets library \texttt{Calculi/Space/RCC8.het},
available from \texttt{www.cofi.info/Libraries}.
The output format is XML, the URL of the DTD is included in the
XML file.
The \texttt{sig} or \texttt{th} option will create \HetCASL signature or
theory files for each development graph node. (The \texttt{.delta} extension
is not supported, yet.)
The \texttt{pp} format is for pretty printing, either as plain text
(\texttt{het}), \LaTeX input (\texttt{tex}) or XML (\texttt{xml}).
For example, it is possible to generate a pretty
printed \LaTeX\ version of \texttt{Order.casl} by typing:
\begin{quote}
\texttt{hets -v2 -o pp.tex Order.casl}
\end{quote}
This will generate a file \texttt{Order.pp.tex}. It can be included
into \LaTeX\ documents, provided that the style \texttt{hetcasl.sty}
coming with the \Hets distribution (\texttt{LaTeX/hetcasl.sty}) is used.
The format \texttt{pp.xml} represents a library in XML for our change
management broker.
Formats with \texttt{graph} are for future usage.
The \texttt{dfg} format is used by the \SPASS theorem prover
\cite{WeidenbachEtAl02}.
The \texttt{tptp} format (\url{http://www.tptp.org}) is a standard
format for first-order theorem provers.
Appending \texttt{.c} to \texttt{dfg} or \texttt{tptp} will create files for
consistency checks by SPASS or Darwin respectively.
For all output formats it is recommended to increase the verbosity to at least
level 2 (by using the option \texttt{-v2}) to get feedback which files are
actually written. (\texttt{-v2} also shows which files are read.)
\item[\texttt{-t TRANS}, \texttt{--translation=TRANS}]
chooses a translation option. \texttt{TRANS} is a colon-separated list
without blanks of one or more comorphism names (see Sect.~\ref{comorphisms}).
\item[\texttt{-n SPECS}, \texttt{--spec=SPECS}]
chooses a list of named specifications for processing
\item[\texttt{-R}, \texttt{--recursive}] output also imported libraries.
\item[\texttt{-I}, \texttt{--interactive}] run \Hets in interactive mode
\item[\texttt{-x}, \texttt{--xml}] use xml-pgip packets to communicate with
\Hets in interactive mode
\item[\texttt{-S PORT}, \texttt{--listen=PORT}] communicate
with \Hets in interactive mode vy listining to the port \texttt{PORT}
\item[\texttt{-c HOSTNAME:PORT}, \texttt{--connect=HOSTNAME:PORT}] communicate
with \Hets in interactive mode via connecting to the port on host
\texttt{HOSTNAME}
\item[\texttt{-d STRING}, \texttt{--dump=STRING}] produces implementation
dependent output for debugging purposes only
\end{description}
\section{Miscellaneous Options}
\begin{description}
\item[\texttt{-v[Int]}, \texttt{--verbose[=Int]}]
Set the verbosity level according to \texttt{Int}. Default is 1.
\item[\texttt{-q}, \texttt{--quiet}]
Be quiet -- no diagnostic output at all. Overrides -v.
\item[\texttt{-V}, \texttt{--version}] Print version number and exit.
\item[\texttt{-h}, \texttt{--help}, \texttt{--usage}]
Print usage information and exit.
\item[\texttt{+RTS -KIntM -RTS}] Increase the stack size to
\texttt{Int} megabytes (needed in case of a stack overflow).
This must be the first option.
\item[\texttt{-l LOGIC}, \texttt{--logic=LOGIC}] chooses the initial logic, which is used for processing the specifications before the first \textbf{logic L}
declaration. The default is \CASL.
\item[\texttt{-m FILE}, \texttt{--modelSparQ=FILE}] model check a qualitative calculus given in SparQ lisp notation \cite{SparQ06} against a \CASL specification
\end{description}
\section{Proofs with \Hets}\label{sec:Proofs}
The proof calculus for development graphs (Sect.~\ref{sec:DevGraph}) reduces
global theorem links to local proof goals. Local proof goals (indicated by red
nodes in the development graph) can be eventually discharged using a theorem
prover, i.e. by using the ``Prove'' menu of a red node.
The graphical user interface (GUI) for calling a prover is shown in
Fig. \ref{fig:proof_window} --- we call it ``Proof Management GUI''.
(This GUI looks slightly different, if hets was not build with GTK support as
for example under solaris.)
The top list on the left shows all goal names prefixed with the proof
status in square brackets. A proved goal is indicated by a `+', a `-'
indicates a disproved goal, a space denotes an open goal, and a
`$\times$' denotes an inconsistent specification (aka a fallen `+';
see below for details).
\begin{figure}
\centering
\includegraphics[width=\textwidth]{proofmanagement1}
\caption{Hets Goal and Prover Interface\label{fig:proof_window}}
\end{figure}
If you open this GUI when processing the goals of one node for the
first time, it will show all goals as open. Within this list you can
select those goals that should be inspected or proved. The GUI elements are the following:
\begin{itemize}
\item The top-right button `Disprove' is supposed to prove the negation of a
selected goal, but this functionality is not implemented yet.
\item The button `Display' shows the selected goals in the ASCII syntax of
this theory's logic in a separate window.
\item By pressing the `Proof details' button a window is opened where for each
proved goal the used axioms, its proof script, and its proof are shown ---
the level of detail depends on the used theorem prover.
\item With the `Prove' button the actual prover is launched. This is described
in more detail in the paragraphs below.
\item The list `Pick Theorem Prover:' lets you choose one of the connected
provers (among them \Isabelle, MathServe Broker, \SPASS, Vampire, and
zChaff, described below). By pressing `Prove' the selected prover is
launched and the theory along with the selected goals is translated via the
shortest possible path of comorphisms into the provers logic.
\item The pop-up choice box below `Selected comorphism path:' lets you pick a
(composed) comorphism to be used for the chosen prover.
\item Since the amount and kind of sentences sent to an ATP system is a major
factor for the performance of the ATP system, it is possible to select in
the bottom lists the axioms and proven theorems that will comprise the
theory of the next proof attempt. Based on this selection the sublogic may
vary and also the available provers and comorphisms to provers. Former
theorems that are imported from other specifications are marked with the
prefix `(Th)'. Since former theorems do not add additional logical content,
they may be safely removed from the theory.
\item If you press the bottom-right `Close' button the window is closed and
the status of the goals' list is integrated into the development graph. If
all goals have been proved, the selected node turns from red into green.
\item All other buttons control selecting list entries
\end{itemize}
\subsection{Consistency Checker}
\label{sec:CC}
Since proofs are void if specifications are inconsistent, the consistency
should be checked (if possible for the given logic) by the ``Consistency
checker'' shown in Fig. \ref{fig:cons_window}. This GUI is invoked from
the `Edit' menu as it operates on all nodes. (Without GTK support this GUI is
missing, though.)
The list on the left shows all node names prefixed with a consistency status
in square brackets that is initially empty. A consistent node is indicated by
a `+', a `-' indicates an inconsistent node, a `t' denotes a timeout of the last
checking attempt.
\begin{figure}
\centering
\includegraphics[width=\textwidth]{ConsistencyChecker}
\caption{Hets Consistency Checker Interface\label{fig:cons_window}}
\end{figure}
For some selection of nodes (of a common logic) a model finder should be
selectable from the `Pick Model finder:' list. Currently only for ``darwin''
some \CASL models can be re-constructed. When pressing `Check', possibly after
`Select comorphism path:', all selected nodes will be checked, spending at
most the number of seconds given under `Timeout:' on each node. Pressing
`Stop' allows to terminate this process if too many nodes have been chosen.
Either by `View results' or automatically the `Results of consistency check'
(Fig. \ref{fig:cons_res}) will pop up and allow you to inspect the models for
nodes, if they could be constructed.
\begin{figure}
\centering
\includegraphics[width=\textwidth]{ConsCheckResults}
\caption{Consistency Checker Results\label{fig:cons_res}}
\end{figure}
\subsection[Automated Theorem Proving Systems]
{Automated Theorem Proving Systems\\(Logic SoftFOL)}
\label{sec:ATP}
\begin{figure}
\centering
\includegraphics[width=\textwidth]{spassGUI1}
\caption{Interface of the \SPASS prover\label{fig:SPASS_GUI}}
\end{figure}
All ATPs integrated into \Hets share the same GUI, with only a slight
modification for the MathServe Broker: the input field for extra options is
inactive. Figure~\ref{fig:SPASS_GUI} shows the instantiation for \SPASS, where
in the top right part of the window the batch mode can be controlled. The
left side shows the list of goals (with status indicators). If goals are
timed out (indicated by `t') is may help to activate the check box `Include
preceeding proven theorems in next proof attempt' and pressing `Prove all'
again.
On the bottom right the result of the last proof
attempt is displayed. The `Status:' indicates `Open', `Proved', `Disproved',
`Open (Time is up!)', or `Proved (Theory inconsistent!)'. The list of `Used
Axioms:' is filled by \SPASS. The button `Show Details' shows the whole output
of the ATP system. The `Save' buttons allow you to save the input and
configuration of each proof for documentation. By `Close' the results for all
goals are transferred back to the Proof Management GUI.
The MathServe system \cite{ZimmerAutexier06} developed by J\"{u}rgen
Zimmer provides a unified interface to a range of different ATP
systems; the most important systems are listed in
Table~\ref{tab:MathServe}, along with their capabilities. These
capabilities are derived from the \emph{Specialist Problem Classes}
(SPCs) defined upon the basis of logical, language and syntactical
properties by Sutcliffe and Suttner \cite{SutcliffeEA:2001:EvalATP}.
Only two of the Web services provided by the MathServe system are used
by \Hets currently: Vampire and the brokering system. The ATP systems
are offered as Web Services using standardized protocols and formats
such as SOAP, HTTP and XML. Currently, the ATP system Vampire may be
accessed from \Hets via MathServe; the other systems are only reached
after brokering.
\begin{table}[t]
\centering
\begin{threeparttable}
\begin{tabular}{|l|c|p{7cm}|}\firsthline
ATP System & Version & Suitable Problem Classes\tnote{a}\\
\hhline{|=|=|=|}
DCTP & 10.21p & effectively propositional \\\hline
EP & 0.91 & effectively propositional; real first-order, no
equality; real first-order, equality\\\hline
Otter & 3.3 & real first-order, no equality\\\hline
\SPASS & 2.2 & effectively propositional; real first-order, no
equality; real first-order, equality\\\hline
Vampire & 8.0 & effectively propositional; pure equality, equality
clauses contain non-unit equality clauses; real first-order, no
equality, non-Horn\\\hline
Waldmeister & 704 & pure equality, equality clauses are unit
equality clauses\\\lasthline
\end{tabular}
%\renewcommand{\thempfootnote}{\arabic{mpfootnote}}
%\footnotetext%[\value{footnote}\stepcounter{footnote}]
\begin{tablenotes}\footnotesize
\item[a]
{The list of problem classes for each ATP system is not
exhaustive, but only the most appropriate problem classes are
named according to benchmark tests made with MathServe by
J\"urgen Zimmer.}
\end{tablenotes}
\end{threeparttable}
\caption{ATP systems provided as Web services by MathServe}
\vspace*{-4mm}
\label{tab:MathServe}
\end{table}
\subsubsection*{\SPASS}
The ATP system \SPASS \cite{WeidenbachEtAl02} is a resolution-based
prover for first-order logic with equality. Furthermore, it provides a soft
typing mechanism with subsorting that treats sorts as unary
predicates. The ATP \SPASS should be installed locally and available
through your \verb,$PATH, environment variable.
\subsubsection*{Vampire}
% http://www.cs.miami.edu/~tptp/CASC/J3/SystemDescriptions.html#Vampire---8.0
The ATP system Vampire is the winner of the last 5 CADE ATP System
Competitions (CASC) (2002--2006) in the devisions \verb,FOF, and
\verb,CNF,. It is a resolution based ATP system supporting the calculi
of ordered binary resolution and superposition for handling equality.
See
\url{http://www.cs.miami.edu/~tptp/CASC/J3/SystemDescriptions.html#Vampire---8.0}
for detailed information. The connection to Vampire is achieved by
using an Web service of the MathServe system.
\subsubsection*{MathServe Broker}
% The classes ``effectively propositional'' and ``real first-order''
% apply to first-order problems that are distinguished by the finiteness
% of the Herbrand universe; an effectively propositional problem has
% only constants (generated by finitely many terms) whereas a real
% first-order problem contains true functions with an infinite Herbrand
% universe.
The brokering service chooses the most appropriate ATP system
upon a classification based on the SPCs, and on a training with the
library Thousands of Problems for Theorem Provers (TPTP)
\cite{ZimmerAutexier06}. The TPTP format
has been introduced by Sutcliffe and Suttner for the annual
competition CASC \cite{Sutcliffe:2006:CASC} and provides a unified
syntax for untyped FOL with equality, but without any symbol
declaration.
\subsection{Isabelle}
\Isabelle \cite{NipPauWen02} is an interactive theorem prover, which is
more powerful than ATP systems, but also requires more user interaction.
\Isabelle
has a very small core guaranteeing correctness, and its provers,
like the simplifier or the tableaux prover, are built on top of this
core. Furthermore, there is over fifteen years of experience with it,
and several mathematical textbooks have been partially
\index{formal!verification}%
verified with
\Isabelle.
\Isabelle is a tactic based theorem prover implemented in standard ML.
The main \Isabelle logic (called Pure) is some weak intuitionistic type
theory with polymorphism. The logic Pure is used to represent a
variety of logics within \Isabelle; one of them being \HOL (higher-order
logic). For example, logical implication in Pure (written
\texttt{==>}, also called meta-implication), is different from logical
implication in \HOL (written \texttt{-->}, also called object
implication).
It is essential to be aware of the fact that the \Isabelle/\HOL logic
is different from the logics that are encoded into it via comorphisms.
Therefore, the formulas appearing in subgoals of proofs with \Isabelle
will not conform to the syntax of the original input logic. They may
even use features of \Isabelle/\HOL such as higher-order functions
that are not present in an input logic like \CASL.
\Isabelle is started with ProofGeneral
\cite{DBLP:conf/tacas/Aspinall00,url:ProofGeneral} in a separate Emacs
\cite{url:Emacs,url:XEmacs}.
The \Isabelle theory file conforms to the Isabelle/Isar syntax
\cite{NipPauWen02}. It starts with the theory (encoded along the selected
comorphism), followed by a list of theorems. Initially, all the
theorems have trivial proofs, using the `oops` command. However, if
you have saved earlier proof attempts, \Hets will patch these into
the generated \Isabelle theory file, ensuring that your previous work
is not lost. (But note that this patching can only be successful
if you do not rename specifications, or change their structure.) You
now can replace the 'oops' commands with real \Isabelle proofs, and
use Proof General to step through the proofs. You finish your session
by saving your file (using the Emacs file menu, or the Ctrl-x Ctrl-s
key sequence), and by exiting Emacs (Ctrl-x Ctrl-c).
\subsection{VSE}
\label{subsec:VSE}
The specification environment Verification Support Environment
(VSE) \cite{VSE00}, developed at
DFKI Saarbr\"ucken, provides an industrial-strength methodology
for specification and verification of imperative programs.
VSE provides an interactive prover, which supports a Gentzen style
natural deduction calculus for dynamic logic.
This logic is an extension of first-order logic with two additional
kinds of formulas
that allow for reasoning about programs. One of them is the
box formula $[\alpha]\varphi$, where $\alpha$ is a program written in an imperative
language, and $\varphi$ is a dynamic logic formula.
The meaning of $[\alpha]\varphi$ can be roughly put as
``After every terminating execution of $\alpha$, $\varphi$ holds.''.
The other new kind
of formulas is the diamond formula $\langle\alpha\rangle\varphi$, which is the dual counter part
of a box formula. The meaning of $\langle\alpha\rangle\varphi$
can be described as ``After some terminating execution of $\alpha$,
$\varphi$ holds''.
A VSE specification or something that can be translated to VSE (currently only
\CASL) can be sent to the VSE prover via the node menu of development graph
nodes in two different ways. You can either select VSE from the theorem prover
choice box shown after ``Prove'' or you can select ``Prove VSE Structured''.
The first choice will call VSE with a single flattened theory whereas a
structured call will translate all nodes with ingoing links to the current one
individually.
VSE pops up with a ``project'' window. In this window you can choose ``Work
on'' and ``specification''. Besides the builtin specification ``boolean''
there is at least one specification from your development graph that you
can select for proving. For a structured choice you'll have specifications
for all underlying nodes that you should work on in a bottom up fashion.
The state created by VSE will be stored in a \texttt{.tar} file (within the
current directory) that preserves proofs for replay later on as long as you
don't change library or node names.
\ednote{TODO Till reference to VSE prover manual, no? availability of VSE,
screen-shots?}
\subsection{zChaff}
zChaff is a solver for satisfiabily problems of boolean formulas
(\normalTEXTSC{S}{AT})
in CNF. It is connected as a prover for propositional logic to \Hets. The prover
\SPASS is used to transform arbitrary boolean formulas to CNF. zChaff
implements the \normalTEXTSC{C}{HAFF}\xspace algorithm. We are
using the property, that a conjecture under the assumption of a set of axioms is
true, if the variables of axioms together with the negation of the conjecture
have no satisfying assignment, to prove theorems with zChaff. That is why you see
the result \normalTEXTSC{U}{NSAT}\xspace in the proof details, if a theorem has been proved
to be true. zChaff uses the same ATP GUI as the provers for SoftFOL (ref. to section
\ref{sec:ATP}). zChaff does not accept any options apart from the time-limit. The
current integration of zChaff into \Hets has been tested with zChaff 2004.11.15.
\subsection{Reduce}
\ednote{TODO : Dominik D.}
\subsection{Pellet}
Pellet is a popular open-source \DL-reasoner for \SROIQ, which is the logic
underlying OWL 2.0, written in Java. A Java Runtime Environment (in version > 1.5)
is needed to run Pellet. For the integration into \Hets the environment variable
\verb+PELLET_PATH+ has to be set to the root-directory of the Pellet installation.
Pellet uses the same ATP GUI as the provers for SoftFOL (ref. to section
\ref{sec:ATP}).
\subsection{Fact++}
Fact++ is a \DL-reasoner for \SROIQ, which is the logic underlying OWL 2.0, written in
C++. Fact++ is integrated into \Hets via the OWL-API, which is written in Java.
A Java Runtime Environment (in version >= 1.5) has to be installed. To use Fact++,
the environment variable \verb+HETS_OWL_TOOLS+ has to be set to the directory
containing the files
\begin{verbatim}
OWLFact.jar
OWLFactProver.jar
lib/FaCTpp-OWLAPI-v1.3.0.1.jar
lib/owlapi-bin.jar
\end{verbatim}
as well as
\begin{verbatim}
lib/native/i686/libFaCTPlusPlusJNI.so
\end{verbatim}
on a 32bits-Linux-system or
\begin{verbatim}
lib/native/x86_64/libFaCTPlusPlusJNI.so
\end{verbatim}
in a 64bits-Linux-system. Fact++ does not support options.
Fact++ uses the same ATP GUI as the provers for SoftFOL (ref. to section
\ref{sec:ATP}).
\subsection{QuickCheck}
\ednote{TODO Till}
\subsection{minisat}
\ednote{TODO Till}
\subsection{Truth tables}
\ednote{TODO Till}
\subsection{E-KRHyper}
E-KRHyper\footnote{\url{http://www.uni-koblenz.de/~bpelzer/ekrhyper/}}
is an extension of
KRHyper\footnote{\url{http://www.uni-koblenz.de/~wernhard/krhyper/}} by
handling of equality. E-KRHyper is an automatic first order theorem
prover and model finder based on the Hyper Tableaux Calculus\cite{Baumgartner:1996}.
E-KRHyper is optimized for being integrated into other systems. In the current
implementation we use a default tactics script, that can be influenced by the user.
The options of E-KRHyper are written in a Prolog-like syntax as in
\begin{verbatim}
#(set_parameter(timeout_termination_method,0)).
\end{verbatim}
the ``.'' at the end of each option is mandatory. To get an overview of
E-KRHyper's options, run the command
\begin{verbatim}
ekrh
\end{verbatim}
in a terminal. Then enter the command
\begin{verbatim}
#(help).
\end{verbatim}
at the prompt of E-KRHyper, to display its help information, which is basically
a long list of all available parameters. You can exit E-KRHyper by the command
\begin{verbatim}
#(exit).
\end{verbatim}
E-KRHyper uses the same ATP GUI as the other provers for SoftFOL (ref. to section
\ref{sec:ATP}).
\subsection{Darwin}
Darwin is an automatic first order prover and model finder implementing the Model
Evolution
Calculus\cite{Baumgartner:2003}. The integration of Darwin as a consistency checker
supports the display of models (if they can be constructed) in \CASL-syntax.
Eprover is needed to be in the system-path, if Darwin is used with \Hets, since
Darwin uses Eprover for clausification of first-order formulae.
Darwin supports a wide range of options, to get an overview of them run the command
\begin{verbatim}
darwin --help
\end{verbatim}
in a terminal.
Darwin uses the same ATP GUI as the other provers for SoftFOL (ref. to section
\ref{sec:ATP}).
\subsection{CspCASLProver}
\ednote{TODO Markus}
\section{Limits of Hets}
\Hets is still intensively under development. In particular, the
following points are still missing:
\begin{itemize}
\item There is no proof support for architectural specifications.
\item Distributed libraries are always downloaded from the local disk,
not from the Internet.
\item Version numbers of libraries are not considered properly.
\item The proof engine for development graphs provides only experimental
support for hiding links and for conservativity.
\end{itemize}
\section{Architecture of Hets}
The architecture of \Hets is shown in Fig.~\ref{fig:hets}.
How is a single logic implemented in the Heterogeneous Tool Set?
This is depicted in the left column of Fig.~\ref{fig:hets}.
\Hets provides an abstract interface for
\index{institution!independence}%
\index{independence, institution}%
institutions, so
that new logics can be integrated smoothly.
In order to do so, a parser,
a static checker and a prover for basic specifications in the logic have
to be provided.
\begin{figure}
%\figrule
\begin{center}
{\small
\begin{verbatim}
class Logic lid sign morphism sentence basic_spec symbol_map
| lid -> sign morphism sentence basic_spec symbol_map where
identity :: lid -> sign -> morphism
compose :: lid -> morphism -> morphism -> morphism
dom, codom :: lid -> morphism -> sign
parse_basic_spec :: lid -> String -> basic_spec
parse_symbol_map :: lid -> String -> symbol_map
parse_sentence :: lid -> String -> sentence
empty_signature :: lid -> sign
basic_analysis :: lid -> sign -> basic_spec -> (sign, [sentence])
stat_symbol_map :: lid -> sign -> symbol_map -> morphism
map_sentence :: lid -> morphism -> sentence -> sentence
provers ::
lid -> [(sign, [sentence]) -> [sentence] -> Proof_status]
cons_checkers :: lid -> [(sign, [sentence]) -> Proof_status]
class Comorphism cid
lid1 sign1 morphism1 sentence1 basic_spec1 symbol_map1
lid2 sign2 morphism2 sentence2 basic_spec2 symbol_map2
| cid -> lid1 lid2 where
sourceLogic :: cid -> lid1 targetLogic :: cid -> lid2
map_theory :: cid -> (sign1, [sentence1]) -> (sign2, [sentence2])
map_morphism :: cid -> morphism1 -> morphism2
\end{verbatim}
}
\end{center}
\caption{The basic ingredients of logics and logic comorphisms}
\label{fig:logic:all}
%\figrule
\end{figure}
Each logic is realized in the programming language Haskell
\cite{PeytonJones03} by a set of types and functions, see
Fig.~\ref{fig:logic:all}, where we present a simplified, stripped down
version, where e.g.\ error handling is ignored. For technical reasons
a logic is \emph{tagged} with a unique identifier type (\texttt{lid}),
which is a singleton type the only purpose of which is to determine
all other type components of the given logic. In Haskell jargon, the
interface is called a multiparameter type class with functional
dependencies \cite{TypeClasses}. The Haskell interface for logic
translations is realised similarly.
The logic-independent modules in \Hets can be found in the right half
of Fig.~\ref{fig:hets}. These modules comprise roughly one third of
\Hets' 100.000 lines of Haskell code.
The heterogeneous parser transforms a string
conforming to the syntax in Fig.~\ref{fig:lang}
to an abstract syntax tree, using the \texttt{Parsec} combinator parser
\cite{Parsec}. Logic and translation names are looked up in the logic
graph --- this is necessary to be able to choose the correct parser
for basic specifications. Indeed, the parser has a state that carries
the current logic, and which is updated if an explicit specification
of the logic is given, or if a logic translation is encountered (in
the latter case, the state is set to the target logic of the
translation). With this, it is possible to parse basic specifications
by just using the logic-specific parser of the current logic as
obtained from the state.
The static analysis is based on the static analysis of basic
specifications, and transforms an abstract syntax tree to a
development graph (cf.\ Sect.~\ref{sec:DevGraph} above). Starting with a
node corresponding to the empty theory, it successively extends (using
the static analysis of basic specifications) and/or translates (along
the intra- and inter-logic translations) the theory, while
simultaneously adding nodes and links to the development graph.
Heterogeneous proof management is done using heterogeneous
development graphs, as described in Sect.~\ref{sec:DevGraph}.
For local proof goals, logic-specific provers are invoked,
see Sect.~\ref{sec:Proofs}.
\Hets can store development graphs, including their proofs.
Therefore, \Hets uses the so-called
\index{ATerms}%
ATerm format \cite{BJKO00}, which is used as interchange format
for interfacing with other tools.
More details can be found in \cite{Habil,MossakowskiEtAl07b}
and in the overview of modules provided in the developers section
of the \Hets home page at \url{http://www.dfki.de/sks/hets}.
\begin{figure}
\begin{center}
\includegraphics[scale=0.4]{hets2007}
\end{center}
%\vspace{1em}
%\input{hets.tex}
\caption{Architecture of the heterogeneous tool set.
\label{fig:hets}}
\end{figure}
\bigskip
\Hets is mainly maintained by
Christian Maeder (Christian.Maeder@dfki.de) and Till Mossakowski
(Till.Mossakowski@dfki.de). The mailing list is
\begin{quote}
\url{hets-users@informatik.uni-bremen.de}
\end{quote}
the homepage is
\begin{quote}
\url{http://www.informatik.uni-bremen.de/mailman/listinfo/hets-users}.
\end{quote}
You need to subscribe to the list before you can send a mail.
But note that subscription is very easy!
If your favourite logic is missing in \Hets, please tell us
(hets-users@informatik.uni-bremen.de). We will take account your
feedback when deciding which logics and proof tools to integrate next
into \Hets. Help with integration of more logics and proof tools into
\Hets is also welcome.
\paragraph{Acknowledgement}
The heterogeneous tool set \Hets would not have possible
without cooperation with many people.
%Christian Maeder and Klaus L\"uttich.
Besides the authors, the following people have been involved
in the implementation of \Hets:
Katja Abu-Dib,
Liliana Codruta,
Dominik Dietrich,
Elena Digor,
Carsten Fischer,
Jorina Freya Gerken,
Andy Gimblett,
Rainer Grabbe,
Sonja Gr\"{o}ning,
Markus Groß,
Klaus Hartke,
Daniel Hausmann,
Wiebke Herding,
Hendrik Iben,
Cui ``Ken'' Jian,
Heng Jiang,
Anton Kirilov,
Tina Krausser,
Martin K\"{u}hl,
Mingyi Liu,
Karl Luc,
Klaus L\"{u}ttich,
%Christian Maeder,
Maciek Makowski,
Florian Mossakowski,
Immanuel Normann,
Liam O'Reilly,
Razvan Pascanu,
Daniel Pratsch,
Felix Reckers,
Adrian Riesco,
Markus Roggenbach,
Pascal Schmidt,
Ewaryst Schulz,
Kristina Sojakova,
Igor Stassiy,
Tilman Thiry,
Paolo Torrini,
Jonathan von Schroeder,
Ren\'{e} Wagner,
Jian Chun Wang,
Zicheng Wang, and
Thiemo Wiedemeyer.
\Hets has been built based on experiences with its
precursors,
\index{Cats@\Cats}%
\Cats and
\index{Maya@\MAYA}%
\MAYA.
The \CASL Tool Set (\Cats)
\cite{Mossakowski:2000:CST,Mossakowski:1998:SSA}
provides parsing and static analysis for \CASL.
It has been developed by the first author with help
of Mark van den Brand, Kolyang, Bartek Klin, Pascal Schmidt and
Frederic Voisin.
\MAYA \cite{Autexier:2002:IHD,AutexierEtal02} is a proof management
tool based on development graphs. \MAYA only supports development
graphs without hiding and without logic translations. \MAYA has been
developed by Serge Autexier and Dieter Hutter.
We also want to thank Agn\`es Arnould, Thibaud Brunet, Pascale LeGall,
Kathrin Hoffmann, Bruno Langenstein, Katiane Lopes,
%Klaus L\"uttich, Christian Maeder,
Stefan Merz, Maria Martins Moreira, Christophe
Ringeissen, Markus Roggenbach, Dmitri Schamschurko, Lutz Schr\"oder,
Konstantin Tchekine and Stefan W\"olfl
for giving feedback about \Cats, HOL-CASL and \Hets. Finally,
special thanks to Christoph L\"uth and George Russell
for help with connecting \Hets to their UniForM workbench.
\bibliographystyle{plain}
\bibliography{cofibib,cofi-ann,UM,hets,kl}
\end{document}
%%% Local Variables:
%%% mode: latex
%%% TeX-master: "UserGuide"
%%% End: