[gecode-users] std::set to Gecode::IntVar conversion

Martin Mann mmann at informatik.uni-freiburg.de
Wed May 10 23:40:41 CEST 2006


Moin Christian,

mhh.. ok I ll have a look if I can write a worthy conversion! ;)
Will have to have a deeper look into IntVar implementations..

Are there any predefined initialisation possibilities in addition to the
"min-max" range init?

Meanwhile, I am looking for set operations for IntSet variables like union
or intersection.
I am used to them by Mozart or Ilog. Are they available in Gecode?

Thanks for your help

Martin


----- Original Message ----- 
From: "Christian Schulte" <schulte at imit.kth.se>
To: "'Martin Mann'" <qyu at gmx.de>; <users at gecode.org>
Sent: Wednesday, May 10, 2006 10:21 PM
Subject: RE: [gecode-users] std::set to Gecode::IntVar conversion


Hi Martin,

unfortunately there is no such thing... Actually, Gecode does not use much
from the C++ standard library so as to give uniform behavior across the
platform it runs on (and with the same performance). So you are on your own!
But if you do anyhting you feel worth being included in Gecode, please let
us know.

Christian

PS: Just create an array (preferably of ranges, that is: intervals), the
contructors of IntSet anyhow are expensive as they convert the set into some
normal form.

--
Christian Schulte, http://www.imit.kth.se/~schulte/

-----Original Message-----
From: users-bounces at gecode.org [mailto:users-bounces at gecode.org] On Behalf
Of Martin Mann
Sent: Wednesday, May 10, 2006 6:27 PM
To: users at gecode.org
Subject: [gecode-users] std::set to Gecode::IntVar conversion


Hi

is there a predefined possibility to initialise an IntVar with the data
of a std::set variable? Or just a nice/fast workaround?

I found an initialisation via IntSet, that can be constructed by an int
array. But that doesnt help, because there is no well conversion from
std::set to int[].

Or is there a std::OutputIterator derived iterator class for IntVar, so
I can use std::copy? I only found IntVarValues but the usage is not the
standard iterator behavior.

Thanks for help!

Martin

_______________________________________________
Gecode users mailing list
users at gecode.org https://www.gecode.org/mailman/listinfo/gecode-users





More information about the gecode-users mailing list