Generated on Sat Apr 10 2021 00:00:00 for Gecode by doxygen 1.9.1
cumulative.cpp File Reference
#include <gecode/int/cumulative.hh>
#include <algorithm>

Go to the source code of this file.

Namespaces

 Gecode::Int
 Finite domain integers.
 
 Gecode::Int::Cumulative
 Scheduling for cumulative resources
 

Functions

template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const TaskTypeArgs &t, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, IntPropLevel ipl)
 
template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const TaskTypeArgs &t, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl)
 
template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, IntPropLevel ipl)
 
template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl)
 
template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, IntPropLevel ipl)
 
template<class Cap >
void Gecode::Int::Cumulative::cumulative (Home home, Cap c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl)
 
void Gecode::cumulative (Home home, int c, const TaskTypeArgs &t, const IntVarArgs &flex, const IntArgs &fix, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const TaskTypeArgs &t, const IntVarArgs &flex, const IntArgs &fix, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, int c, const TaskTypeArgs &t, const IntVarArgs &flex, const IntArgs &fix, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const TaskTypeArgs &t, const IntVarArgs &flex, const IntArgs &fix, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, int c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, int c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const IntVarArgs &s, const IntArgs &p, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, int c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, int c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 
void Gecode::cumulative (Home home, IntVar c, const IntVarArgs &s, const IntVarArgs &p, const IntVarArgs &e, const IntArgs &u, const BoolVarArgs &m, IntPropLevel ipl=IPL_DEF)
 Post propagators for scheduling optional tasks on cumulative resources. More...
 

Function Documentation

◆ cumulative() [1/12]

void Gecode::cumulative ( Home  home,
int  c,
const TaskTypeArgs t,
const IntVarArgs flex,
const IntArgs fix,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Schedule tasks with flexible times flex, fixed times fix, and use capacity u on a cumulative resource with capacity c. For each task, it depends on t how the flexible and fix times are interpreted:

  • If t[i] is TT_FIXP, then flex[i] is the start time and fix[i] is the processing time.
  • If t[i] is TT_FIXS, then flex[i] is the end time and fix[i] is the start time.
  • If t[i] is TT_FIXE, then flex[i] is the start time and fix[i] is the end time.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if t, s p, or u are of different size.
  • Throws an exception of type Int::OutOfLimits, if p, u, or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 354 of file cumulative.cpp.

◆ cumulative() [2/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const TaskTypeArgs t,
const IntVarArgs flex,
const IntArgs fix,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Definition at line 362 of file cumulative.cpp.

◆ cumulative() [3/12]

void Gecode::cumulative ( Home  home,
int  c,
const TaskTypeArgs t,
const IntVarArgs flex,
const IntArgs fix,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Schedule tasks with flexible times flex, fixed times fix, use capacity u, and whether a task is mandatory m (a task is mandatory if the Boolean variable is 1) on a cumulative resource with capacity c. For each task, it depends on t how the flexible and fix times are interpreted:

  • If t[i] is TT_FIXP, then flex[i] is the start time and fix[i] is the processing time.
  • If t[i] is TT_FIXS, then flex[i] is the end time and fix[i] is the start time.
  • If t[i] is TT_FIXE, then flex[i] is the start time and fix[i] is the end time.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if t, s p, or u are of different size.
  • Throws an exception of type Int::OutOfLimits, if p, u, or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 373 of file cumulative.cpp.

◆ cumulative() [4/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const TaskTypeArgs t,
const IntVarArgs flex,
const IntArgs fix,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Definition at line 381 of file cumulative.cpp.

◆ cumulative() [5/12]

void Gecode::cumulative ( Home  home,
int  c,
const IntVarArgs s,
const IntArgs p,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Schedule tasks with start times s, processing times p, and use capacity u on a cumulative resource with capacity c.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if s p, or u are of different size.
  • Throws an exception of type Int::OutOfLimits, if p, u, or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 392 of file cumulative.cpp.

◆ cumulative() [6/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const IntVarArgs s,
const IntArgs p,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Definition at line 399 of file cumulative.cpp.

◆ cumulative() [7/12]

void Gecode::cumulative ( Home  home,
int  c,
const IntVarArgs s,
const IntArgs p,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Schedule optional tasks with start times s, processing times p, used capacity u, and whether a task is mandatory m (a task is mandatory if the Boolean variable is 1) on a cumulative resource with capacity c.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if s, p, u, or m are of different size.
  • Throws an exception of type Int::OutOfLimits, if p, u, or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 409 of file cumulative.cpp.

◆ cumulative() [8/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const IntVarArgs s,
const IntArgs p,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Definition at line 416 of file cumulative.cpp.

◆ cumulative() [9/12]

void Gecode::cumulative ( Home  home,
int  c,
const IntVarArgs s,
const IntVarArgs p,
const IntVarArgs e,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Schedule tasks with start times s, processing times p, end times e, and use capacity u on a cumulative resource with capacity c.

The propagator does not enforce $s_i+p_i=e_i$, this constraint has to be posted in addition to ensure consistency of the task bounds.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if s p, or u are of different size.
  • Throws an exception of type Int::OutOfLimits, if u or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 426 of file cumulative.cpp.

◆ cumulative() [10/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const IntVarArgs s,
const IntVarArgs p,
const IntVarArgs e,
const IntArgs u,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling tasks on cumulative resources.

Definition at line 434 of file cumulative.cpp.

◆ cumulative() [11/12]

void Gecode::cumulative ( Home  home,
int  c,
const IntVarArgs s,
const IntVarArgs p,
const IntVarArgs e,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Schedule optional tasks with start times s, processing times p, end times e, used capacity u, and whether a task is mandatory m (a task is mandatory if the Boolean variable is 1) on a cumulative resource with capacity c.

The propagator does not enforce $s_i+p_i=e_i$, this constraint has to be posted in addition to ensure consistency of the task bounds.

The propagator performs propagation that depends on the integer propagation level ipl as follows:

  • If IPL_BASIC is set, the propagator performs overload checking and time-tabling propagation.
  • If IPL_ADVANCED is set, the propagator performs overload checking and edge finding.
  • If both flags are combined, all the above listed propagation is performed.

The propagator uses algorithms taken from:

Petr Vilím, Max Energy Filtering Algorithm for Discrete Cumulative Resources, in W. J. van Hoeve and J. N. Hooker, editors, CPAIOR, volume 5547 of LNCS, pages 294-308. Springer, 2009.

and

Petr Vilím, Edge finding filtering algorithm for discrete cumulative resources in O(kn log n). In I. P. Gent, editor, CP, volume 5732 of LNCS, pages 802-816. Springer, 2009.

  • Throws an exception of type Int::ArgumentSizeMismatch, if s, p, u, or m are of different size.
  • Throws an exception of type Int::OutOfLimits, if u or c contain an integer that is not nonnegative, or that could generate an overflow.

Definition at line 445 of file cumulative.cpp.

◆ cumulative() [12/12]

void Gecode::cumulative ( Home  home,
IntVar  c,
const IntVarArgs s,
const IntVarArgs p,
const IntVarArgs e,
const IntArgs u,
const BoolVarArgs m,
IntPropLevel  ipl = IPL_DEF 
)

Post propagators for scheduling optional tasks on cumulative resources.

Definition at line 453 of file cumulative.cpp.