\documentclass[pdf,slideColor,plainsem]{prosper}

\usepackage{xspace}
\usepackage{latexsym}
\usepackage{amssymb}

\usepackage{pst-node}
\usepackage{pst-uml-prosper}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\def\MiniPage#1#2{\begin{minipage}[t]{.49\hsize}#1\end{minipage}%
\hspace{1ex}\begin{minipage}[t]{.49\hsize}#2\end{minipage}}

\newlength{\ParLen}
\def\Parbox#1#2{\settowidth{\ParLen}{#1}\parbox[t]{\ParLen}{#2}}

\newcommand {\minitab}  {\hspace*{1ex}}
\newcommand {\smalltab} {\hspace*{5mm}}
\newcommand {\tab}      {\hspace*{10mm}}
\newcommand {\bigtab}   {\hspace*{15mm}}
\newcommand {\hugetab}  {\hspace*{20mm}}

\newcommand{\per}{\mathpunct{\mbox{\bf .}}}
\newcommand{\nl}{\\\tab}

\def\centerpar#1{\renewcommand{\arraystretch}{0.7}%
\begin{tabular}{c}#1\end{tabular}\renewcommand{\arraystretch}{1}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% symbols for UML package
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\newlength{\umlunitbox}
\def\umlcard#1%
  {\umlcsize #1\hspace*{-.5ex}}
\def\umlclass#1#2%
  {\rnode{#1}{\umlClass{\makebox[\umlunitbox]{#2}}{\hline\hline}}}
\def\umlclassred#1#2%
  {\color{red}%
  \rnode{#1}{\umlClass[linecolor=red]{\makebox[\umlunitbox]{#2}}{\hline\hline}}}
\def\umlclassa#1#2#3%
  {\rnode{#1}{\umlClass{\makebox[\umlunitbox]{#2}}%
  {#3\\\hline\hline}}}
\def\umldefclass#1#2%
  {\rnode{#1}{\umlClass{\makebox[\umlunitbox]%
      {{\bf /}#2}}{\hline\hline}}}
\renewcommand{\ncputicon}[2][]{%
   \setkeys{psset}{npos=0,nrot=:D}%
   \setkeys{psset}{#1}%
   \ncput{#2}}
\def\umlIsa{%
   \pstriangle[gangle=-90,%
              linestyle=solid,%
              fillstyle=solid,%
              fillcolor=white]%
          (-0.15,0)(0.12,0.15)} % (centre)(Width,Length)

%%%%%%%%%% Macros %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\newcommand{\vtrue}{{\tt T}}
\newcommand{\vfalse}{{\tt F}}
\newcommand{\interp}{{\cal I}}
\newcommand{\interf}{{\cal I}}
\newcommand{\domain}{{\Delta}}
\newcommand{\jinterp}{{\cal J}}
\newcommand{\interfj}{{\cal J}}
\newcommand{\minterp}{{\cal M}}
\newcommand{\formel}{{\cal F}}
\newcommand{\clauses}{{\cal C}}
\newcommand{\intf}[1]{{#1}^{\cal I}}
\newcommand{\intfj}[1]{{#1}^{\cal J}}
\newcommand{\varmap}{{\alpha}}
\newcommand{\intfv}[1]{{#1}^{{\cal I},\varmap}}
\newcommand{\I}{{\cal I}}

\newcommand{\predA}{{\tt A}}
\newcommand{\predB}{{\tt B}}
\newcommand{\predR}{{\tt R}}

\newcommand{\tl}[1]{#1^\ast}    % translation of modal logic formulae
                                % into predicate logic formulae

\newcommand{\set}[1]{\{ #1 \}}          % set

\newcommand{\KB}{\textit{KB}\xspace}

\newcommand{\limplies}{\rightarrow}
\newcommand{\lequiv}{\leftrightarrow}
\newcommand{\Subsumes}{{\sqsupseteq}}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\semtitle{Description Logics}
\semsubject{Foundations of First Order Logic}
\semauthor{Enrico Franconi}
\sememail{franconi@cs.man.ac.uk}
\semwebpage{http://www.cs.man.ac.uk/\~{}franconi}
\seminstitution{Department of Computer Science, University of Manchester}

\begin{document}

\makesemtitle

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Motivation}

\begin{itemize}

    \item We can already do a lot with propositional logic.

    \item But it is unpleasant that we cannot access the {\em
    structure\/} of atomic sentences.

    \item Atomic formulas of propositional logic are {\it too atomic}
    -- they are just statement which my be true or false but which
    have no internal structure.

    \item In \textit{First Order Logic} (FOL) the atomic formulas are
    interpreted as statements about \textit{relationships between
    objects}.

\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Predicates and Constants}

    Let's consider the statements:
    \begin{itemize}
        \item \textit{Mary is female}\\
        \textit{John is male}\\
        \textit{Mary and John are siblings}
    \end{itemize}
    
In propositional logic the above statements are atomic propositions:
    \begin{itemize}
        \item \texttt{Mary-is-female}\\ \texttt{John-is-male}\\
        \texttt{Mary-and-John-are-siblings}
    \end{itemize}

In FOL atomic statements use predicates, with
constants as argument:
    \begin{itemize}
        \item {\tt Female(mary)}\\ {\tt Male(john)}\\
       {\tt Siblings(mary,john)}
    \end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Variables and Quantifiers}

    Let's consider the statements:
    \begin{itemize}
        \item \textit{Everybody is male or female}
        \item \textit{A male is not a female}
    \end{itemize}
    
    In FOL predicates may have variables as arguments, whose value is 
    bounded by quantifiers:
    \begin{itemize}
        \item {$\tt\forall x\per\ Male(x)\lor Female(x)$}
        \item {$\tt\forall x\per\ Male(x)\rightarrow \neg Female(x)$}
    \end{itemize}
    
    Deduction (why?):
    \begin{itemize}
        \item \textit{Mary is not male}
        \item {$\tt\neg Male(mary)$}
    \end{itemize}
    
    

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Functions}

    Let's consider the statement:
    \begin{itemize}
        \item \textit{The father of a person is male}
    \end{itemize}
    
    In FOL objects of the domain may be denoted by functions applied 
    to (other) objects:
    \begin{itemize}
        \item {$\tt\forall x\per\ Male(father(x))$}
    \end{itemize}
    
\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Syntax of FOL: atomic sentences}

Countably infinite {\bf supply of symbols} ({\em signature}):

\begin{itemize}
\item variable symbols: $x,y,z, \ldots$ \\
$n$-ary function symbols: $f,g,h, \ldots$\\
individual constants: $a,b,c,\ldots$\\
$n$-are predicate symbols: $P,Q,R, \ldots$
\end{itemize}

\begin{tabbing}
{\bf Formulas:}\ \  \= $\phi,\psi$ \= $\rightarrow$ \=
$f(t_1, \ldots, t_n)$~~~~~~  \= \kill 
{\bf Terms:} \> $t$ \> $\rightarrow$ \> $x$ \> {\small variable} \\
\> \> $|$ \> $a$ \> {\small constant} \\
\> \> $|$ \> $f(t_1, \ldots, t_n)$ \> {\small function application}
%
\\ {\bf Ground terms}: terms that do not contain variables \\
%
{\bf Formulas:} \> $\phi$ \> $\rightarrow$ \> $P(t_1,\ldots,t_n)$
\> {\small atomic formulas}
\end{tabbing}

\begin{tabular}{ll}
E.g., & $Brother(kingJohn,richardTheLionheart)$\\
      & $>(length(leftLegOf(richard)),length(leftLegOf(kingJohn)))$\\
\end{tabular}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Syntax of FOL: propositional sentences}

\begin{tabbing}
{\bf Formulas:}\ \  \= $\phi,\psi$ \= $\rightarrow$ \=
$f(t_1, \ldots, t_n)$~~~~~~  \= \kill 
{\bf Formulas:} \> $\phi,\psi$ \> $\rightarrow$ \> $P(t_1,\ldots,t_n)$
\> {\small atomic formulas} \\
\> \> $|$ \> $\bot$ \> {\small false} \\
\> \> $|$ \> $\top$ \> {\small true} \\
\> \> $|$ \> $\neg\phi$ \> {\small negation} \\
\> \> $|$ \> $\phi\land\psi$ \> {\small conjunction} \\
\> \> $|$ \> $\phi\lor\psi$ \> {\small disjunction} \\
\> \> $|$ \> $\phi\rightarrow\psi$ \> {\small implication} \\
\> \> $|$ \> $\phi\leftrightarrow\psi$ \> {\small equivalence} \\
\end{tabbing}

\begin{itemize}
\item (Ground) {\bf atoms} and (ground) {\bf literals}.
\end{itemize}

{\small
\begin{tabular}{ll}
E.g. & $Sibling(kingJohn,richard) \rightarrow Sibling(richard,kingJohn)$ \\
     & ${>}(1,2) \lor {\leq}(1,2)$ \\
     & ${>}(1,2) \land \lnot {>}(1,2)$ \\
\end{tabular}}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Syntax of full FOL}

\begin{tabbing}
{\bf Formulas:}\ \  \= $\phi,\psi$ \= $\rightarrow$ \=
$f(t_1, \ldots, t_n)$~~~~~~  \= \kill 
{\bf Formulas:} \> $\phi,\psi$ \> $\rightarrow$ \> $P(t_1,\ldots,t_n)$
\> {\small atomic formulas} \\
\> \> $|$ \> $\bot$ \> {\small false} \\
\> \> $|$ \> $\top$ \> {\small true} \\
\> \> $|$ \> $\neg\phi$ \> {\small negation} \\
\> \> $|$ \> $\phi\land\psi$ \> {\small conjunction} \\
\> \> $|$ \> $\phi\lor\psi$ \> {\small disjunction} \\
\> \> $|$ \> $\phi\rightarrow\psi$ \> {\small implication} \\
\> \> $|$ \> $\phi\leftrightarrow\psi$ \> {\small equivalence} \\
\> \> $|$ \> $\forall x\per\ \phi$ \> {\small\bf\it universal quantification} \\
\> \> $|$ \> $\exists x\per\ \phi$ \> {\small\bf\it existential quantification} \\
\end{tabbing}

\begin{tabular}{lll}
E.g. & Everyone in England is smart:
     & $\forall x\per\ In(x,england) \rightarrow Smart(x)$\\
     & Someone in France is smart:
     & $\exists x\per\ In(x,france) \land Smart(x)$\\
 \end{tabular}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Summary of Syntax of FOL}

\begin{itemize}
\item Terms
  \begin{itemize}
  \item variables
  \item constants
  \item functions
  \end{itemize}
\item Literals
  \begin{itemize}
  \item atomic formula
    \begin{itemize}
    \item relation (predicate)
    \end{itemize}
  \item negation
  \end{itemize}
\item Well formed formulas
  \begin{itemize}
  \item truth-functional connectives
  \item existential and universal quantifiers
  \end{itemize}
\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Semantics of FOL: intuition}

\begin{itemize}

\item Just like in propositional logic, a (complex) FOL formula may be
true (or false) with respect to a given interpretation.

\item An interpretation specifies referents for\\
{\em constant symbols} $\rightarrow$ \textbf{objects}\\
{\em predicate symbols} $\rightarrow$ \textbf{relations}\\
{\em function symbols} $\rightarrow$ \textbf{functional relations}

\item An atomic sentence $P(t_1,\ldots,t_n)$ is true in a given 
interpretation\\
iff the \textit{objects} referred to by $t_1,\ldots,t_n$\\
are in the \textit{relation} referred to by the predicate $P$.

\item An interpretation in which a formula is true is called a {\em 
model} for the formula.

\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Models for FOL: Example}

\includegraphics[width=\hsize]{fol-models.eps}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Semantic of FOL: Interpretations}

{\bf Interpretation}: $\interf = \langle\domain, \intf{\cdot}\rangle$
where $\domain$ is an arbitrary non-empty set and
$\interf$ is a function that maps

\begin{itemize}
\item $n$-ary function symbols to functions over $\domain$: \\
$\intf{f} \in [\domain^n \rightarrow \domain]$
\item individual constants to elements of $\domain$:\newline
$\intf{a} \in \domain$
\item $n$-ary predicate symbols to relation over $\domain$:\\
$\intf{P}\subseteq \domain^n$
\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Semantic of FOL: Satisfaction}

{\bf Interpretation} of ground terms:
\begin{eqnarray*}
\intf{{(f(t_1,\ldots,t_n))}} & = &
\intf{f}(\intf{t_1},\ldots,\intf{t_n}) \:\: (\in \domain) \\
\end{eqnarray*}
{\bf Satisfaction} of ground atoms $P(t_1,\ldots,t_n)$:
\begin{eqnarray*}
\interf \models P(t_1,\ldots,t_n) & \mbox{iff} & 
\langle\intf{t_1},\ldots,\intf{t_n}\rangle \in \intf{P}
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\overlays{3}{
\begin{slide}{Examples}

\MiniPage
{$\begin{array}{rcl}
\domain & = & \{d_1, \ldots, d_n, n > 1\} \\
\intf{\mbox{\tt a}} & = & d_1 \\
\intf{\mbox{\tt b}} & = & d_2 \\
\intf{\mbox{\tt Block}} & = & \{d_1\} \\
\intf{\mbox{\tt Red}} & = & \domain \\
\fromSlide{2}{\interf} & \fromSlide{2}{\models} & \fromSlide{2}{\mbox{\tt Red(b)}} \\
\fromSlide{2}{\interf} & \fromSlide{2}{\not\models} & \fromSlide{2}{\mbox{\tt Block(b)}}
\end{array}$}
%
{$\begin{array}{rcl}
\domain & = & \{1,2,3,\ldots\} \\
\intf{\tt 1} & = & 1 \\
\intf{\tt 2} & = & 2 \\
& \vdots & \\
\intf{\tt Even} & = & \{2, 4, 6, \ldots\} \\
\intf{\tt succ} & = & \{(1 \mapsto 2), (2 \mapsto 3), \ldots\} \\
\fromSlide{3}{\interf} & \fromSlide{3}{\not\models} & \fromSlide{3}{{\tt Even}(3)} \\
\fromSlide{3}{\interf} & \fromSlide{3}{\models} & \fromSlide{3}{{\tt Even}({\tt succ}(3))}
\end{array}$}

\end{slide}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Semantics of FOL: Variable Assignments}

$V$ set of all variables. Function $\varmap\colon V \rightarrow \domain$.

{\bf Notation:} $\varmap[x/d]$ is identical to $\varmap$ except for the 
variable $x$.

Interpretation of terms {\em under $\interf,\varmap$}:
\begin{eqnarray*}
 \intfv{x} & = & \varmap(x) \\
 \intfv{a} & = & \intf{a} \\
 \intfv{(f(t_1,\ldots,t_n))} & = & \intf{f}(\intfv{t_1},\ldots,\intfv{t_n})
\end{eqnarray*}

Satisfiability of atomic formulas:
\begin{eqnarray*}
\interf,\varmap \models P(t_1,\ldots,t_n) & \mbox{iff} & 
\langle\intfv{t_1},\ldots,\intfv{t_n}\rangle \in \intf{P} 
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Variable Assignment example}

\begin{eqnarray*}
\varmap & = & \{(\mbox{\tt x} \mapsto d_1), (\mbox{\tt y} \mapsto d_2)\} \\
\interf,\varmap & \models & \mbox{\tt Red(x)} \\
%\interf,\varmap & \not\models & \mbox{\tt Block(y)} \\
\interf,\varmap[\mbox{\tt y}/d_1] & \models &  \mbox{\tt Block(y)}
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Semantics of FOL: Satisfiability of formulas}

A formula $\phi$ is satisfied by (\textit{is true in\/}) an
interpretation $\interf$ under a variable assignment $\varmap$,
\\$\interf,\varmap \models \phi$ :

\vspace{-1em}
\begin{eqnarray*}
\interf,\varmap \models P(t_1,\ldots,t_n) & \mbox{~~iff~~} & \langle
\intfv{t_1}, \ldots, \intfv{t_n}\rangle \in \intf{P} \\
\interf,\varmap \models \neg \phi & \mbox{~~iff~~} & \interf,\varmap
\not\models \phi \\
\interf,\varmap \models \phi \wedge \psi & \mbox{~~iff~~} & \interf,\varmap
\models \phi \: \mbox{and} \: \interf,\varmap
\models \psi \\
\interf,\varmap \models \phi \vee \psi & \mbox{~~iff~~} & \interf,\varmap
\models \phi \: \mbox{or} \: \interf,\varmap
\models \psi \\
\interf,\varmap \models \forall x\per \:  \phi & \mbox{~~iff~~} &
\!\! \begin{array}[t]{l}
\mbox{for all }\: d \in \domain \: \mbox{:} \\
\interf,\varmap[x/d]
\models  \phi 
\end{array} \\
\interf,\varmap \models \exists x\per \:  \phi & \mbox{~~iff~~} &
\!\! \begin{array}[t]{l}
\mbox{there exists a }\: d \in \domain \: \mbox{:} \\
 \interf,\varmap[x/d]
\models  \phi
\end{array}
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Examples}

{\footnotesize
\vspace{-2em}
 \begin{eqnarray*}
     \domain & = & \{d_1, \ldots, d_n, \} \:\: n > 1\\
\intf{\mbox{\tt a}} & = & d_1 \\
\intf{\mbox{\tt b}} & = & d_1 \\
\intf{\mbox{\tt Block}} & = & \{d_1\} \\
\intf{\mbox{\tt Red}} & = & \domain \\
\varmap & = & \{(\mbox{\tt x} \mapsto d_1), (\mbox{\tt y} \mapsto
d_2)\} \\
\end{eqnarray*}

\vspace{-2em}
\begin{enumerate}
\item $\interf,\varmap \models \mbox{\tt Block(c)} \vee 
\mbox{\tt $\neg$Block(c)}$? 
\item $\interf,\varmap \models \mbox{\tt Block(x)} \rightarrow \mbox{\tt
Block(x)} \vee \mbox{\tt Block(y)}$?
\item $\interf,\varmap \models \forall\per\ 
\mbox{\tt x  Block(x)} \rightarrow \mbox{\tt  Red(x)}$?
\item
$\Theta = \left\{ \begin{array}{l} 
\mbox{\tt Block(a), Block(b)} \\
\forall \mbox{\tt x  (Block(x)} \rightarrow \mbox{\tt  Red(x))}
\end{array} 
\right\}$ \\
$\interf,\varmap \models \Theta$?
\end{enumerate}
}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\overlays{2}{
\begin{slide}{Example}

Find a model of the formula:

$$\exists y\per\ [\ P(y)\wedge\neg Q(y)\ ] \land 
  \forall z\per [\ P(z)\lor Q(z)\ ]$$

\vspace{3em}

\fromSlide{2}{
$\Delta=\{a,b\}$ \\
$ \intf P=\{a\}$ \\
$ \intf Q=\{b\}$}

\end{slide}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Satisfiability and Validity}

An interpretation $\interf$ is a {\bf model} of $\phi$ 
{\em under} $\alpha$, if
\[\interf,\alpha \models \phi.\]

Similarly as in propositional logic, 
a formula $\phi$ can be
{\bf satisfiable}, {\bf unsatisfiable},  {\bf falsifiable} or
{\bf valid}---the definition is in terms of the pair $(\interf,\varmap)$.

A formula $\phi$ is
\begin{itemize}
\item {\bf satisfiable}, if there is some $(\interf,\varmap)$ that 
  satisfies~$\phi$,
\item {\bf unsatisfiable}, if $\phi$ is not satisfiable,
\item {\bf falsifiable}, if there is some $(\interf,\varmap)$
      that does not satisfy $\phi$,
\item {\bf valid} (i.e., a {\bf tautology}),  if every  $(\interf,\varmap)$
      is a model of $\phi$.
\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Equivalence}

Analogously, two formulas are {\bf logically equivalent} 
($\phi \equiv \psi$), 
if for all $\interf,\varmap$ we have:

\begin{eqnarray*}
\interf,\varmap \models \phi  & \mbox{iff} & \interf,\varmap
\models \psi
\end{eqnarray*}

{\bf Note:} ${\tt P(x)} \not\equiv  {\tt P(y)}$!

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Free and Bound Variables}

\vspace{-2em}
\[\forall \mbox{\tt x$\per$  (R(\fbox{y},\fbox{z}) $\wedge$ $\exists$ 
y$\per$  ($\neg$P(y,x)
$\vee$ R(y,\fbox{z})))}\]

Variables in boxes are {\bf free}; other variables are {\bf bound}.

Free variables of a formula (inductively defined over the structure of
expressions):

\vspace{-2em}
\begin{eqnarray*}
\mbox{free}(x) & = & \{x\} \\
\mbox{free}(a) & = & \emptyset \\
\mbox{free}(f(t_1,\ldots,t_n)) & = &  \mbox{free}(t_1) \cup \ldots \cup \mbox{free}(t_n) \\
\mbox{free}(P(t_1,\ldots,t_n)) & = &  \mbox{free}(t_1) \cup \ldots \cup \mbox{free}(t_n) \\
\mbox{free}(\neg\phi) & = & \mbox{free}(\phi) \\
\mbox{free}(\phi*\psi) & = & \mbox{free}(\phi) \cup \mbox{free}(\psi),
\: *=\vee, \wedge, \ldots \\
\mbox{free}(\forall x\per\ \phi) & = & \mbox{free}(\phi) - \{x\} \\
\mbox{free}(\exists x\per\ \phi) & = & \mbox{free}(\phi) - \{x\}
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Open and Closed Formulas}

\begin{itemize}

\item A formula is {\bf closed} or a {\bf sentence} if no free
variables occurs in it.  When formulating theories, we only use closed
formulas.

\item Note: For closed formulas, the properties {\em logical
equivalence, satisfiability, entailment\/} etc.\ do not depend on
variable assignments.  If the property holds for one variable
assignment then it holds for all of them.

\item For closed formulas, the symbol $\varmap$ on the left hand side
of the ``$\models$'' sign is omitted.  \[\interf \models \phi\]

\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Entailment}

Entailment is defined similarly as in propositional logic.

The formula $\phi$ is logically implied by a formula $\psi$,
if $\phi$ is true 
in all models of $\psi$ 
(symbolically, $\psi \models \phi$):
\begin{eqnarray*}
\psi \models \phi & \mbox{iff} & \interp \models \phi \: 
\mbox{\ for all models\ } \interp \: \mbox{\ of } \psi
\end{eqnarray*}


\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{More Exercises}

\begin{itemize}
\item $\models \forall x\per\ (P(x)\lor \neg P(x))$ \\
\item $\exists x\per\ [\ P(x)\land (P(x)\rightarrow Q(x))\ ] \models
  \exists x\per\ Q(x)$ \\
\item $\models \neg (\exists x\per\ [\ \forall y\per\ [\ P(x)\rightarrow Q(y)\ ]\ ])$ \\
\item $\exists y\per\ [\ P(y)\wedge\neg Q(y)\ ] \land \forall z\per [\ 
  P(z)\lor Q(z)\ ]$ satisfiable
\end{itemize}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Equality}

\begin{itemize}

\item Equality is a special predicate.

\item $t_1 = t_2$ is true under a given interpretation $(\interf,\varmap \models 
t_1 = t_2)$\\
if and only if $t_1$ and $t_2$ refer to the same object:\\
$\intfv{t_1} = \intfv{t_2}$

\end{itemize}

\begin{tabular}{ll}
E.g.,& $\forall{x}\per\ ({\times}(sqrt(x),sqrt(x)) = x)$ 
is satisfiable\\
      & $2=2$ is valid
\end{tabular}

E.g., definition of (full) $Sibling$ in terms of $Parent$:

$\forall{x,y}\per$
  \parbox[t]{2\textwidth}{$
    Sibling(x,y) \lequiv \\
    (\parbox[t]{\textwidth}{$
       \lnot(x = y) \land \\
       \exists{m,f}\per
       \parbox[t]{\textwidth}{$
         \lnot(m = f) \land 
         Parent(m,x) \land Parent(f,x) \land\\ Parent(m,y) \land 
         Parent(f,y)\ )
       $}
    $}
  $}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Universal quantification}

Everyone in England is smart: 
$\forall x\per\ In(x,england) \rightarrow Smart(x)$

$(\forall x\per\ \phi)$ is equivalent to the \textit{conjunction} of
all possible \textit{instantiations} in $x$ of $\phi$:
\[
\begin{array}{rl}
     & In(kingJohn,england) \rightarrow Smart(kingJohn) \\
\land& In(richard,england) \rightarrow Smart(richard) \\
\land& In(england,england) \rightarrow Smart(england) \\
\land& \ldots
\end{array}\]

Typically, $\rightarrow$ is the main connective with $\forall$.\\
Common mistake: using $\land$ as the main connective with $\forall$:
\[\forall x\per\ In(x,england) \land Smart(x)\]
means ``Everyone is in England and everyone is smart''

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Existential quantification}

Someone in France is smart: 
$\exists x\per\ In(x,france) \land Smart(x)$

$(\exists x\per\ \phi)$ is equivalent to the \textit{disjunction} of
all possible \textit{instantiations} in $x$ of $\phi$
\[
\begin{array}{rl}
    & In(kingJohn,france) \land Smart(kingJohn) \\
\lor& In(richard,france) \land Smart(richard) \\
\lor& In(france,france) \land Smart(france) \\
\lor& \ldots
\end{array}\]

Typically, $\land$ is the main connective with $\exists$.\\
Common mistake: using $\rightarrow$ as the main connective with $\exists$:
\[\exists x\per\ In(x,france) \rightarrow Smart(x)\]
is true if there is anyone who is not in France!

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Properties of quantifiers}

$(\forall {x}\per\forall {y}\per\phi)$ is the same as
$(\forall {y\per}\forall {x}\per\phi)$ (Why?)

$(\exists {x}\per\exists {y}\per\phi)$ is the same as 
$(\exists {y}\per\exists {x}\per\phi)$ (Why?)

$(\exists {x}\per\forall {y}\per\phi)$ is {\bf not} the same as
$(\forall {y}\per\exists {x}\per\phi)$

$\exists {x}\per\forall {y}\per Loves(x,y)$\\
``There is a person who loves everyone in the world''

$\forall {y}\per\exists {x}\per Loves(x,y)$\\
``Everyone in the world is loved by at least one person'' 
\textit{(not necessarily the same\/)}

\textbf{Quantifier duality}: each can be expressed using the other:

$\forall {x}\per Likes(x,iceCream)$ \tab
$\lnot \exists {x}\per \lnot Likes(x,iceCream)$ 

$\exists {x}\per Likes(x,broccoli)$ \tab
$\lnot \forall {x}\per \lnot Likes(x,broccoli)$ 

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Equivalences}

