Loading...
Please wait, while we are loading the content...
Similar Documents
The XSB System Version 2.5 Volume 1: Programmer's Manual
| Content Provider | Semantic Scholar |
|---|---|
| Author | Sagonas, Konstantinos F. Swift, Terrance Warren, David Scott Freire, Juliana Rao, Prasad Cui, Baoqiu Johnson, Ernie Castro, Luís Miguel De Dawson, Steve Kifer, Michael |
| Copyright Year | 2003 |
| Abstract | ly, a table can be seen as a set of entry triples 〈S,A, Status〉 where S is a subgoal, A is its associated answer set, and Status its status — whether it is complete or incomplete. In terms of implementation, “the table” is actually a set of mini-tables, each one containing entries for a particular predicate. Hence, we may refer to the table containing entries for some predicate p/n as “the table for p/n.” Further recall that a particular predicate may be evaluated according to either a variant or subsumptive strategy as chosen by the user. Invocation of a call during an evaluation leads to the classification of the call, as well as its possible insertion into the table. Each call can be classified as either (a) a generator, or producer, of an answer set, or (b) a consumer of the answer set of some subgoal in the table. Creation of a table entry thus relies not only on the call and on the subgoals already present in the table, but also upon whether call-variance or call-subsumption is used (cf. [37]). Answers, Returns, and Templates Given a table entry (S,A, Status), the set of variables in S is sometimes called the substitution factor of S. The order of arguments in the substitution factor corresponds to the order of distinct variables in a left-to-right traversal of S. Each answer in A substitutes values for the variables in the substitution factor of S; this substitution is sometimes called an answer substitution. The table inspection predicates allow access to substitution factors and answer substitutions through a family of terms whose principle functors are ret/n, where n is the size of the substitution factor. Example 6.15.1 Let S = p(X,f(Y)) be a producer subgoal (or simply, a subgoal if callvariance is used). Using the ret/nnotation, the substitution factor can be depicted as ret(X,Y), while the answer substitution {X=a,Y=b} is depicted as ret(a,b). Note that the application of the answer substitution to the producer subgoal yields the answer p(a,f(b)). To take a slightly more complex example, consider the subgoal q(X) where X is an attributed variable whose attribute is f(Z,Y,Y). In this case the substitution factor is ret(X,Z,Y). |
| File Format | PDF HTM / HTML |
| Alternate Webpage(s) | https://www.cse.buffalo.edu//~chomicki/636/xsb/manual1.pdf |
| Alternate Webpage(s) | http://www.cs.sunysb.edu/~sbprolog/manual/manual1.ps.gz |
| Alternate Webpage(s) | https://www.uow.edu.au/~markus/teaching/CSCI337/XSBManual1.pdf |
| Language | English |
| Access Restriction | Open |
| Content Type | Text |
| Resource Type | Article |