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

Method post

test/int/arithmetic.cpp:929–935  ·  view source on GitHub ↗

Post constraint on \a x

Source from the content-addressed store, hash-verified

927 }
928 /// Post constraint on \a x
929 virtual void post(Gecode::Space& home, Gecode::IntVarArray& x) {
930 int n=x.size()-1;
931 Gecode::BoolVarArgs m(n);
932 for (int i=0; i<n; i++)
933 m[i]=channel(home,x[i]);
934 Gecode::argmax(home, m, offset, x[n], tiebreak);
935 }
936 };
937
938 /// %Test for argument maximum constraint with shared variables

Callers

nothing calls this directly

Calls 3

argmaxFunction · 0.85
channelFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected