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

Method post

test/float/mm-lin.cpp:112–121  ·  view source on GitHub ↗

Post constraint on \a x

Source from the content-addressed store, hash-verified

110 }
111 /// Post constraint on \a x
112 virtual void post(Gecode::Space& home, Gecode::IntVarArray& x) {
113 using namespace Gecode;
114 FloatVarArray y(home,4,dom.min(),dom.max());
115 channel(home, x[0], y[0]);
116 channel(home, x[1], y[1]);
117 channel(home, x[2], y[2]);
118 channel(home, x[3], y[3]);
119 LinFloatExpr reg[3] = {y[0],y[1],y[2]};
120 rel(home, y[3], FRT_EQ, expr(home, eval(lis,reg)));
121 }
122 };
123
124 /// %Test linear relations over float variables

Callers

nothing calls this directly

Calls 6

evalFunction · 0.70
channelFunction · 0.50
relFunction · 0.50
exprFunction · 0.50
minMethod · 0.45
maxMethod · 0.45

Tested by

no test coverage detected