MCPcopy Create free account
hub / github.com/Gecode/gecode / extendAssignment

Method extendAssignment

test/float/arithmetic.cpp:125–133  ·  view source on GitHub ↗

Extend assignment \a x

Source from the content-addressed store, hash-verified

123 }
124 /// Extend assignment \a x
125 virtual bool extendAssignment(Assignment& x) const {
126 Gecode::FloatVal d = x[0]*x[0];
127 if (Gecode::Float::subset(d, dom)) {
128 x.set(1, d);
129 return true;
130 } else {
131 return false;
132 }
133 }
134 /// Post constraint on \a x
135 virtual void post(Gecode::Space& home, Gecode::FloatVarArray& x) {
136 Gecode::mult(home, x[0], x[0], x[1]);

Callers

nothing calls this directly

Calls 2

subsetFunction · 0.50
setMethod · 0.45

Tested by

no test coverage detected