\begin{eqnarray*}
(\forall x\per \phi) \wedge \psi & \equiv & 
\forall x\per (\phi \wedge \psi) \: \mbox{ if $x$
not free in}\: \psi  \\
(\forall x\per \phi) \vee \psi & \equiv & 
\forall x\per (\phi \vee \psi) \: \mbox{ if $x$
not free in}\: \psi  \\
(\exists x\per \phi) \wedge \psi & \equiv & 
\exists x\per (\phi \wedge \psi) \: \mbox{ if $x$
not free in}\: \psi  \\
(\exists x\per \phi) \vee \psi & \equiv & 
\exists x\per (\phi \vee \psi) \: \mbox{ if $x$
not free in}\: \psi  \\
\forall x\per \phi \wedge \forall x\per \psi & 
\equiv & \forall x\per (\phi \wedge \psi) \\
\exists x\per \phi \vee \exists x\per \psi & 
\equiv & \exists x\per (\phi \vee \psi) \\
\\
\neg \forall x\per \phi & \equiv & \exists x\per \neg \phi \\
\neg \exists x\per \phi & \equiv & \forall x\per \neg \phi \\
\lefteqn{\& \: \mbox{propositional equivalences}}
\end{eqnarray*}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{The Prenex Normal Form}

Quantifier prefix + (quantifier free) matrix 
\[\forall x_1 \forall x_2 \exists x_3  \ldots \forall x_n \phi\]

\begin{enumerate}
\item Elimination of $\rightarrow$ and $\leftrightarrow$
\item push $\neg$ inwards
\item pull quantifiers outwards
\end{enumerate}

\begin{tabular}{ll}
E.g. & $\tt \neg \forall x\per \:((\forall x\per \: p(x)) \rightarrow q(x))$ \\
     & $\tt \neg \forall x\per \:(\neg(\forall x\per \: p(x)) \vee q(x))$ \\
     & $\tt \exists x\per \: ((\forall x\per \: p(x)) \wedge \neg q(x)) $ \\
     & {\bf and now?} 
 \end{tabular}


{\bf Notation: renaming of variables.}
Let $\phi[x/t]$ be the formula $\phi$ where all occurrences of $x$ 
have been replaced by the term $t$.

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{The Prenex Normal Form: theorems}

{\bf Lemma.} 
Let $y$ be a variable that does not occur in $\phi$. \\
Then we have
$\forall x \phi \equiv (\forall x \phi)[x/y]$ and 
$\exists x \phi \equiv (\exists x \phi)[x/y]$.

{\bf Theorem.} 
There is an algorithm that computes for every formula
its prenex normal form.


\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


\begin{slide}{FOL at work: reasoning by cases}

$\Gamma =$
\parbox[t]{.7\textwidth}{\tt
FRIEND(john,susan) $\wedge$\\ 
FRIEND(john,andrea) $\wedge$\\
LOVES(susan,andrea) $\wedge$\\ 
LOVES(andrea,bill) $\wedge$\\
Female(susan) $\wedge$\\ 
$\neg$Female(bill)
}

