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

Method solution

test/float/trigonometric.cpp:260–264  ·  view source on GitHub ↗

%Test whether \a x is solution

Source from the content-addressed store, hash-verified

258 : Test("Trigonometric::ASin::XY::Sol::"+s,2,d,st,EXTEND_ASSIGNMENT,false) {}
259 /// %Test whether \a x is solution
260 virtual MaybeType solution(const Assignment& x) const {
261 if ((x[0].min() > 1.0) || (x[0].max() < -1.0))
262 return MT_FALSE;
263 return eq(asin(x[0]), x[1]);
264 }
265 /// Extend assignment \a x
266 virtual bool extendAssignment(Assignment& x) const {
267 if ((x[0].min() > 1.0) || (x[0].max() < -1.0))

Callers

nothing calls this directly

Calls 3

asinFunction · 0.50
minMethod · 0.45
maxMethod · 0.45

Tested by

no test coverage detected