38#ifndef __GECODE_FLOAT_HH__
39#define __GECODE_FLOAT_HH__
54#if !defined(GECODE_STATIC_LIBS) && \
55 (defined(__CYGWIN__) || defined(__MINGW32__) || defined(_MSC_VER))
57#ifdef GECODE_BUILD_FLOAT
58#define GECODE_FLOAT_EXPORT __declspec( dllexport )
60#define GECODE_FLOAT_EXPORT __declspec( dllimport )
65#ifdef GECODE_GCC_HAS_CLASS_VISIBILITY
66#define GECODE_FLOAT_EXPORT __attribute__ ((visibility("default")))
68#define GECODE_FLOAT_EXPORT
74#ifndef GECODE_BUILD_FLOAT
75#define GECODE_LIBRARY_NAME "Float"
80#include <boost/numeric/interval.hpp>
128namespace Gecode {
namespace Float {
131#if defined(_MSC_VER) && (defined(_M_X64) || (defined(_M_IX86_FP) && (_M_IX86_FP > 0)))
138 typedef boost::numeric::interval_lib::save_state< boost::numeric::interval_lib::rounded_arith_std<FloatNum> >
144 typedef boost::numeric::interval_lib::rounded_arith_opp<FloatNum>
198#ifdef GECODE_HAS_MPFR
281namespace Gecode {
namespace Float {
287 bool subset(
const FloatVal&
x,
const FloatVal&
y);
297 bool overlap(
const FloatVal&
x,
const FloatVal&
y);
303 FloatVal
intersect(
const FloatVal&
x,
const FloatVal&
y);
308 FloatVal
hull(
const FloatVal&
x,
const FloatVal&
y);
369 template<
class Char,
class Traits>
370 friend std::basic_ostream<Char,Traits>&
386#ifdef GECODE_HAS_MPFR
416 typedef boost::numeric::interval_lib::save_state<Float::Rounding>
R;
418 typedef boost::numeric::interval_lib::checking_strict<FloatNum>
P;
420 typedef boost::numeric::interval
422 boost::numeric::interval_lib::policies<R, P> >
464 bool tight(
void)
const;
677 template<
class Char,
class Traits>
678 std::basic_ostream<Char,Traits>&
738#ifdef GECODE_HAS_MPFR
835namespace Gecode {
namespace Float {
942 template<
class Char,
class Traits>
943 std::basic_ostream<Char,Traits>&
968 template<
class InputIterator>
999 template<
class InputIterator>
1092 dom(Home home, FloatVar
x, FloatVal n);
1095 dom(Home home,
const FloatVarArgs&
x, FloatVal n);
1104 dom(Home home, FloatVar
x, FloatVal n, Reify
r);
1110 dom(Home home, FloatVar
x, FloatVar d);
1113 dom(Home home,
const FloatVarArgs&
x,
const FloatVarArgs& d);
1158 ite(Home home, BoolVar b, FloatVar
x, FloatVar
y, FloatVar
z);
1224#ifdef GECODE_HAS_MPFR
1447 typedef std::function<bool(
const Space& home,
FloatVar x,
int i)>
1460 typedef std::function<double(
const Space& home,
FloatVar x,
int i)>
1500 typedef std::function<void(
Space& home,
unsigned int a,
1659 typedef std::function<void(
const Space &home,
const Brancher& b,
1661 FloatVar
x,
int i,
const FloatNumBranch& n,
1934 branch(Home home,
const FloatVarArgs&
x,
1935 FloatVarBranch vars, FloatValBranch vals,
1944 branch(Home home,
const FloatVarArgs&
x,
1945 TieBreak<FloatVarBranch> vars, FloatValBranch vals,
1954 branch(Home home, FloatVar
x, FloatValBranch vals,
1963 assign(Home home,
const FloatVarArgs&
x,
1964 FloatVarBranch vars, FloatAssign vals,
1973 assign(Home home,
const FloatVarArgs&
x,
1974 TieBreak<FloatVarBranch> vars, FloatAssign vals,
1983 assign(Home home, FloatVar
x, FloatAssign vals,
AFC(void)
Construct as not yet intialized.
Action(void)
Construct as not yet intialized.
Boolean integer variables.
CHB(void)
Construct as not yet intialized.
Generic domain change information to be supplied to advisors.
Recording AFC information for float variables.
void init(Home home, const FloatVarArgs &x, double d=1.0, bool share=true)
Initialize for float variables x with decay factor d.
FloatAFC(void)
Construct as not yet initialized.
FloatAFC & operator=(const FloatAFC &a)
Assignment operator.
Recording actions for float variables.
FloatAction & operator=(const FloatAction &a)
Assignment operator.
void init(Home home, const FloatVarArgs &x, double d=1.0, FloatBranchMerit bm=nullptr)
Initialize for float variables x with decay factor d.
FloatAction(void)
Construct as not yet initialized.
Which values to select for assignment.
Select
Which value selection.
@ SEL_MAX
Select median value of the upper part.
@ SEL_VAL_COMMIT
Select value according to user-defined functions.
@ SEL_RND
Select median value of a randomly chosen part.
@ SEL_MIN
Select median value of the lower part.
Select s
Which value to select.
FloatAssign(Select s=SEL_MIN)
Initialize with selection strategy s.
Select select(void) const
Return selection strategy.
Recording CHB for float variables.
FloatCHB & operator=(const FloatCHB &chb)
Assignment operator.
void init(Home home, const FloatVarArgs &x, FloatBranchMerit bm=nullptr)
Initialize for float variables x.
FloatCHB(void)
Construct as not yet initialized.
Value description class for branching.
bool l
Whether to try the lower or upper half first.
FloatNum n
The middle value for branching.
Trace delta information for float variables.
FloatTraceDelta(Float::FloatTraceView o, Float::FloatView n, const Delta &d)
Initialize with old trace view o, new view n, and delta d.
const Delta & d
Delta information.
FloatNum min(void) const
Return minimum.
Float::FloatView n
New view.
FloatNum max(void) const
Return maximum.
FloatValArgs(std::initializer_list< FloatVal > x)
Allocate array and copy elements from x.
static FloatValArgs create(int n, FloatVal start, int inc=1)
Allocate array with n elements such that for all .
FloatValArgs(void)
Allocate empty array.
Which values to select for branching first.
Select select(void) const
Return selection strategy.
Select
Which value selection.
@ SEL_SPLIT_RND
Select values randomly which are not greater or not smaller than mean of largest and smallest value.
@ SEL_SPLIT_MIN
Select values not greater than mean of smallest and largest value.
@ SEL_VAL_COMMIT
Select value according to user-defined functions.
@ SEL_SPLIT_MAX
Select values greater than mean of smallest and largest value.
Select s
Which value to select.
FloatValBranch(Select s=SEL_SPLIT_MIN)
Initialize with selection strategy s.
friend std::basic_ostream< Char, Traits > & operator<<(std::basic_ostream< Char, Traits > &os, const FloatVal &x)
friend FloatVal cos(const FloatVal &x)
bool singleton(void) const
Test whether float is a singleton.
friend FloatVal exp(const FloatVal &x)
friend FloatVal Float::hull(const FloatVal &x, const FloatVal &y)
friend FloatVal acos(const FloatVal &x)
FloatVal & operator/=(const FloatNum &n)
Divide by n.
friend bool operator==(const FloatVal &x, const FloatVal &y)
boost::numeric::interval_lib::checking_strict< FloatNum > P
Used checking policy.
friend FloatVal atanh(const FloatVal &x)
static FloatVal pi(void)
Return lower bound of .
friend bool operator<(const FloatVal &x, const FloatVal &y)
friend bool operator<=(const FloatVal &x, const FloatVal &y)
friend FloatVal cosh(const FloatVal &x)
friend FloatVal operator-(const FloatVal &x)
boost::numeric::interval< FloatNum, boost::numeric::interval_lib::policies< R, P > > FloatValImpType
Implementation type for float value.
static FloatVal pi_twice(void)
Return .
friend FloatVal operator*(const FloatVal &x, const FloatVal &y)
friend FloatVal acosh(const FloatVal &x)
FloatValImpType x
Implementation of float value.
bool zero_in(void) const
Test whether zero is included.
friend FloatVal sqrt(const FloatVal &x)
FloatVal & operator-=(const FloatNum &n)
Subtract by n.
bool in(FloatNum n) const
Test whether n is included.
friend FloatVal pow(const FloatVal &x, int n)
friend FloatVal abs(const FloatVal &x)
friend FloatVal operator/(const FloatVal &x, const FloatVal &y)
friend FloatVal tanh(const FloatVal &x)
FloatVal & operator*=(const FloatNum &n)
Multiply by n.
FloatNum max(void) const
Return upper bound.
void assign(FloatNum const &l, FloatNum const &u)
Assign lower bound l and upper bound u.
friend FloatVal log(const FloatVal &x)
friend FloatVal sin(const FloatVal &x)
friend FloatVal sqr(const FloatVal &x)
friend FloatVal sinh(const FloatVal &x)
friend bool operator>=(const FloatVal &x, const FloatVal &y)
friend FloatVal asin(const FloatVal &x)
FloatVal & operator+=(const FloatNum &n)
Increment by n.
friend bool operator!=(const FloatVal &x, const FloatVal &y)
FloatNum med(void) const
Return median of float value.
FloatVal & operator=(const FloatNum &n)
Assignment operator.
friend bool operator>(const FloatVal &x, const FloatVal &y)
boost::numeric::interval_lib::save_state< Float::Rounding > R
Used rounding policies.
friend FloatVal atan(const FloatVal &x)
friend FloatVal asinh(const FloatVal &x)
bool tight(void) const
Test whether float is tight.
friend FloatVal nroot(const FloatVal &x, int n)
FloatNum size(void) const
Return size of float value (distance between maximum and minimum)
friend FloatVal operator+(const FloatVal &x)
friend FloatVal fmod(const FloatVal &x, const FloatVal &y)
static FloatVal pi_half(void)
Return .
FloatVal(const FloatValImpType &i)
Initialize from implementation i.
friend FloatVal tan(const FloatVal &x)
FloatVal(void)
Default constructor.
FloatNum min(void) const
Return lower bound.
FloatVarArgs(void)
Allocate empty array.
FloatVarArray & operator=(const FloatVarArray &)=default
Assignment operator.
FloatVarArray(void)
Default constructor (array of size 0)
Which variable to select for branching.
Select select(void) const
Return selection strategy.
FloatVarBranch(void)
Initialize with strategy SEL_NONE.
void expand(Home home, const FloatVarArgs &x)
Expand AFC, action, and CHB.
Select
Which variable selection.
@ SEL_ACTION_SIZE_MIN
With smallest action divided by domain size.
@ SEL_ACTION_SIZE_MAX
With largest action divided by domain size.
@ SEL_MIN_MIN
With smallest min.
@ SEL_AFC_SIZE_MIN
With smallest accumulated failure count divided by domain size.
@ SEL_MAX_MAX
With largest max.
@ SEL_AFC_SIZE_MAX
With largest accumulated failure count divided by domain size.
@ SEL_CHB_MAX
With highest CHB Q-score.
@ SEL_DEGREE_SIZE_MIN
With smallest degree divided by domain size.
@ SEL_MIN_MAX
With largest min.
@ SEL_CHB_SIZE_MIN
With smallest CHB Q-score divided by domain size.
@ SEL_NONE
First unassigned.
@ SEL_MERIT_MIN
With least merit.
@ SEL_ACTION_MAX
With highest action.
@ SEL_CHB_MIN
With lowest CHB Q-score.
@ SEL_DEGREE_MAX
With largest degree.
@ SEL_DEGREE_SIZE_MAX
With largest degree divided by domain size.
@ SEL_DEGREE_MIN
With smallest degree.
@ SEL_MERIT_MAX
With highest merit.
@ SEL_MAX_MIN
With smallest max.
@ SEL_CHB_SIZE_MAX
With largest CHB Q-score divided by domain size.
@ SEL_RND
Random (uniform, for tie breaking)
@ SEL_AFC_MAX
With largest accumulated failure count.
@ SEL_SIZE_MAX
With largest domain size.
@ SEL_AFC_MIN
With smallest accumulated failure count.
@ SEL_ACTION_MIN
With lowest action.
@ SEL_SIZE_MIN
With smallest domain size.
Select s
Which variable to select.
friend class FloatVarArgs
bool in(const FloatVal &n) const
Test whether n is contained in domain.
FloatVal domain(void) const
Return domain.
FloatNum med(void) const
Return median of domain.
FloatVar & operator=(const FloatVar &)=default
Assignment operator.
FloatNum size(void) const
Return size of domain (distance between maximum and minimum)
FloatNum min(void) const
Return minimum of domain.
FloatVar(void)
Default constructor.
FloatVal val(void) const
Return assigned value.
FloatNum max(void) const
Return maximum of domain.
friend class FloatVarArray
Float variable implementation.
Float view for float variables.
FloatNum sin_down(FloatNum x)
Return lower bound of sine of x (domain: )
FloatNum tanh_up(FloatNum x)
Return upper bound of hyperbolic tangent of x (domain: )
FloatNum acosh_up(FloatNum x)
Return upper bound of hyperbolic arccosine of x (domain: )
~Rounding(void)
Destructor (restores previous rounding mode)
FloatNum tanh_down(FloatNum x)
Return lower bound of hyperbolic tangent of x (domain: )
FloatNum sinh_up(FloatNum x)
Return upper bound of hyperbolic sine of x (domain: )
FloatNum int_up(FloatNum x)
Return next upward-rounded integer of x (domain: )
FloatNum sqrt_up(FloatNum x)
Return upper bound of square root of x (domain: )
FloatNum atanh_down(FloatNum x)
Return lower bound of hyperbolic arctangent of x (domain: )
FloatNum cos_up(FloatNum x)
Return upper bound of cosine of x (domain: )
FloatNum sub_up(FloatNum x, FloatNum y)
Return upper bound of x minus y (domain: )
FloatNum int_down(FloatNum x)
Return next downward-rounded integer of x (domain: )
FloatNum median(FloatNum x, FloatNum y)
Return median of x and y (domain: )
FloatNum add_up(FloatNum x, FloatNum y)
Return upper bound of x plus y (domain: )
Rounding(void)
Default constructor (configures full rounding mode)
FloatNum sinh_down(FloatNum x)
Return lower bound of hyperbolic sine of x (domain: )
FloatNum tan_down(FloatNum x)
Return lower bound of tangent of x (domain: )
FloatNum sqrt_down(FloatNum x)
Return lower bound of square root of x (domain: )
FloatNum sub_down(FloatNum x, FloatNum y)
Return lower bound of x minus y (domain: )
FloatNum asin_down(FloatNum x)
Return lower bound of arcsine of x (domain: )
FloatNum mul_up(FloatNum x, FloatNum y)
Return upper bound of x times y (domain: )
FloatNum div_up(FloatNum x, FloatNum y)
Return upper bound of x divided y (domain: )
FloatNum exp_down(FloatNum x)
Return lower bound of exponential of x (domain: )
FloatNum div_down(FloatNum x, FloatNum y)
Return lower bound of x divided by y (domain: )
FloatNum mul_down(FloatNum x, FloatNum y)
Return lower bound of x times y (domain: )
FloatNum asin_up(FloatNum x)
Return upper bound of arcsine of x (domain: )
FloatNum acosh_down(FloatNum x)
Return lower bound of hyperbolic arccosine of x (domain: )
FloatNum atan_down(FloatNum x)
Return lower bound of arctangent of x (domain: )
FloatNum cosh_down(FloatNum x)
Return lower bound of hyperbolic cosine of x (domain: )
FloatNum log_up(FloatNum x)
Return upper bound of logarithm of x (domain: )
FloatNum asinh_down(FloatNum x)
Return lower bound of hyperbolic arcsine of x (domain: )
FloatNum sin_up(FloatNum x)
Return upper bound of sine of x (domain: )
FloatNum acos_up(FloatNum x)
Return upper bound of arccossine of x (domain: )
FloatNum cosh_up(FloatNum x)
Return upper bound of hyperbolic cosine of x (domain: )
FloatNum exp_up(FloatNum x)
Return upper bound of exponential of x (domain: )
FloatNum tan_up(FloatNum x)
Return upper bound of tangent of x (domain: )
FloatNum acos_down(FloatNum x)
Return lower bound of arccosine of x (domain: )
FloatNum atanh_up(FloatNum x)
Return upper bound of hyperbolic arctangent of x (domain: )
FloatNum log_down(FloatNum x)
Return lower bound of logarithm of x (domain: )
FloatNum atan_up(FloatNum x)
Return upper bound of arctangent of x (domain: )
FloatNum cos_down(FloatNum x)
Return lower bound of cosine of x (domain: )
FloatNum asinh_up(FloatNum x)
Return upper bound of hyperbolic arcsine of x (domain: )
FloatNum add_down(FloatNum x, FloatNum y)
Return lower bound of x plus y (domain: )
Home class for posting propagators
Reification specification.
Shared array with arbitrary number of elements.
static StdFloatTracer def
Default tracer (printing to std::cerr)
StdFloatTracer(std::ostream &os0=std::cerr)
Initialize with output stream os0.
virtual void fail(const Space &home, const FloatTraceRecorder &t)
Print failure information.
virtual void fix(const Space &home, const FloatTraceRecorder &t)
Print fixpoint information.
std::ostream & os
Output stream to use.
virtual void done(const Space &home, const FloatTraceRecorder &t)
Print that trace recorder is done.
virtual void prune(const Space &home, const FloatTraceRecorder &t, const ViewTraceInfo &vti, int i, FloatTraceDelta &d)
Print prune information.
virtual void init(const Space &home, const FloatTraceRecorder &t)
Print init information.
Propagator for recording view trace information.
Tracer that process view trace information.
#define GECODE_FLOAT_EXPORT
ViewTracer< Float::FloatView > FloatTracer
Tracer for float variables.
ViewTraceRecorder< Float::FloatView > FloatTraceRecorder
Trace recorder for float variables.
GECODE_FLOAT_EXPORT void trace(Home home, const FloatVarArgs &x, TraceFilter tf, int te=(TE_INIT|TE_PRUNE|TE_FIX|TE_FAIL|TE_DONE), FloatTracer &t=StdFloatTracer::def)
Create a tracer for float variables.
std::function< double(const Space &home, double w, double b)> BranchTbl
Tie-break limit function.
std::function< FloatNumBranch(const Space &home, FloatVar x, int i)> FloatBranchVal
Branch value function type for float variables.
std::function< double(const Space &home, FloatVar x, int i)> FloatBranchMerit
Branch merit function type for float variables.
std::function< bool(const Space &home, FloatVar x, int i)> FloatBranchFilter
Branch filter function type for float variables.
void assign(Home home, const FloatVarArgs &x, FloatVarBranch vars, FloatAssign vals, FloatBranchFilter bf=nullptr, FloatVarValPrint vvp=nullptr)
Assign all x with variable selection vars and value selection vals.
std::function< void(Space &home, unsigned int a, FloatVar x, int i, FloatNumBranch nl)> FloatBranchCommit
Branch commit function type for float variables.
void branch(Home home, const FloatVarArgs &x, FloatVarBranch vars, FloatValBranch vals, FloatBranchFilter bf=nullptr, FloatVarValPrint vvp=nullptr)
Branch over x with variable selection vars and value selection vals.
void linear(Home home, const FloatVarArgs &x, FloatRelType frt, FloatVal c)
Post propagator for .
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVar x1)
Post propagator for .
void ite(Home home, BoolVar b, FloatVar x, FloatVar y, FloatVar z)
Post propagator for if-then-else constraint.
double FloatNum
Floating point number base type.
FloatRelType
Relation types for floats.
@ FRT_LQ
Less or equal ( )
@ FRT_GQ
Greater or equal ( )
@ TE_INIT
Trace init events.
@ TE_PRUNE
Trace prune events.
@ TE_FIX
Trace fixpoint events.
@ TE_FAIL
Trace fail events.
@ TE_DONE
Trace done events.
Numerical limits for floating point variables.
const FloatNum max
Largest allowed float value.
bool valid(const FloatVal &n)
Return whether float n is a valid number.
const FloatNum min
Smallest allowed float value.
void check(const FloatVal &n, const char *l)
Check whether float n is a valid number, otherwise throw out of limits exception with information l.
bool subset(const FloatVal &x, const FloatVal &y)
bool proper_subset(const FloatVal &x, const FloatVal &y)
FloatVal hull(const FloatVal &x, const FloatVal &y)
bool overlap(const FloatVal &x, const FloatVal &y)
FloatVal intersect(const FloatVal &x, const FloatVal &y)
boost::numeric::interval_lib::rounded_arith_opp< FloatNum > RoundingBase
Rounding Base class (optimized version)
Gecode toplevel namespace
FloatVarBranch FLOAT_VAR_DEGREE_SIZE_MAX(BranchTbl tbl=nullptr)
Select variable with largest degree divided by domain size.
FloatVarBranch FLOAT_VAR_DEGREE_SIZE_MIN(BranchTbl tbl=nullptr)
Select variable with smallest degree divided by domain size.
FloatVarBranch FLOAT_VAR_RND(Rnd r)
Select random variable (uniform distribution, for tie breaking)
FloatValBranch FLOAT_VAL_SPLIT_MAX(void)
Select values greater than mean of smallest and largest value.
FloatVal operator/(const FloatVal &x, const FloatVal &y)
std::function< void(const Space &home, const Brancher &b, unsigned int a, FloatVar x, int i, const FloatNumBranch &n, std::ostream &o)> FloatVarValPrint
Function type for explaining branching alternatives for float variables.
FloatVal operator-(const FloatVal &x)
FloatVal asinh(const FloatVal &x)
bool operator<=(const FloatVal &x, const FloatVal &y)
FloatVarBranch FLOAT_VAR_AFC_MIN(double d=1.0, BranchTbl tbl=nullptr)
Select variable with smallest accumulated failure count with decay factor d.
void sin(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatNum pi_upper(void)
Return upper bound of .
FloatVal operator+(const FloatVal &x)
Post propagator for SetVar SetOpType SetVar SetRelType r
FloatVarBranch FLOAT_VAR_SIZE_MAX(BranchTbl tbl=nullptr)
Select variable with largest domain size.
FloatNum pi_lower(void)
Return lower bound of .
FloatNum pi_half_lower(void)
Return lower bound of .
void channel(Home home, FloatVar x0, IntVar x1)
Post propagator for channeling a float and an integer variable .
FloatVarBranch FLOAT_VAR_MAX_MAX(BranchTbl tbl=nullptr)
Select variable with largest max.
void sqr(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatValBranch FLOAT_VAL_SPLIT_RND(Rnd r)
Select values randomly which are not greater or not smaller than mean of largest and smallest value.
FloatVarBranch FLOAT_VAR_AFC_SIZE_MIN(double d=1.0, BranchTbl tbl=nullptr)
Select variable with smalllest accumulated failure count divided by domain size with decay factor d.
FloatVarBranch FLOAT_VAR_CHB_SIZE_MAX(BranchTbl tbl=nullptr)
Select variable with largest CHB Q-score divided by domain size.
Archive & operator<<(Archive &e, FloatNumBranch nl)
FloatNum pi_twice_lower(void)
Return lower bound of .
void cos(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
void min(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
FloatNum pi_half_upper(void)
Return upper bound of .
void dom(Home home, FloatVar x, FloatVal n)
Propagates .
void abs(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
void div(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
bool operator<(const FloatVal &x, const FloatVal &y)
Post propagator for SetVar SetOpType SetVar SetRelType SetVar z
void mult(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
FloatVarBranch FLOAT_VAR_CHB_MIN(BranchTbl tbl=nullptr)
Select variable with lowest CHB Q-score.
void sqrt(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatVarBranch FLOAT_VAR_CHB_SIZE_MIN(BranchTbl tbl=nullptr)
Select variable with smallest CHB Q-score divided by domain size.
FloatNum pi_twice_upper(void)
Return upper bound of .
FloatVarBranch FLOAT_VAR_ACTION_MAX(double d=1.0, BranchTbl tbl=nullptr)
Select variable with highest action with decay factor d.
void acos(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
Post propagator for SetVar SetOpType SetVar y
FloatVarBranch FLOAT_VAR_CHB_MAX(BranchTbl tbl=nullptr)
Select variable with highest CHB Q-score.
FloatAssign FLOAT_ASSIGN_MAX(void)
Select median value of the upper part.
bool operator>(const FloatVal &x, const FloatVal &y)
FloatVarBranch FLOAT_VAR_MIN_MIN(BranchTbl tbl=nullptr)
Select variable with smallest min.
FloatValBranch FLOAT_VAL(FloatBranchVal v, FloatBranchCommit c=nullptr)
void log(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatVarBranch FLOAT_VAR_MAX_MIN(BranchTbl tbl=nullptr)
Select variable with smallest max.
FloatVarBranch FLOAT_VAR_ACTION_MIN(double d=1.0, BranchTbl tbl=nullptr)
Select variable with lowest action with decay factor d.
bool operator>=(const FloatVal &x, const FloatVal &y)
GECODE_FLOAT_EXPORT void relax(Home home, const FloatVarArgs &x, const FloatVarArgs &sx, Rnd r, double p)
void exp(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
void atan(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatVarBranch FLOAT_VAR_NONE(void)
Select first unassigned variable.
void wait(Home home, FloatVar x, std::function< void(Space &home)> c)
Execute c when x becomes assigned.
void max(Home home, FloatVar x0, FloatVar x1, FloatVar x2)
Post propagator for .
FloatVarBranch FLOAT_VAR_DEGREE_MAX(BranchTbl tbl=nullptr)
Select variable with largest degree.
FloatVal fmod(const FloatVal &x, const FloatVal &y)
FloatVal sinh(const FloatVal &x)
FloatVal acosh(const FloatVal &x)
FloatVarBranch FLOAT_VAR_ACTION_SIZE_MAX(double d=1.0, BranchTbl tbl=nullptr)
Select variable with largest action divided by domain size with decay factor d.
FloatVal tanh(const FloatVal &x)
FloatVarBranch FLOAT_VAR_MIN_MAX(BranchTbl tbl=nullptr)
Select variable with largest min.
void asin(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatAssign FLOAT_ASSIGN_RND(Rnd r)
Select median value of a randomly chosen part.
void pow(Home home, FloatVar x0, int n, FloatVar x1)
Post propagator for for $n\geq 0$.
FloatVal atanh(const FloatVal &x)
FloatVal operator*(const FloatVal &x, const FloatVal &y)
FloatVarBranch FLOAT_VAR_AFC_SIZE_MAX(double d=1.0, BranchTbl tbl=nullptr)
Select variable with largest accumulated failure count divided by domain size with decay factor d.
FloatVarBranch FLOAT_VAR_MERIT_MIN(FloatBranchMerit bm, BranchTbl tbl=nullptr)
Select variable with least merit according to branch merit function bm.
Post propagator for SetVar x
FloatVal cosh(const FloatVal &x)
FloatVarBranch FLOAT_VAR_DEGREE_MIN(BranchTbl tbl=nullptr)
Select variable with smallest degree.
void nroot(Home home, FloatVar x0, int n, FloatVar x1)
Post propagator for for $n\geq 0$.
bool operator==(const FloatVal &x, const FloatVal &y)
FloatValBranch FLOAT_VAL_SPLIT_MIN(void)
Select values not greater than mean of smallest and largest value.
bool operator!=(const FloatVal &x, const FloatVal &y)
FloatVarBranch FLOAT_VAR_SIZE_MIN(BranchTbl tbl=nullptr)
Select variable with smallest domain size.
FloatVarBranch FLOAT_VAR_AFC_MAX(double d=1.0, BranchTbl tbl=nullptr)
Select variable with largest accumulated failure count with decay factor d.
FloatAssign FLOAT_ASSIGN_MIN(void)
Select median value of the lower part.
FloatAssign FLOAT_ASSIGN(FloatBranchVal v, FloatBranchCommit c=nullptr)
FloatVarBranch FLOAT_VAR_ACTION_SIZE_MIN(double d=1.0, BranchTbl tbl=nullptr)
Select variable with smallest action divided by domain size with decay factor d.
void tan(Home home, FloatVar x0, FloatVar x1)
Post propagator for .
FloatVarBranch FLOAT_VAR_MERIT_MAX(FloatBranchMerit bm, BranchTbl tbl=nullptr)
Select variable with highest merit according to branch merit function bm.