The fd.pl library can be used as a basis for further
extensions.
There are several hooks that make the interfacing easier:
Each time a new domain variable is created, either
in the ::/2 predicate or by giving it a default domain
in a rational arithmetic expression, the predicate new_domain_var/1
is called with the variable as argument.
Its default definition does nothing. To use it,
it is necessary to redefine it, i.e. to recompile it
in the fd module, e.g. using compile/2
or the tool body of compile_term/1.
Default domains
are created in the predicate default_domain/1
in the fd module, its default definition is
default_domain(Var) :- Var :: -10000000..10000000.
It is possible to change default domains by redefining
this predicate in the fd module.