[gecode-users] splitting branching in full enumeration and first-fail check

Martin Mann mmann at informatik.uni-freiburg.de
Mon Jan 28 10:36:00 CET 2013


Great! Thanks Christian!

Had a look into MPG yesterday but somehow skipped it.. Thanks for the 
help and exactly the piece of code I was looking for! :)

If I am right the following statements at the end of my Space 
constructor should do right?

   branch( *this, A, ..);
   assign( *this, B, ..);

So the overall reported solutions should show all valid assignments for 
A but for each only one valid assignment for B, right?

Please let me know if I am wrong and thanks again for the quick help!

Cheers,
Martin



Am 28.01.2013 10:00, schrieb Christian Schulte:
> That should be easy enough: set up a search engine with branching on A.
> Suppose you get a solution there (a space): then post the simple assignment
> branching on B on use a different search engine to find a solution there.
>
> You might want to read about assignment branchings in MPG.
>
> Best
> Christian
>
> --
> Christian Schulte, www.ict.kth.se/~cschulte/
>
>
> -----Original Message-----
> From: users-bounces at gecode.org [mailto:users-bounces at gecode.org] On Behalf
> Of Martin Mann
> Sent: Sunday, January 27, 2013 12:09 PM
> To: gecode user list
> Subject: [gecode-users] splitting branching in full enumeration and
> first-fail check
>
>
> Dear Gecoders,
>
> I am working on a small problem where the CSP variables are split into two
> subsets A and B.
>
> For set A, a full enumeration of all valid assignments is wanted while for
> set B a single check for a valid assignment is sufficent.
>
> Some years ago with Gecode 1.3 I wrote my own branching that did the latter
> part.
> Thus, first normal branch on A followed by pseudo-branching on B. The latter
> stopped the subsearch for B after the first solution was found such that the
> search in A was continued and so on.
>
> So my question: is there a direct support for such a scheme in Gecode 3.7?
> Or do I have to find my old branching implementation and make it ready for
> the new version? I am crossing fingers you have something ready.. :/
>
> Thanks for your help,
> Martin
>




More information about the users mailing list