%\vspace{2em}

{\tt\small
\setlength{\unitlength}{0.8em}
\begin{picture}(20,13)
\thinlines    \put(2,0){bill: $\neg$Female}
              \put(2,6){andrea}
              \put(12,6){susan: Female}
              \put(7.5,11.6){john}
              
              \put(3.5,5){\vector(0,-1){4}}
              \put(11,6.2){\vector(-1,0){4.5}}
              \put(7,11){\vector(-1,-1){4}}
              \put(10,11){\vector(1,-1){4}}
                            
              \put(1,9){FRIEND}
              \put(13,9){FRIEND}
              \put(7,6.6){LOVES}
              \put(4,3){LOVES}
\end{picture}}


\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\overlays{2}{
\begin{slide}{}

\vspace{-2em}
$\Gamma = $
{\tt\footnotesize
\setlength{\unitlength}{0.9em}
\begin{picture}(20,13)
\thinlines    \put(2,0){bill: $\neg$Female}
              \put(2,6){andrea}
              \put(12,6){susan: Female}
              \put(7.5,11.6){john}
              
              \put(3.5,5){\vector(0,-1){4}}
              \put(11,6.2){\vector(-1,0){4.5}}
              \put(7,11){\vector(-1,-1){4}}
              \put(10,11){\vector(1,-1){4}}
                            
              \put(1,9){FRIEND}
              \put(13,9){FRIEND}
              \put(7,6.6){LOVES}
              \put(4,3){LOVES}
\end{picture}}

%\vspace{3em}

Does John have a female friend loving a male (i.e. not female) person?

%\vspace{1em}
\fromSlide{2}{{\Large\begin{center}\color{blue}YES!\end{center}}}
%\vspace{1em}

$\Gamma\models$
  $\exists X,Y\per~$
\parbox[t]{.8\textwidth}{$
    {\tt FRIEND}({\tt john},X)\wedge {\tt Female}(X)\wedge \\
    {\tt LOVES}(X,Y)\wedge\neg{\tt Female}(Y)
    $}

\end{slide}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{}

\vspace{-2em}
{\tt\footnotesize
\setlength{\unitlength}{0.8em}
\begin{picture}(24,13)(-5,0)
\thinlines    \put(2,0){bill: $\neg$Female}
              \put(-5,6){\bf [$\neg$Female] andrea}
              \put(12,6){\bf susan: Female}
              \put(7.5,11.6){\bf john}
              
              \thinlines\put(3.5,5){\vector(0,-1){4}}
              \thicklines\put(11,6.2){\vector(-1,0){4.5}}
              \thinlines\put(7,11){\vector(-1,-1){4}}
              \thicklines\put(10,11){\vector(1,-1){4}}
                            
              \put(1,9){FRIEND}
              \put(13,9){\bf FRIEND}
              \put(6,6.6){\bf LOVES}
              \put(4,3){LOVES}
\end{picture}}

\vspace{4em}

{\tt FRIEND(john,susan), Female(susan), \\
LOVES(susan,andrea), $\neg$ Female(andrea)}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{}

\vspace{-2em}
{\tt\footnotesize
\setlength{\unitlength}{0.8em}
\begin{picture}(24,13)(-5,0)
\thinlines    \put(2,0){\bf bill: $\neg$Female}
              \put(-4,6){\bf [Female] andrea}
              \put(12,6){susan: Female}
              \put(7.5,11.6){\bf john}
              
              \thicklines\put(3.5,5){\vector(0,-1){4}}
              \thinlines\put(11,6.2){\vector(-1,0){4.5}}
              \thicklines\put(7,11){\vector(-1,-1){4}}
              \thinlines\put(10,11){\vector(1,-1){4}}
                            
              \put(-1,9){\bf FRIEND}
              \put(13,9){FRIEND}
              \put(7,6.6){LOVES}
              \put(4,3){\bf LOVES}
\end{picture}}

\vspace{4em}

{\tt FRIEND(john,andrea), Female(andrea), \\
LOVES(andrea,bill), $\neg$ Female(bill)}

\end{slide}

% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% \begin{slide}{Exercise}

% Write the possible models of the theory.

% \end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Theories and Models}

