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

Class SetValBranch

gecode/set.hh:1460–1486  ·  view source on GitHub ↗

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

Source from the content-addressed store, hash-verified

1458 * \ingroup TaskModelSetBranch
1459 */
1460 class SetValBranch : public ValBranch<SetVar> {
1461 public:
1462 /// Which value selection
1463 enum Select {
1464 SEL_MIN_INC, ///< Include smallest element
1465 SEL_MIN_EXC, ///< Exclude smallest element
1466 SEL_MED_INC, ///< Include median element (rounding downwards)
1467 SEL_MED_EXC, ///< Exclude median element (rounding downwards)
1468 SEL_MAX_INC, ///< Include largest element
1469 SEL_MAX_EXC, ///< Exclude largest element
1470 SEL_RND_INC, ///< Include random element
1471 SEL_RND_EXC, ///< Exclude random element
1472 SEL_VAL_COMMIT ///< Select value according to user-defined functions
1473 };
1474 protected:
1475 /// Which value to select
1476 Select s;
1477 public:
1478 /// Initialize with selection strategy \a s
1479 SetValBranch(Select s = SEL_MIN_INC);
1480 /// Initialize with random number generator \a r
1481 SetValBranch(Select s, Rnd r);
1482 /// Initialize with value function \a f and commit function \a c
1483 SetValBranch(SetBranchVal v, SetBranchCommit c);
1484 /// Return selection strategy
1485 Select select(void) const;
1486 };
1487
1488 /**
1489 * \defgroup TaskModelSetBranchVal Value selection for set variables

Callers 9

SET_VAL_MIN_INCFunction · 0.85
SET_VAL_MIN_EXCFunction · 0.85
SET_VAL_MED_INCFunction · 0.85
SET_VAL_MED_EXCFunction · 0.85
SET_VAL_MAX_INCFunction · 0.85
SET_VAL_MAX_EXCFunction · 0.85
SET_VAL_RND_INCFunction · 0.85
SET_VAL_RND_EXCFunction · 0.85
SET_VALFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected