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

Class IntValBranch

gecode/int.hh:5001–5029  ·  view source on GitHub ↗

* \brief Which values to select for branching first * * \ingroup TaskModelIntBranch */

Source from the content-addressed store, hash-verified

4999 * \ingroup TaskModelIntBranch
5000 */
5001 class IntValBranch : public ValBranch<IntVar> {
5002 public:
5003 /// Which value selection
5004 enum Select {
5005 SEL_MIN, ///< Select smallest value
5006 SEL_MED, ///< Select greatest value not greater than the median
5007 SEL_MAX, ///< Select largest value
5008 SEL_RND, ///< Select random value
5009 SEL_SPLIT_MIN, ///< Select values not greater than mean of smallest and largest value
5010 SEL_SPLIT_MAX, ///< Select values greater than mean of smallest and largest value
5011 SEL_RANGE_MIN, ///< Select the smallest range of the variable domain if it has several ranges, otherwise select values not greater than mean of smallest and largest value
5012 SEL_RANGE_MAX, ///< Select the largest range of the variable domain if it has several ranges, otherwise select values greater than mean of smallest and largest value
5013 SEL_VAL_COMMIT, ///< Select value according to user-defined functions
5014 SEL_VALUES_MIN, ///< Select all values starting from smallest
5015 SEL_VALUES_MAX ///< Select all values starting from largest
5016 };
5017 protected:
5018 /// Which value to select
5019 Select s;
5020 public:
5021 /// Initialize with selection strategy \a s
5022 IntValBranch(Select s = SEL_MIN);
5023 /// Initialize with random number generator \a r
5024 IntValBranch(Rnd r);
5025 /// Initialize with value function \a f and commit function \a c
5026 IntValBranch(IntBranchVal v, IntBranchCommit c);
5027 /// Return selection strategy
5028 Select select(void) const;
5029 };
5030
5031 /**
5032 * \brief Which values to select for branching first

Callers 11

INT_VAL_MINFunction · 0.85
INT_VAL_MEDFunction · 0.85
INT_VAL_MAXFunction · 0.85
INT_VAL_RNDFunction · 0.85
INT_VAL_SPLIT_MINFunction · 0.85
INT_VAL_SPLIT_MAXFunction · 0.85
INT_VAL_RANGE_MINFunction · 0.85
INT_VAL_RANGE_MAXFunction · 0.85
INT_VALFunction · 0.85
INT_VALUES_MINFunction · 0.85
INT_VALUES_MAXFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected