Comment by cubefox
3 months ago
There seems to an interesting difference between Prolog and conventional (predicate) logic.
In Prolog, anything that can't be inferred from the knowledge base is false. If nothing about "playsAirGuitar(mia)" is implied by the knowledge base, it's false. All the facts are assumed to be given; therefore, if something isn't given, it must be false.
Predicate logic is the opposite: If I can't infer anything about "playsAirGuitar(mia)" from my axioms, it might be true or false. It's truth value is unknown. It's true in some model of the axioms, and false in others. The statement is independent of the axioms.
Deductive logic assumes an open universe, Prolog a closed universe.
This is called the Closed World Assumption (CWA) - https://en.wikipedia.org/wiki/Closed-world_assumption
Prolog’s Closed-World Assumption: A Journey Through Time - https://medium.com/@kenichisasagawa/prologs-closed-world-ass...
Is Prolog really based on the closed-world assumption? - https://stackoverflow.com/questions/65014705/is-prolog-reall...
It's not really false I think. It's 'no', which is an answer to a question "Do I know this to be true?"
I think there should be a room for three values there: true, unprovable, false. Where false things are also unprovable. I wonder if Prolog has false, defined as "yes" of the opposite.
> It's not really false I think. It's 'no', which is an answer to a question "Do I know this to be true?"
I don't think so, because in this case both x and not-x could be "no", but I think in Prolog, if x is "no", not-x is "yes", even if neither is known to be true. It's not a three-valued logic that doesn't adhere to the law of the excluded middle.
If x is "no" (I do not know this to be true) then not-x is "yes" (I do know this to be true). So negation still works as usual.
"Yes" is not "true" but rather "provably true". And "no" is not "false" but rather "not provably true".
Third sensible value in this framework (which I think Prolog doesn't have) would be "false" meaning "it's provably false" ("the opposite of it is provably true").
To be frank I think Prolog in newer implementations completely abandoned this nuance and just call states "true" and "false" instead of "yes" and "no".
2 replies →