-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing halting tests and adding a universal quantified version
- Loading branch information
Showing
3 changed files
with
46 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>. | ||
@prefix log: <http://www.w3.org/2000/10/swap/log#>. | ||
@prefix : <urn:example:>. | ||
|
||
:T1 a :Test . | ||
|
||
# Generate an endless loop... | ||
# _:B is a universal quantifier | ||
(_:A _:B) log:onNegativeSurface { | ||
_:A a :Test . | ||
|
||
() log:onNegativeSurface { | ||
_:B a :Test . | ||
_:A :child _:B . | ||
}. | ||
}. | ||
|
||
# But provide a condition when the loop could generate a result | ||
(_:S1 _:S2 _:S3 _:S4 _:S5 _:S6 _:S7 _:S8 _:S9) log:onNegativeSurface { | ||
:X a :Test . | ||
:X :child _:S1 . | ||
_:S1 :child _:S2 . | ||
_:S2 :child _:S3 . | ||
_:S3 :child _:S4 . | ||
_:S4 :child _:S5 . | ||
_:S6 :child _:S7 . | ||
_:S7 :child _:S8 . | ||
_:S8 :child _:S9 . | ||
_:S9 a :Test . | ||
() log:onNegativeSurface { | ||
:test :is true. | ||
}. | ||
}. | ||
|
||
() log:onNegativeSurface { | ||
:test :is true. | ||
() log:onNegativeAnswerSurface { | ||
:test :is true. | ||
} | ||
}. |