Go to the documentation of this file.
39 #ifdef GECODE_HAS_MPFR
44 namespace Test {
namespace Float {
47 namespace Trigonometric {
240 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
261 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
267 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
291 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
309 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
330 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
336 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
360 if ((
x[0].
min() > 1.0) || (
x[0].
max() < -1.0))
SinXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
ACosXY acos_xy_c("C", c, step)
SinXY sin_xy_a("A", a, step)
SinXX sin_xx_c("C", c, step)
ACosXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
Gecode::FloatVal dom
Domain of variables.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ATanXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
CosXX cos_xx_c("C", c, step)
TanXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
ACosXX acos_xx_a("A", a, step)
TanXYSol tan_xy_sol_b("B", b, step)
ASinXX asin_xx_a("A", a, step)
ASinXY asin_xy_a("A", a, step)
static MaybeType eq(Gecode::FloatVal x, Gecode::FloatVal y)
Whether x and y are equal.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
ATanXYSol atan_xy_sol_a("A", a, step)
ACosXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ATanXYSol atan_xy_sol_b("B", b, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
ACosXX acos_xx_c("C", c, step)
ACosXY acos_xy_a("A", a, step)
Test for atangent constraint
TanXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
Test for cosinus constraint with shared variables
CosXX cos_xx_a("A", a, step)
Test for cosinus constraint where solution is ensured
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
ASinXYSol asin_xy_sol_a("A", a, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
ASinXYSol asin_xy_sol_b("B", b, step)
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
Gecode::FloatVal c(-8, 8)
ACosXYSol acos_xy_sol_a("A", a, step)
const FloatNum min
Smallest allowed float value.
void sin(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
Test for asinus constraint with shared variables
Test for acosinus constraint with shared variables
Test for tangent constraint where solution is ensured
ACosXYSol acos_xy_sol_c("C", c, step)
ASinXY asin_xy_b("B", b, step)
CosXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
void acos(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
CosXY cos_xy_b("B", b, step)
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ATanXX atan_xx_b("B", b, step)
SinXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
ASinXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
Test for atangent constraint where solution is ensured
ASinXX asin_xx_b("B", b, step)
SinXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
ASinXY asin_xy_c("C", c, step)
ATanXY atan_xy_b("B", b, step)
Test for cosinus constraint
CosXY cos_xy_a("A", a, step)
ACosXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
SinXYSol sin_xy_sol_a("A", a, step)
Node * x
Pointer to corresponding Boolean expression node.
ATanXX atan_xx_c("C", c, step)
SinXYSol sin_xy_sol_c("C", c, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
Test for acosinus constraint where solution is ensured
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
Test for sinus constraint with shared variables
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ATanXY atan_xy_a("A", a, step)
TanXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
SinXY sin_xy_c("C", c, step)
Test for tangent constraint with shared variables
bool flip(void)
Flip a coin and return true or false randomly.
TanXX tan_xx_a("A", a, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
TanXY tan_xy_c("C", c, step)
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
CosXYSol cos_xy_sol_b("B", b, step)
double FloatNum
Floating point number base type.
CosXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
Test for sinus constraint where solution is ensured
void tan(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ATanXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
Test for asinus constraint where solution is ensured
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
CosXY(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
bool subset(const FloatVal &x, const FloatVal &y)
ACosXY acos_xy_b("B", b, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
Test for asinus constraint
Test for acosinus constraint
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
TanXY tan_xy_a("A", a, step)
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
Test for sinus constraint
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
Test for tangent constraint
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ASinXYSol asin_xy_sol_c("C", c, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVal n)
Propagates .
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
ASinXYSol(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
TanXX tan_xx_b("B", b, step)
const Gecode::FloatNum step
ASinXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
CosXYSol cos_xy_sol_c("C", c, step)
Gecode::FloatVal b(9, 12)
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
MaybeType
Type for comparisons and solutions.
CosXX cos_xx_b("B", b, step)
void asin(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
TanXYSol tan_xy_sol_a("A", a, step)
Test for atangent constraint with shared variables
Base class for assignments
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
TanXYSol tan_xy_sol_c("C", c, step)
ATanXY atan_xy_c("C", c, step)
CosXY cos_xy_c("C", c, step)
SinXY sin_xy_b("B", b, step)
TanXY tan_xy_b("B", b, step)
const Gecode::FloatNum step2
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
void atan(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution
SinXX sin_xx_b("B", b, step)
ATanXYSol atan_xy_sol_c("C", c, step)
ACosXYSol acos_xy_sol_b("B", b, step)
virtual bool extendAssignement(Assignment &x) const
Extend assignment x.
Gecode::FloatVal a(-8, 5)
virtual void post(Gecode::Space &home, Gecode::FloatVarArray &x)
Post constraint on x.
TanXX tan_xx_c("C", c, step)
ASinXX asin_xx_c("C", c, step)
SinXX sin_xx_a("A", a, step)
void cos(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
ATanXX atan_xx_a("A", a, step)
SinXYSol sin_xy_sol_b("B", b, step)
const FloatNum max
Largest allowed float value.
ACosXX acos_xx_b("B", b, step)
ATanXX(const std::string &s, const Gecode::FloatVal &d, Gecode::FloatNum st)
Create and register test.
CosXYSol cos_xy_sol_a("A", a, step)
virtual MaybeType solution(const Assignment &x) const
Test whether x is solution