[gecode-users] Classify the solutions

Christian Schulte cschulte at kth.se
Mon Sep 29 11:06:12 CEST 2014


Please read about branchers in MPG: they are used in the order in which they
are posted.

 

Christian

 

--

Christian Schulte, Professor of Computer Science, KTH,
www.gecode.org/~schulte/

 

From: mehdi m [mailto:medistif at hotmail.fr] 
Sent: Monday, September 29, 2014 11:05 AM
To: users at gecode.org; cschulte at kth.se
Subject: RE: [gecode-users] Classify the solutions

 

Hi,

 

How can i branch the "sum" variable over the variable that represent the
vector of solutions ?

 

Thanks.

  _____  

From: cschulte at kth.se
To: medistif at hotmail.fr; users at gecode.org
Subject: RE: [gecode-users] Classify the solutions
Date: Mon, 29 Sep 2014 10:43:12 +0200

Hi,

 

What you could do is adding a "sum" variable and branch over the variable so
that values are tried in increasing order. Then the solutions will be found
in that order.

 

Best

Christian

 

--

Christian Schulte, Professor of Computer Science, KTH,
www.gecode.org/~schulte/

 

From: users-bounces at gecode.org [mailto:users-bounces at gecode.org] On Behalf
Of mehdi m
Sent: Monday, September 29, 2014 10:09 AM
To: users at gecode.org
Subject: [gecode-users] Classify the solutions

 

Hello, 

i'm building a model , and the solutions are vectors like this "3 5 9 4 7",
i have an constraint that express the sum of the vectors must to be > than
an threshold M. 

My question is can i add an constraint or any parameter to tell to gecode :
the solutions returned must be ordered according to a criterion, for example
from the smallest to the largest sum.

 

Thank you for your help

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20140929/e96173f1/attachment-0001.html>


More information about the users mailing list