blob: d84c855c67f5bfe40c7a44aebc14cd3f33f38b79 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
\documentclass{article}
\usepackage{a4wide}
\usepackage[english]{babel}
\usepackage[latin1]{inputenc}
\selectlanguage{english}
\usepackage{amsmath,url,graphics,verbatim}
\DeclareGraphicsRule{*}{mps}{*}{}
\begin{document}
\title{An example of automaton generated\\with the MetaPost package \url{automata.mp}}
\author{Gabriele Puppis\\
\emph{Dipartimento di Matematica e Informatica, Università di Udine, Italy}\\
\url{gabriele.puppis@dimi.uniud.it}}
\maketitle
This \LaTeX\ document shows how to include a picture generated with MetaPost.
By default, the extension of a file generated with MetaPost is a number
(e.g., \url{.0}), so you should use the package \url{graphics} and the command
\verb \DeclareGraphicsRule{*}{mps}{*}{} to make \LaTeX\ recognize these
extensions as files in PS format.
The file \url{example.mp} contains the MetaPost source code that was used to generate
the automaton in Figure \ref{fig:example}. This file should be compiled with MetaPost
(e.g., run ``\verb mp \verb -tex=latex \verb example.mp '' from the shell command
line). Such an example uses the package \url{automata.mp} to easily draw the states
and the transitions of the automaton (you can find some documentation inside the files
\url{example.mp} and \url{automata.mp}).
\begin{figure}[!!h]
\centering\includegraphics{example.0}
\caption{An example pf automaton}\label{fig:example}
\end{figure}
\end{document}
|