$\Gamma_1 =$
\parbox[t]{.8\textwidth}{
$
{\tt FRIEND(john,susan)\ \wedge } \\ 
{\tt FRIEND(john,andrea)\ \wedge } \\
{\tt LOVES(susan,andrea)\ \wedge } \\ 
{\tt LOVES(andrea,bill)\ \wedge } \\
{\tt Female(susan)\ \wedge } \\ 
{\tt Male(bill)\ \wedge } \\ 
\forall X\per\ {\tt Male}(X)\leftrightarrow \neg{\tt Female}(X)
$
}

%\vspace{2em}

{\tt\small
\setlength{\unitlength}{0.8em}
\begin{picture}(20,13)
\thinlines    \put(2,0){bill: Male} \put(14,0){Male$\doteq\neg$Female}
              \put(2,6){andrea}
              \put(12,6){susan: Female}
              \put(7.5,11.6){john}
              
              \put(3.5,5){\vector(0,-1){4}}
              \put(11,6.2){\vector(-1,0){4.5}}
              \put(7,11){\vector(-1,-1){4}}
              \put(10,11){\vector(1,-1){4}}
                            
              \put(1,9){FRIEND}
              \put(13,9){FRIEND}
              \put(7,6.6){LOVES}
              \put(4,3){LOVES}
\end{picture}}


