331 |
331 |
332 text {* |
332 text {* |
333 In contrast to the highly interactive mode of Isabelle/Isar theory |
333 In contrast to the highly interactive mode of Isabelle/Isar theory |
334 development, the document preparation stage essentially works in |
334 development, the document preparation stage essentially works in |
335 batch-mode. An Isabelle \bfindex{session} consists of a collection |
335 batch-mode. An Isabelle \bfindex{session} consists of a collection |
336 of theory source files that contribute to an output document |
336 of theory source files that may contribute to an output document |
337 eventually. Each session is derived from a single parent, usually |
337 eventually. Each session is derived from a single parent, usually |
338 an object-logic image like \texttt{HOL}. This results in an overall |
338 an object-logic image like \texttt{HOL}. This results in an overall |
339 tree structure, which is reflected by the output location in the |
339 tree structure, which is reflected by the output location in the |
340 file system (usually rooted at \verb,~/isabelle/browser_info,). |
340 file system (usually rooted at \verb,~/isabelle/browser_info,). |
341 |
341 |
342 \medskip The easiest way to manage Isabelle sessions is via |
342 \medskip The easiest way to manage Isabelle sessions is via |
343 \texttt{isatool mkdir} (generates an initial source setup) and |
343 \texttt{isatool mkdir} (generates an initial session source setup) |
344 \texttt{isatool make} (runs a session controlled by |
344 and \texttt{isatool make} (run sessions controlled by |
345 \texttt{IsaMakefile}). For example, a new session |
345 \texttt{IsaMakefile}). For example, a new session |
346 \texttt{MySession} derived from \texttt{HOL} may be produced as |
346 \texttt{MySession} derived from \texttt{HOL} may be produced as |
347 follows: |
347 follows: |
348 |
348 |
349 \begin{verbatim} |
349 \begin{verbatim} |
350 isatool mkdir HOL MySession |
350 isatool mkdir HOL MySession |
351 isatool make |
351 isatool make |
352 \end{verbatim} |
352 \end{verbatim} |
353 |
353 |
354 The \texttt{isatool make} job tells about the file-system location |
354 The \texttt{isatool make} job also informs about the file-system |
355 of the ultimate results. The above dry run should be able to |
355 location of the ultimate results. The above dry run should be able |
356 produce some \texttt{document.pdf} of a single page (with dummy |
356 to produce some \texttt{document.pdf} (with dummy title, empty table |
357 title, empty table of contents etc.). Any failure at that stage |
357 of contents etc.). Any failure at that stage usually indicates |
358 usually indicates technical problems of the {\LaTeX} |
358 technical problems of the {\LaTeX} installation.\footnote{Especially |
359 installation.\footnote{Especially make sure that \texttt{pdflatex} |
359 make sure that \texttt{pdflatex} is present; if all fails one may |
360 is present; if all fails one may fall back on DVI output by changing |
360 fall back on DVI output by changing \texttt{usedir} options in |
361 \texttt{usedir} options in \texttt{IsaMakefile} |
361 \texttt{IsaMakefile} \cite{isabelle-sys}.} |
362 \cite{isabelle-sys}.} |
|
363 |
362 |
364 \medskip The detailed arrangement of the session sources is as |
363 \medskip The detailed arrangement of the session sources is as |
365 follows: |
364 follows: |
366 |
365 |
367 \begin{itemize} |
366 \begin{itemize} |
392 See also \cite{isabelle-sys} for further details, especially on |
391 See also \cite{isabelle-sys} for further details, especially on |
393 \texttt{isatool usedir} and \texttt{isatool make}. |
392 \texttt{isatool usedir} and \texttt{isatool make}. |
394 |
393 |
395 \end{itemize} |
394 \end{itemize} |
396 |
395 |
397 With everything put in its proper place, \texttt{isatool make} |
396 One may now start to populate the directory \texttt{MySession}, and |
398 should be sufficient to process the Isabelle session completely, |
397 the file \texttt{MySession/ROOT.ML} accordingly. |
399 with the generated document appearing in its proper place. |
398 \texttt{MySession/document/root.tex} should also be adapted at some |
400 |
399 point; the default version is mostly self-explanatory. Note that |
401 \medskip One may now start to populate the directory |
400 \verb,\isabellestyle, enables fine-tuning of the general appearance |
402 \texttt{MySession}, and the file \texttt{MySession/ROOT.ML} |
401 of characters and mathematical symbols (see also |
403 accordingly. \texttt{MySession/document/root.tex} should also be |
402 \S\ref{sec:doc-prep-symbols}). |
404 adapted at some point; the default version is mostly |
403 |
405 self-explanatory. Note that \verb,\isabellestyle, enables |
404 Especially observe the included {\LaTeX} packages \texttt{isabelle} |
406 fine-tuning of the general appearance of characters and mathematical |
405 (mandatory), \texttt{isabellesym} (required for mathematical |
407 symbols (see also \S\ref{sec:doc-prep-symbols}). |
406 symbols), and the final \texttt{pdfsetup} (provides handsome |
408 |
407 defaults for \texttt{hyperref}, including URL markup) --- all three |
409 Especially observe inclusion of the {\LaTeX} packages |
408 are distributed with Isabelle. Further packages may be required in |
410 \texttt{isabelle} (mandatory), and \texttt{isabellesym} (required |
409 particular applications, e.g.\ for unusual mathematical symbols. |
411 for mathematical symbols), and the final \texttt{pdfsetup} (provides |
410 |
412 handsome defaults for \texttt{hyperref}, including URL markup). |
411 \medskip Additional files for the {\LaTeX} stage may be put into the |
413 Further packages may be required in particular applications, e.g.\ |
412 \texttt{MySession/document} directory, too. In particular, adding |
414 for unusual Isabelle symbols. |
413 \texttt{root.bib} here (with that specific name) causes an automatic |
415 |
414 run of \texttt{bibtex} to process a bibliographic database; see also |
416 \medskip Additional files for the {\LaTeX} stage may be included in |
415 \texttt{isatool document} covered in \cite{isabelle-sys}. |
417 the directory \texttt{MySession/document}, too, such as {\TeX} |
|
418 sources or graphics). In particular, adding \texttt{root.bib} here |
|
419 (with that specific name) causes an automatic run of \texttt{bibtex} |
|
420 to process a bibliographic database; see also \texttt{isatool |
|
421 document} covered in \cite{isabelle-sys}. |
|
422 |
416 |
423 \medskip Any failure of the document preparation phase in an |
417 \medskip Any failure of the document preparation phase in an |
424 Isabelle batch session leaves the generated sources in their target |
418 Isabelle batch session leaves the generated sources in their target |
425 location (as pointed out by the accompanied error message). This |
419 location (as pointed out by the accompanied error message). This |
426 enables users to trace {\LaTeX} at the file positions of the |
420 enables users to trace {\LaTeX} problems with the target files at |
427 generated material. |
421 hand. |
428 *} |
422 *} |
429 |
423 |
430 |
424 |
431 subsection {* Structure Markup *} |
425 subsection {* Structure Markup *} |
432 |
426 |