%% Style file for Poole & Mackworth "Artificial Intelligence" Beamer Presentations
\usepackage[noend]{algpseudocode} % see algorithmicx package & end of aimemior.sty


%\usepackage{beamerthemesplit}
\usecolortheme{whale}
\useoutertheme{split}
\usefonttheme[onlysmall]{structurebold}
%\setbeamerfont{itemize subsubitem}{size=\large}
%\setbeamerfont{itemize subitem}{size=\large}
%\usepackage{dpstandard}
\usepackage{graphicx}
\DeclareGraphicsExtensions{.pdf}
\usepackage{pifont}

\setbeamertemplate{navigation symbols}{\insertslidenavigationsymbol}


\newcommand{\cislide}[3]{
\title{Artificial Intelligence, Lecture #1.#2, Page \thepage}
}
\author{\copyright D. Poole and A. Mackworth  2010}
\date{\today}
\newcommand{\slhead}{\frametitle}

% Highlights.
\definecolor{purple}{rgb}{1,0,1}
\definecolor{dred}{rgb}{0.7,0,0}
\definecolor{myred}{rgb}{1,0,0}
\definecolor{dblue}{rgb}{0,0,0.7}
\definecolor{dgreen}{rgb}{0,0.5,0}
\definecolor{myyellow}{rgb}{1,1,0}
% \hilitea{text} highlights text (for short text)
\newcommand{\hilitea}[1]{\colorbox{dblue}{\color{myyellow} #1}}
\newcommand{\hiliteb}[1]{\colorbox{myyellow}{\color{dred} #1}}
\newcommand{\hilitec}[1]{\colorbox{myyellow}{\color{dgreen} #1}}
\newcommand{\keyword}[1]{\hiliteb{#1}}

% \hiliteap{text} highlights text in a paragraph (for long text)
\newcommand{\hiliteap}[1]{\hilitea{\parbox[t]{0.9\textwidth}{#1}}}
\newcommand{\hilitebp}[1]{\hiliteb{\parbox[t]{0.9\textwidth}{#1}}}
\newcommand{\hilitecp}[1]{\hilitec{\parbox[t]{0.9\textwidth}{#1}}}
% \newcommand{\hilitea}{\emph}   % main highlight
% \newcommand{\hiliteap}{\emph}
% \newcommand{\hiliteb}{\emph}   % main highlight
% \newcommand{\hilitebp}{\emph}
% \newcommand{\hilitec}{\emph}   % secondary highlight
% \newcommand{\hilitecp}{\emph}

\newenvironment{slide}{\begin{frame}}{\end{frame}}

\newcommand{\barrow}{\mbox{\color{red}$\Longrightarrow$}}

% these are taked from dpstandard.sty
\newenvironment{pcode}{\begin{tabbing}
 \hspace*{8mm}\=\hspace*{8mm}\=\hspace*{8mm}\=\hspace*{8mm}\=
 \hspace*{8mm}\=\hspace*{8mm}\=\hspace*{8mm}\=\hspace*{8mm}\=
 \hspace*{8mm}\=\hspace*{8mm}\=\kill}{\end{tabbing}}
\newcommand{\pcodecomm}[1]{\parbox{\columnwidth}{{\em \{#1\}}}}
\newcommand{\tuple}[1]{\left<#1\right>}
\newcommand{\triple}[1]{\left<#1\right>}
\newcommand{\stuple}[1]{\langle #1\rangle}
\newcommand{\AND}{\wedge \mbox{}}
\newcommand{\OAND}{\:\&\:}
\newcommand{\OANDsymb}{\&}
\newcommand{\IF}{\leftarrow \mbox{}}
\newcommand{\IFF}{\leftrightarrow \mbox{}}
\newcommand{\OIF}{\Leftarrow \mbox{}}
\newcommand{\is}{\mbox{ is }}
\newcommand{\negn}{\mbox{$\sim$}}
\newcommand{\notmodels}{\not\models}
\newcommand{\WHY}{\mbox{\small WHY}}
\newcommand{\HOW}{\mbox{\small HOW}}
\newcommand{\WHYNOT}{\mbox{\small WHYNOT}}
\newcommand{\D}{\mathbf{D}}              % was \mathcal{D}
\newenvironment{code}{\begin{eqnarray*}}{\end{eqnarray*}} %conflicts
                                %with hyperlatex
\newenvironment{cicode}{\begin{eqnarray*}}{\end{eqnarray*}} %conflicts
                                %with hyperlatex
\newcommand{\head}[1]{\lefteqn{{%\mathit
        {#1}}}}
\newcommand{\body}[1]{&&{%\mathit
        {#1}}}
\newcommand{\uri}[1]{\ensuremath{\triple{\mbox{\textsf{#1}}}}}
\newcommand{\uriabbr}[1]{\mbox{\textsf{#1}}}

\newenvironment{myitemize}%    possibly close together top-level itemized list
   {\begin{itemize}}%
   {\end{itemize}}
\newenvironment{commentpar}{\begin{flushleft}\%}{\end{flushleft}}
 
\newcommand{\parents}[1]{parents(#1)}
\setbeamertemplate{itemize item}[ball]
%\setbeamercolor{itemize subitems}[triangle]

% Local additions to the algpseudocode package which is part of the
% algorithmicx package 
% \algblock{Inputs}{EndInputs}
% \algnotext{Inputs}
% \algnotext{EndInputs}
% \algloop{Output}
% \algblock[Output]{Outputs}{EndOutputs}
% \algnotext{EndOutputs}
% \algrenewtext{Outputs}{\textbf{Output}}
% \algblock{Local}{EndLocal} 
% \algnotext{EndLocal}
% \algblockdefx{ForEach}{EndForEach}[1]{\textbf{for each} #1
%   \textbf{do}}{\textbf{end for each}}
% \algblockdefx{RepeatTimes}{EndRepeatTimes}[1]{\textbf{repeat} #1
%   \textbf{times}}{\textbf{end repeat}}
% \algblockdefx{RepeatForever}{EndRepeatForever}{\textbf{repeat forever}}{\textbf{end repeat}}
% \algblockdefx{Either}{EndEither}{\textbf{either}}{\textbf{end either}}
% \algcblock{Either}{Or}{EndEither}
\newcommand{\textprocedure}[1]{\textit{{#1}}} % for procedure headers
\algrenewcommand\textproc{\textprocedure}
\algblock{Inputs}{EndInputs}
\algnotext{EndInputs}
\algloop{Output}
\algblock[Output]{Outputs}{EndOutputs}
\algnotext{EndOutputs}
\algrenewtext{Outputs}{\textbf{Output}}
\algblock{Local}{EndLocal} 
\algnotext{EndLocal}
\algblockdefx{ForEach}{EndForEach}[1]{\textbf{for each} #1
  \textbf{do}}{}%{\textbf{end for each}}
\algnotext{EndForEach}
\algblockdefx{RepeatTimes}{EndRepeatTimes}[1]{\textbf{repeat} #1
  \textbf{times}}{\textbf{end repeat}}
\algnotext{EndRepeatTimes}
\algblockdefx{RepeatForever}{EndRepeatForever}{\textbf{repeat}}{\textbf{until} termination}
%\algnotext{EndRepeatForever}
\algblockdefx{RepeatForAWhile}{EndRepeatForAWhile}{\textbf{repeat}}{\textbf{until} termination}
%\algnotext{EndRepeatForAWhile}
\algblockdefx{Either}{EndEither}{\textbf{either}}{\textbf{end either}}
\algcblock{Either}{Or}{EndEither}
\algnotext{EndEither}
\algblockdefx{NonDetProc}{EndNonDetProc}[2]{\textbf{non-deterministic procedure} \textprocedure{#1}(#2)}{}%{\textbf{end for each}}
\algnotext{EndNonDetProc}
\algblockdefx{Controller}{EndController}[2]{\textbf{controller} \textprocedure{#1}(#2)}{}%{\textbf{end for each}}
\algnotext{EndController}

\renewcommand{\algorithmicindent}{3em}
\newcommand{\I}{}
\newcommand{\II}{}
\newcommand{\III}{}
\newcommand{\IIII}{}
\newcommand{\IIIII}{}
\newcommand{\IIIIII}{}
\newcommand{\IIIIIII}{}
