Q: ECLiPSe, fd_sets 
Author Message
 Q: ECLiPSe, fd_sets

Hi everybody,

I'm about to start a larger programming project.  I think that ECLiPSe
is a
good choice because of its constraint solvers.  To make sure I get
everything
right, I first want to ask some questions.

Without going into much detail, the aim of the program is to construct a
solution of a larger problem via a fixpoint computation: This solution
consists of small pieces which can be seen as solutions to constraint
satisfaction problems over finite sets of objects.  To find a solution
to the
global problem, the program incrementally constructs such CSPs until
``saturation''.  Every solution to such a CSP is a piece of the global
solution.  

Instead of labeling the solutions to these CSPs, I think of keeping the
variables and constraints, such that each valid instantiation of the
variables
represents a piece of the global solution.  Therefore, the fd_sets
library of
ECLiPSe seems the right environment to work with.

My problem is that additional parts of the global solution can be found
by
extending such CSPs - adding new variables and imposing corresponding
constraints.  Therefore, CSPs are a part of the global solution and the
base
for various new CSPs at the same time: I think I need a way to copy
CSPs!

Is it possible copy a set of variables together with their imposed
constraints?  Is it advised to do so?  

I would be grateful for any comment.

Uli

--
Ulrich Scholz


http://www.*-*-*.com/ ~scholz/



Sat, 08 May 2004 00:32:48 GMT  
 Q: ECLiPSe, fd_sets

Quote:

> Without going into much detail, the aim of the program is to construct a
> solution of a larger problem via a fixpoint computation: This solution
> consists of small pieces which can be seen as solutions to constraint
> satisfaction problems over finite sets of objects.  To find a solution
> to the
> global problem, the program incrementally constructs such CSPs until
> ``saturation''.  Every solution to such a CSP is a piece of the global
> solution.

> Instead of labeling the solutions to these CSPs, I think of keeping the
> variables and constraints, such that each valid instantiation of the
> variables
> represents a piece of the global solution.

I've read this several times, but I don't understand what you mean.
Can you try to explain the declarative and the algorithmic aspects
separately?

Quote:
>  Therefore, the fd_sets library of
> ECLiPSe seems the right environment to work with.

This choice seems unrelated to what you are discussing above.
You should use this library simply when you want to model your
problem in terms of sets and constraints over sets.

Quote:
> Is it possible copy a set of variables together with their imposed
> constraints?  Is it advised to do so?

I would not recommend it because there is no easy way to
specify which subset of the constraints you want.
Instead, you should just run the constraint-setup-code twice
to get another instance of the constraint network with new
variables:

?- setup_constraints(Variables1),
   setup_constraints(Variables2),
   ...

You could speed that up by taking advantage of the propagation
results that you got the first time: copy the first set of variables
(with their already reduced domains, but without the constraints),
and setup the second set of constraints on these copies:

?- setup_constraints(Variables1),
   copy_term(Variables1, Variables2),
   setup_constraints(Variables2),
   ...

--
 Joachim Schimpf              /             phone: +44 20 7594 8187

 London SW7 2AZ, UK         /    http://www.icparc.ic.ac.uk/eclipse



Wed, 12 May 2004 03:01:43 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Eclipsing Eclipse - Rescheduled

2. Eclipsing Eclipse

3. ECLiPSe 3.5.1 / Parallel ECLiPSe

4. several Qs

5. Qs on CLUBMGR, Template BUG ???

6. Qs

7. Qs about language nomenclature

8. New newbies Qs on Ruby

9. Newbie Qs: startup time, Module.constants, chdir, Ruby distro's library

10. Qs on Ruby and DbC/Smalltalk

11. 2 Qs: IndexedFaceSets & browsers

12. Qs re 'Write & 'Read

 

 
Powered by phpBB® Forum Software