[gecode-users] Variable updates and copies

Javier Andrés Mena Zapata javimena at gmail.com
Sun Jul 22 02:27:57 CEST 2007


Hi,

I wonder which is the objective of the update and copy methods. My question
arise, because the intermediate variables doesn't need to be update.

E.g.

class Solver : public Space {
  IntVarArray x;
 public:
  Solver() {
    IntVarArray xx(this,10,0,100);

    for (int i=0; i < 10; i++)
       post(this, xx[i] == x[i] * x[i])  // some weird relationship between
x and xx
    linear(this,xx, IRT_EQ, 10);

    branch(this,x,.....)
  }
};


In this case, there is no code for updating xx in the copy constructor, why?
what happen if I don't update x in the copy constructor?

Thanks,

-- 
Javier Andrés Mena Zapata
University of  Valle
Cali - Colombia
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.ps.uni-sb.de/pipermail/users/attachments/20070721/0bb80df7/attachment.htm>


More information about the gecode-users mailing list