update
[ker1415-1.git] / report / ass1.tex
index 7826f14..4fb5b57 100644 (file)
@@ -1,3 +1,4 @@
+\newpage
 \subsection{Part 1: Modelling Sokoban}
 \subsubsection{Task 1: Knowledge base}
 \begin{itemize}
                                        agent(x, s))\\
                                        crate(x, y, result(A, s)) & \rightarrow\\
                                & (\exists z,\alpha:
-                                       A = push(z, \alpha),
-                                       (\exists \beta:
-                                               connected(z, \beta, \alpha),
-                                               connected(\beta, y, \alpha),
-                                               crate(x, \beta, s)
+                                       A = push(z\wedge \alpha)\wedge\\
+                               &       (\exists \beta:
+                                               connected(z\wedge \beta\wedge \alpha)\wedge
+                                               connected(\beta\wedge y\wedge \alpha)\wedge
+                                               crate(x\wedge \beta\wedge s)
                                        )
                                ) \vee\\
                                & (\exists z,\alpha:
                \end{array}$
 \end{itemize}
 
+\newpage
 \subsection{Part 2: Implementation}
 \subsubsection{Task 3: Translate Axioms}
 The only optimization added to the file is the reverse move optimization,
@@ -128,7 +130,16 @@ disallowing the agent to reverse a move immediatly.
 \end{listing}
 
 \subsubsection{Task 6: Inverse Problem}
+\begin{listing}[H]
+       \caption{Instance description task 6}
+       \prologcode{./src/instancetask6.pl}
+\end{listing}
+\begin{listing}[H]
+       \caption{Domain description task 6}
+       \prologcode{./src/domaintask6.pl}
+\end{listing}
 
+\newpage
 \subsection{Part 3: Extending the domain}
 \subsubsection{Task 7: Unlocking the Crates}
 \begin{listing}[H]
@@ -140,6 +151,7 @@ disallowing the agent to reverse a move immediatly.
        \prologcode{./src/domaintask7.pl}
 \end{listing}
 
+\newpage
 \subsection{Part 4: General questions}
 \subsubsection{Task 10: Sitcalc expressivity}
 Situation calculus(sitcalc from now on) is very expressive because you can