Suppose I have a knowledge base
likes(john,mary).
person(mary).
person(john).
If we ask for a prologue, <
|?- likes(mary,john)
He will answer no , because we did not state this. Is there a way to make the prolog request unknown if we do not explicitly specify.
\+ likes(mary,john)
In other words, we can ask the prologue to treat unrelated expressions as possible, rather than false ones. I use the IDP system, which allows for existential quantification and considers unapproved relationships as if connected, rather than false, but I would like to use something more basic.
http://adams.cs.kuleuven.be/idp/server.html
For example, in IDP you can make a statement
vocabulary V{
type Person
Likes(Person,Person)
}
theory T: V{
//Everyone might like someone and disallow narcisiscm
}
//some instance without special meaning
structure S:V{
Person={A..C}
}
procedure main(){
//Print all possible solutions
printmodels(allmodels(T,S))
}
What gives
Number of models: 27
Model 1
=======
structure : V {
Person = { "A"; "B"; "C" }
Likes = { "A","B"; "A","C"; "B","A"; "B","C"; "C","A"; "C","B" }
}