From a6991c1e2576cbf38a4fb66dc6ac1d821c72bc86 Mon Sep 17 00:00:00 2001 From: Mart Lubbers Date: Tue, 20 Jan 2015 11:38:53 +0100 Subject: [PATCH] ding --- report/ass2-1.tex | 2 +- report/src/burglary.ail | 36 ++++++++++++++---------------------- report/src/pizza.ail | 5 +++++ 3 files changed, 20 insertions(+), 23 deletions(-) create mode 100644 report/src/pizza.ail diff --git a/report/ass2-1.tex b/report/ass2-1.tex index ea6f097..18639be 100644 --- a/report/ass2-1.tex +++ b/report/ass2-1.tex @@ -174,4 +174,4 @@ can prefer the \textit{AILog} method when speed is of an essence. When precision is necessary manual calculation is preferred. \section{Burglary problem with extended information} - +$\frac{1}{1000}+\frac{9999}{10000}\frac{1}{10000}+\frac{9999}{10000}\frac{9998}{9999}\frac{1}{19998}$ diff --git a/report/src/burglary.ail b/report/src/burglary.ail index 482efed..478d0e3 100644 --- a/report/src/burglary.ail +++ b/report/src/burglary.ail @@ -1,24 +1,16 @@ -prob joeW: 5/7. -prob williamW: 5/7. -prob jackW: 5/7. -prob averallW: 5/7. +prob joe: 5/7. +prob william: 5/7. +prob jack: 5/7. +prob averall: 5/7. -works(joe) <- joeW. -works(william) <- williamW. -works(jack) <- jackW. -works(averall) <- averallW. +joeWorks <- joe. +jackWorks <- jack & joe. +williamWorks <- william. +averallWorks <- averall & jack & william. -needs(joe, []). -needs(william, []). -needs(jack, [joe]). -needs(averall, [jack, william]). - - -burgels(X) <- - works(X) & needs(X, Needs) & forall(member(Burgel, Needs), member(Burgel, Workers)). - -%burgels(X) <- -% works(X) & findall(Y, works(Y), Workers) & -% needs(X, Needs) & forall(member(Burgel, Needs), member(Burgel, Workers)). - -%findall(X, burgels(X), L) & length(L, LX) & LX > 1. +burglary <- joeWorks & jackWorks. +burglary <- joeWorks & williamWorks. +burglary <- joeWorks & averallWorks. +burglary <- jackWorks & williamWorks. +burglary <- jackWorks & averallWorks. +burglary <- williamWorks & averallWorks. diff --git a/report/src/pizza.ail b/report/src/pizza.ail new file mode 100644 index 0000000..75fbb04 --- /dev/null +++ b/report/src/pizza.ail @@ -0,0 +1,5 @@ +% Margarita : cheese, tomatosauce. +% Hawaii : cheese, tomatosauce, ham, pineapple. +% Salami : cheese, tomatosauce, salami. +% Funghi : cheese, tomatosauce, mushrooms, ham(50%). +% Pepperoni : cheese, tomatosauce, salami, jalapeños. -- 2.20.1