Re: [eclipse-clp-users] Error in the code of my Problem

From: Meriem Djefel <Meriem.DJEFEL_at_...178...>
Date: Tue, 23 Mar 2010 11:00:20 +0100
Thanks for your answer.

My program goal is to  find the different possibles configuration of an 
aircraft (just some components)
I had correct the problem with the domain of moteurs but I still have 
the same error,
I did'nt understand the difference between (->) and ( *->) : I tray to 
add a constraint when the condition were verified.

Le 22/03/2010 18:53, Kish Shen a écrit :
> Sorry for the delay in replying -- I have been a little busy...
> Meriem Djefel wrote:
>>> In your message, you do not give any details of how to run your 
>>> program, or what the errors are. I don't think you should just ask 
>>> the users in the mailing to fix your problem, without even 
>>> describing it or how to run your program. Therefore,  can you please 
>>> send a new message with more description of your problem.
>> *I run my programm with :*
>> avionTourismeSol(Sol)*when I want to have all the solution of the 
>> problem or with
>> *avionTourisme(CS, FR, EN,SN, ST)*when I just want to have a solution*.
> You still did not say what your problem is. When I run your program as 
> you suggest, I get an error message about arguments having different 
> domains for the constraint:
> V &= deux_Mot_LP
> This is because deux_Mot_LP is *not* one of the symbolic domains you 
> defined for moteur.
> This should be quite easy to see from the error message. Is this your 
> problem, or are you thinking of something else?
>>> Several points about your program: you are using the soft-cut (*->), 
>>> This is a very dangerous thing to use, and so should be avoided, 
>>> especially if you do not know absolutely what you are doing. 
>>> Secondly, why are you using $ family of constraints?  ($= etc.), 
>>> these are for continous ranges (real values), but you seem to be 
>>> working with integer values only (i.e. finite domain), even when you 
>>> specify real values, they are integral.
>> *I use (* ->) to add a new constraint to the problem when a condition 
>> where checked **, I want to simulate a DCSP , I don't think that 
>> adding variables is possible but I want to add constraints*.
>> *For using ($ =etc.) , I thinck you are right in this example I am 
>> using only finite domain. *
> I still don't understand why you are using *-> instead of ->: you 
> almost never want to backtrack into the condition. I assume you know 
> that if-then-else (Cond -> Then ; Else) (the same applies to *->) does 
> not behave in a constraint like manner?
> Cheers,
> Kish

Received on Tue Mar 23 2010 - 10:01:19 CET

This archive was generated by hypermail 2.3.0 : Tue Aug 20 2019 - 00:14:49 CEST