next up previous contents
Next: FD Accessors Up: FUF: the Universal Unifier Previous: Control

Manipulation of FDs as Data-structures

FDs can be viewed as a convenient data-structure. FUF provides a library of Lisp functions to manipulate FDs: accessors to extract a sub-fd from a total fd, insertion of an FD within a total FD, etc. These functions' main complexity lies in the interpretation of paths. For example, if you want to extract a sub-fd from a total fd, and this sub-fd contains path pointing outside the sub-fd up into the total fd, the extraction function should also extract these paths. In addition, relative paths in the sub-fd must be adjusted to maintain consistency.

Another class of functions helps in manipulating lists of FDs and FDs as lists (providing programmatically the same facilities as the ~, ^n~ and ~n notations discussed in Chapter [*] p.[*]).

 

In this chapter, the notion of total FD plays a critical role. A total FD is a self-contained FD, which appears at the top level and is not supposed to be embedded in another FD. All the paths appearing within this FD are interpreted relative to the total FD. In logical terms, a total FD is a universe of reference for FUF and in programming language terms, a total FD is an environment.



 
next up previous contents
Next: FD Accessors Up: FUF: the Universal Unifier Previous: Control
Michael Elhadad - elhadad@cs.bgu.ac.il