\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{}

\vspace{-2em}
$\Gamma_1 = $
{\tt\footnotesize
\setlength{\unitlength}{0.9em}
\begin{picture}(20,13)
\thinlines    \put(2,0){bill: Male} \put(14,0){Male$\doteq\neg$Female}
              \put(2,6){andrea}
              \put(12,6){susan: Female}
              \put(7.5,11.6){john}
              
              \put(3.5,5){\vector(0,-1){4}}
              \put(11,6.2){\vector(-1,0){4.5}}
              \put(7,11){\vector(-1,-1){4}}
              \put(10,11){\vector(1,-1){4}}
                            
              \put(1,9){FRIEND}
              \put(13,9){FRIEND}
              \put(7,6.6){LOVES}
              \put(4,3){LOVES}
\end{picture}}

\vspace{1em}

Does John have a female friend loving a male person?

%\vspace{1em}

$\Gamma_1\models$
  $\exists X,Y\per~$
\parbox[t]{.8\textwidth}{$
    {\tt FRIEND}({\tt john},X)\wedge {\tt Female}(X)\wedge \\
    {\tt LOVES}(X,Y)\wedge{\tt Male}(Y)
    $}

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\overlays{3}{
\begin{slide}{}

{\footnotesize

\MiniPage{
$\Gamma =$
\parbox[t]{.9\textwidth}{\tt
FRIEND(john,susan) $\wedge$\\ 
FRIEND(john,andrea) $\wedge$\\
LOVES(susan,andrea) $\wedge$\\ 
LOVES(andrea,bill) $\wedge$\\
Female(susan) $\wedge$\\ 
$\neg$Female(bill)
}}
{\fromSlide{2}{\scriptsize
\noindent\parbox[t]{\textwidth}{
$\Delta=\{{\tt john,susan,andrea,bill}\}$\\
$\intf {\tt Female}=\{{\tt susan}\}$
}}
}

\vspace{1ex}

\MiniPage{
$\Gamma_1 =$
\parbox[t]{.8\textwidth}{
$
{\tt FRIEND(john,susan)\ \wedge } \\ 
{\tt FRIEND(john,andrea)\ \wedge } \\
{\tt LOVES(susan,andrea)\ \wedge } \\ 
{\tt LOVES(andrea,bill)\ \wedge } \\
{\tt Female(susan)\ \wedge } \\ 
{\tt Male(bill)\ \wedge } \\ 
\forall X\per\ {\tt Male}(X)\leftrightarrow \neg{\tt Female}(X)
$
}}
{\fromSlide{3}{\scriptsize\vspace{-2em}
\noindent\parbox[t]{\textwidth}{
$\Delta^{\I_1}=\{{\tt john,susan,andrea,bill}\}$\\
${\tt Female}^{\I_1}=\{{\tt susan,andrea}\}$\\
${\tt Male}^{\I_1}=\{{\tt bill,john}\}$
}\vspace{1em}\\
\noindent\parbox[t]{\textwidth}{
$\Delta^{\I_2}=\{{\tt john,susan,andrea,bill}\}$\\
${\tt Female}^{\I_2}=\{{\tt susan}\}$\\
${\tt Male}^{\I_2}=\{{\tt bill,andrea,john}\}$
}\vspace{1em}\\
\noindent\parbox[t]{\textwidth}{
$\Delta^{\I_1}=\{{\tt john,susan,andrea,bill}\}$\\
${\tt Female}^{\I_1}=\{{\tt susan,andrea,john}\}$\\
${\tt Male}^{\I_1}=\{{\tt bill}\}$
}\vspace{1em}\\
\noindent\parbox[t]{\textwidth}{
$\Delta^{\I_2}=\{{\tt john,susan,andrea,bill}\}$\\
${\tt Female}^{\I_2}=\{{\tt susan,john}\}$\\
${\tt Male}^{\I_2}=\{{\tt bill,andrea}\}$
}}
}
}
\end{slide}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{}


${\tt \Gamma\not\models Female(andrea)}$\\
${\tt \Gamma\not\models\neg Female(andrea)}$

\vspace{2em}

${\tt \Gamma_1\not\models Female(andrea)}$\\
${\tt \Gamma_1\not\models\neg Female(andrea)}$\\
${\tt \Gamma_1\not\models Male(andrea)}$\\
${\tt \Gamma_1\not\models\neg Male(andrea)}$

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{slide}{Exercise}

\includegraphics[width=.3\hsize]{block.eps}

\vspace{2em}

Is it true that the top block is on a white block touching a black block?

\end{slide}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%% 
 % \begin{slide}{}
 % 
 % \slideheading{Undecidability of reasoning in FOL}
 % 
 % {\bf Theorem} ({\em Undecidability of FOL})
 % It is undecidable whether $\models \phi$.
 % 
 % {\bf Corollary} The set of satisfiable formulas in PL1 is not recursively
 % enumerable.
 % 
 % \end{slide}
 %%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\end{document}
