Re: [eclipse-users] How to remember last variable value and then choose in search

From: Helmut Simonis <h.simonis_at_...70...>
Date: Thu, 21 Feb 2008 10:44:29 -0000

Tentative values in the repair library should be able to handle your
problem. Alternatively, you can do the search not on a list of variables,
but on a list of terms(Id,Var) where Id is an id (say a number), identifying
the problem variable, and Var is the variable itself. You can then lookup
the old value under the id. This will handle dynamic variable selection as



4C, University College Cork, Ireland

-----Original Message-----
From: eclipse-users-bounces+h.simonis=4c.ucc.ie_at_...2...
[mailto:eclipse-users-bounces+h.simonis=4c.ucc.ie_at_...2...] On Behalf
Of Daniel Lucraft
Sent: 21 February 2008 10:07
To: eclipse-users_at_...2...
Subject: [eclipse-users] How to remember last variable value and then choose
in search


If anyone could help me it would be much appreciated. 

I'm solving a problem repeatedly using Ic. I'd like to
 remember the previous solution, and then write a
'choice' predicate I can pass to search that begins by
choosing the value from the previous solution.
Hopefully that will speed things up.

Not sure how to do this. After the search has
completed, the program backtracks, uninstantiating the
solution variables, before applying a new constraint
and re-solving. So I suppose I need to save the result
in nonlogical storage, but how to look up the value
when all the choice predicate gets given is the


Daniel Lucraft
Imperial College London

ECLiPSe-Users mailing list
Received on Thu Feb 21 2008 - 10:44:58 CET

This archive was generated by hypermail 2.3.0 : Sat Aug 24 2019 - 06:15:04 CEST