unary.hh
Go to the documentation of this file.
/* -*- mode: C++; c-basic-offset: 2; indent-tabs-mode: nil -*- */
/*
* Main authors:
* Christian Schulte <schulte@gecode.org>
* Guido Tack <tack@gecode.org>
*
* Copyright:
* Christian Schulte, 2009
* Guido Tack, 2010
*
* This file is part of Gecode, the generic constraint
* development environment:
* http://www.gecode.org
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
*/
#ifndef __GECODE_INT_UNARY_HH__
#define __GECODE_INT_UNARY_HH__
#include <gecode/int/task.hh>
namespace Gecode { namespace Int { namespace Unary {
class ManFixPTask {
protected:
Int::IntView _s;
int _p;
public:
ManFixPTask(void);
ManFixPTask(IntVar s, int p);
void init(IntVar s, int p);
void init(const ManFixPTask& t);
int est(void) const;
int ect(void) const;
int lst(void) const;
int lct(void) const;
int pmin(void) const;
int pmax(void) const;
IntVar st(void) const;
bool mandatory(void) const;
bool excluded(void) const;
bool optional(void) const;
bool assigned(void) const;
ModEvent est(Space& home, int n);
ModEvent ect(Space& home, int n);
ModEvent lst(Space& home, int n);
ModEvent lct(Space& home, int n);
ModEvent norun(Space& home, int e, int l);
ModEvent mandatory(Space& home);
ModEvent excluded(Space& home);
void update(Space& home, ManFixPTask& t);
void subscribe(Space& home, Propagator& p, PropCond pc);
void cancel(Space& home, Propagator& p, PropCond pc);
void reschedule(Space& home, Propagator& p, PropCond pc);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFixPTask& t);
class ManFixPSETask : public ManFixPTask {
protected:
TaskType _t;
public:
ManFixPSETask(void);
ManFixPSETask(TaskType t, IntVar s, int p);
void init(TaskType t, IntVar s, int p);
void init(const ManFixPSETask& t);
int est(void) const;
int ect(void) const;
int lst(void) const;
int lct(void) const;
int pmin(void) const;
int pmax(void) const;
ModEvent est(Space& home, int n);
ModEvent ect(Space& home, int n);
ModEvent lst(Space& home, int n);
ModEvent lct(Space& home, int n);
ModEvent norun(Space& home, int e, int l);
void update(Space& home, ManFixPSETask& t);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFixPSETask& t);
class OptFixPTask : public ManToOptTask<ManFixPTask> {
protected:
using ManToOptTask<ManFixPTask>::_m;
public:
OptFixPTask(void);
OptFixPTask(IntVar s, int p, BoolVar m);
void init(IntVar s, int p, BoolVar m);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFixPTask& t);
class OptFixPSETask : public ManToOptTask<ManFixPSETask> {
protected:
using ManToOptTask<ManFixPSETask>::_m;
public:
OptFixPSETask(void);
OptFixPSETask(TaskType t, IntVar s, int p, BoolVar m);
void init(TaskType t, IntVar s, int p, BoolVar m);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFixPSETask& t);
class ManFlexTask {
protected:
Int::IntView _s;
Int::IntView _p;
Int::IntView _e;
public:
ManFlexTask(void);
ManFlexTask(IntVar s, IntVar p, IntVar e);
void init(IntVar s, IntVar p, IntVar e);
void init(const ManFlexTask& t);
int est(void) const;
int ect(void) const;
int lst(void) const;
int lct(void) const;
int pmin(void) const;
int pmax(void) const;
IntVar st(void) const;
IntVar p(void) const;
IntVar e(void) const;
bool mandatory(void) const;
bool excluded(void) const;
bool optional(void) const;
bool assigned(void) const;
ModEvent est(Space& home, int n);
ModEvent ect(Space& home, int n);
ModEvent lst(Space& home, int n);
ModEvent lct(Space& home, int n);
ModEvent norun(Space& home, int e, int l);
ModEvent mandatory(Space& home);
ModEvent excluded(Space& home);
void update(Space& home, ManFlexTask& t);
void subscribe(Space& home, Propagator& p, PropCond pc);
void cancel(Space& home, Propagator& p, PropCond pc);
void reschedule(Space& home, Propagator& p, PropCond pc);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFlexTask& t);
class OptFlexTask : public ManToOptTask<ManFlexTask> {
protected:
using ManToOptTask<ManFlexTask>::_m;
public:
OptFlexTask(void);
OptFlexTask(IntVar s, IntVar p, IntVar e, BoolVar m);
void init(IntVar s, IntVar p, IntVar e, BoolVar m);
};
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFlexTask& t);
}}}
#include <gecode/int/unary/task.hpp>
namespace Gecode { namespace Int { namespace Unary {
typedef ManFixPTask ManFixPTaskFwd;
typedef FwdToBwd<ManFixPTaskFwd> ManFixPTaskBwd;
typedef ManFixPSETask ManFixPSETaskFwd;
typedef FwdToBwd<ManFixPSETaskFwd> ManFixPSETaskBwd;
typedef OptFixPTask OptFixPTaskFwd;
typedef FwdToBwd<OptFixPTaskFwd> OptFixPTaskBwd;
typedef OptFixPSETask OptFixPSETaskFwd;
typedef FwdToBwd<OptFixPSETaskFwd> OptFixPSETaskBwd;
typedef ManFlexTask ManFlexTaskFwd;
typedef FwdToBwd<ManFlexTaskFwd> ManFlexTaskBwd;
typedef OptFlexTask OptFlexTaskFwd;
typedef FwdToBwd<OptFlexTaskFwd> OptFlexTaskBwd;
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFixPTaskBwd& t);
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFixPSETaskBwd& t);
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFixPTaskBwd& t);
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFixPSETaskBwd& t);
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const ManFlexTaskBwd& t);
template<class Char, class Traits>
std::basic_ostream<Char,Traits>&
operator <<(std::basic_ostream<Char,Traits>& os, const OptFlexTaskBwd& t);
}}}
#include <gecode/int/unary/task-view.hpp>
namespace Gecode { namespace Int {
template<>
class TaskViewTraits<Unary::ManFixPTaskFwd> {
public:
typedef Unary::ManFixPTask Task;
};
template<>
class TaskViewTraits<Unary::ManFixPTaskBwd> {
public:
typedef Unary::ManFixPTask Task;
};
template<>
class TaskViewTraits<Unary::ManFixPSETaskFwd> {
public:
typedef Unary::ManFixPSETask Task;
};
template<>
class TaskViewTraits<Unary::ManFixPSETaskBwd> {
public:
typedef Unary::ManFixPSETask Task;
};
template<>
class TaskViewTraits<Unary::OptFixPTaskFwd> {
public:
typedef Unary::OptFixPTask Task;
};
template<>
class TaskViewTraits<Unary::OptFixPTaskBwd> {
public:
typedef Unary::OptFixPTask Task;
};
template<>
class TaskViewTraits<Unary::OptFixPSETaskFwd> {
public:
typedef Unary::OptFixPSETask Task;
};
template<>
class TaskViewTraits<Unary::OptFixPSETaskBwd> {
public:
typedef Unary::OptFixPSETask Task;
};
template<>
class TaskViewTraits<Unary::ManFlexTaskFwd> {
public:
typedef Unary::ManFlexTask Task;
};
template<>
class TaskViewTraits<Unary::ManFlexTaskBwd> {
public:
typedef Unary::ManFlexTask Task;
};
template<>
class TaskViewTraits<Unary::OptFlexTaskFwd> {
public:
typedef Unary::OptFlexTask Task;
};
template<>
class TaskViewTraits<Unary::OptFlexTaskBwd> {
public:
typedef Unary::OptFlexTask Task;
};
template<>
class TaskTraits<Unary::ManFixPTask> {
public:
typedef Unary::ManFixPTaskFwd TaskViewFwd;
typedef Unary::ManFixPTaskBwd TaskViewBwd;
};
template<>
class TaskTraits<Unary::ManFixPSETask> {
public:
typedef Unary::ManFixPSETaskFwd TaskViewFwd;
typedef Unary::ManFixPSETaskBwd TaskViewBwd;
};
template<>
class TaskTraits<Unary::OptFixPTask> {
public:
typedef Unary::OptFixPTaskFwd TaskViewFwd;
typedef Unary::OptFixPTaskBwd TaskViewBwd;
typedef Unary::ManFixPTask ManTask;
};
template<>
class TaskTraits<Unary::OptFixPSETask> {
public:
typedef Unary::OptFixPSETaskFwd TaskViewFwd;
typedef Unary::OptFixPSETaskBwd TaskViewBwd;
typedef Unary::ManFixPTask ManTask;
};
template<>
class TaskTraits<Unary::ManFlexTask> {
public:
typedef Unary::ManFlexTaskFwd TaskViewFwd;
typedef Unary::ManFlexTaskBwd TaskViewBwd;
};
template<>
class TaskTraits<Unary::OptFlexTask> {
public:
typedef Unary::OptFlexTaskFwd TaskViewFwd;
typedef Unary::OptFlexTaskBwd TaskViewBwd;
typedef Unary::ManFlexTask ManTask;
};
}}
namespace Gecode { namespace Int { namespace Unary {
class OmegaNode {
public:
int p;
int ect;
void init(const OmegaNode& l, const OmegaNode& r);
void update(const OmegaNode& l, const OmegaNode& r);
};
template<class TaskView>
class OmegaTree : public TaskTree<TaskView,OmegaNode> {
protected:
using TaskTree<TaskView,OmegaNode>::tasks;
using TaskTree<TaskView,OmegaNode>::leaf;
using TaskTree<TaskView,OmegaNode>::root;
using TaskTree<TaskView,OmegaNode>::init;
using TaskTree<TaskView,OmegaNode>::update;
public:
OmegaTree(Region& r, const TaskViewArray<TaskView>& t);
void insert(int i);
void remove(int i);
int ect(void) const;
int ect(int i) const;
};
class OmegaLambdaNode : public OmegaNode {
public:
static const int undef = -1;
int lp;
int lect;
int resEct;
int resLp;
void init(const OmegaLambdaNode& l, const OmegaLambdaNode& r);
void update(const OmegaLambdaNode& l, const OmegaLambdaNode& r);
};
template<class TaskView>
class OmegaLambdaTree : public TaskTree<TaskView,OmegaLambdaNode> {
protected:
using TaskTree<TaskView,OmegaLambdaNode>::tasks;
using TaskTree<TaskView,OmegaLambdaNode>::leaf;
using TaskTree<TaskView,OmegaLambdaNode>::root;
using TaskTree<TaskView,OmegaLambdaNode>::init;
using TaskTree<TaskView,OmegaLambdaNode>::update;
public:
OmegaLambdaTree(Region& r, const TaskViewArray<TaskView>& t,
bool inc=true);
void shift(int i);
void oinsert(int i);
void linsert(int i);
void lremove(int i);
bool lempty(void) const;
int responsible(void) const;
int ect(void) const;
int lect(void) const;
};
}}}
#include <gecode/int/unary/tree.hpp>
namespace Gecode { namespace Int { namespace Unary {
template<class ManTask>
ExecStatus overload(TaskArray<ManTask>& t);
template<class OptTask, class PL>
ExecStatus overload(Space& home, Propagator& p, TaskArray<OptTask>& t);
template<class Task>
ExecStatus timetabling(Space& home, Propagator& p, TaskArray<Task>& t);
template<class Task>
ExecStatus subsumed(Space& home, Propagator& p, TaskArray<Task>& t);
template<class ManTask>
ExecStatus detectable(Space& home, TaskArray<ManTask>& t);
template<class OptTask, class PL>
ExecStatus detectable(Space& home, Propagator& p, TaskArray<OptTask>& t);
template<class ManTask>
ExecStatus notfirstnotlast(Space& home, TaskArray<ManTask>& t);
template<class OptTask, class PL>
ExecStatus notfirstnotlast(Space& home, Propagator& p, TaskArray<OptTask>& t);
template<class Task>
ExecStatus edgefinding(Space& home, TaskArray<Task>& t);
template<class ManTask, class PL>
class ManProp : public TaskProp<ManTask,PL> {
protected:
using TaskProp<ManTask,PL>::t;
ManProp(Home home, TaskArray<ManTask>& t);
ManProp(Space& home, ManProp& p);
public:
virtual Actor* copy(Space& home);
virtual ExecStatus propagate(Space& home, const ModEventDelta& med);
static ExecStatus post(Home home, TaskArray<ManTask>& t);
};
template<class OptTask, class PL>
class OptProp : public TaskProp<OptTask,PL> {
protected:
using TaskProp<OptTask,PL>::t;
OptProp(Home home, TaskArray<OptTask>& t);
OptProp(Space& home, OptProp& p);
public:
virtual Actor* copy(Space& home);
virtual ExecStatus propagate(Space& home, const ModEventDelta& med);
static ExecStatus post(Home home, TaskArray<OptTask>& t);
};
template<class ManTask>
ExecStatus
manpost(Home home, TaskArray<ManTask>& t, IntPropLevel ipl);
template<class OptTask>
ExecStatus
optpost(Home home, TaskArray<OptTask>& t, IntPropLevel ipl);
}}}
#include <gecode/int/unary/overload.hpp>
#include <gecode/int/unary/time-tabling.hpp>
#include <gecode/int/unary/subsumption.hpp>
#include <gecode/int/unary/detectable.hpp>
#include <gecode/int/unary/not-first-not-last.hpp>
#include <gecode/int/unary/edge-finding.hpp>
#include <gecode/int/unary/man-prop.hpp>
#include <gecode/int/unary/opt-prop.hpp>
#include <gecode/int/unary/post.hpp>
#endif
// STATISTICS: int-prop
Gecode::ActorLink::Actor
friend class Actor
Definition core.hpp:590
Gecode::BoolVar
Boolean integer variables.
Definition int.hh:512
Gecode::Home
Home class for posting propagators
Definition core.hpp:856
Gecode::IntVar
Integer variables.
Definition int.hh:371
Gecode::Int::FwdToBwd
Task mapper: turns a task view into its dual.
Definition task.hh:102
Gecode::Int::IntView
Integer view for integer variables.
Definition view.hpp:129
Gecode::Int::ManToOptTask< ManFixPTask >::_m
Int::BoolView _m
Definition task.hh:46
Gecode::Int::ManToOptTask< ManFixPTask >::ManToOptTask
ManToOptTask(void)
Definition man-to-opt.hpp:38
Gecode::Int::TaskArray
Task array.
Definition task.hh:165
Gecode::Int::TaskProp< ManTask, PL >::t
TaskArray< ManTask > t
Definition task.hh:427
Gecode::Int::TaskProp< ManTask, PL >::TaskProp
TaskProp(Home home, TaskArray< ManTask > &t)
Definition prop.hpp:38
Gecode::Int::TaskTraits< Unary::ManFixPSETask >::TaskViewFwd
Unary::ManFixPSETaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:604
Gecode::Int::TaskTraits< Unary::ManFixPSETask >::TaskViewBwd
Unary::ManFixPSETaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:606
Gecode::Int::TaskTraits< Unary::ManFixPTask >::TaskViewBwd
Unary::ManFixPTaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:596
Gecode::Int::TaskTraits< Unary::ManFixPTask >::TaskViewFwd
Unary::ManFixPTaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:594
Gecode::Int::TaskTraits< Unary::ManFlexTask >::TaskViewFwd
Unary::ManFlexTaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:638
Gecode::Int::TaskTraits< Unary::ManFlexTask >::TaskViewBwd
Unary::ManFlexTaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:640
Gecode::Int::TaskTraits< Unary::OptFixPSETask >::ManTask
Unary::ManFixPTask ManTask
The corresponding mandatory task.
Definition unary.hh:630
Gecode::Int::TaskTraits< Unary::OptFixPSETask >::TaskViewFwd
Unary::OptFixPSETaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:626
Gecode::Int::TaskTraits< Unary::OptFixPSETask >::TaskViewBwd
Unary::OptFixPSETaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:628
Gecode::Int::TaskTraits< Unary::OptFixPTask >::TaskViewFwd
Unary::OptFixPTaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:614
Gecode::Int::TaskTraits< Unary::OptFixPTask >::ManTask
Unary::ManFixPTask ManTask
The corresponding mandatory task.
Definition unary.hh:618
Gecode::Int::TaskTraits< Unary::OptFixPTask >::TaskViewBwd
Unary::OptFixPTaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:616
Gecode::Int::TaskTraits< Unary::OptFlexTask >::TaskViewFwd
Unary::OptFlexTaskFwd TaskViewFwd
The forward task view type.
Definition unary.hh:648
Gecode::Int::TaskTraits< Unary::OptFlexTask >::ManTask
Unary::ManFlexTask ManTask
The corresponding mandatory task.
Definition unary.hh:652
Gecode::Int::TaskTraits< Unary::OptFlexTask >::TaskViewBwd
Unary::OptFlexTaskBwd TaskViewBwd
The backward task view type.
Definition unary.hh:650
Gecode::Int::TaskTraits
Traits class for mapping tasks to task views.
Definition task.hh:157
Gecode::Int::TaskTree< TaskView, OmegaNode >::tasks
const TaskViewArray< TaskView > & tasks
Definition task.hh:369
Gecode::Int::TaskTree< TaskView, OmegaNode >::TaskTree
TaskTree(Region &r, const TaskViewArray< TaskView > &t)
Definition tree.hpp:141
Gecode::Int::TaskTree< TaskView, OmegaNode >::init
void init(void)
Definition tree.hpp:115
Gecode::Int::TaskTree< TaskView, OmegaNode >::update
void update(int i, bool l=true)
Definition tree.hpp:129
Gecode::Int::TaskTree< TaskView, OmegaNode >::root
const OmegaNode & root(void) const
Definition tree.hpp:109
Gecode::Int::TaskTree< TaskView, OmegaNode >::leaf
OmegaNode & leaf(int i)
Definition tree.hpp:103
Gecode::Int::TaskViewArray
Task view array.
Definition task.hh:233
Gecode::Int::TaskViewTraits< Unary::ManFixPSETaskBwd >::Task
Unary::ManFixPSETask Task
The task type.
Definition unary.hh:521
Gecode::Int::TaskViewTraits< Unary::ManFixPSETaskFwd >::Task
Unary::ManFixPSETask Task
The task type.
Definition unary.hh:513
Gecode::Int::TaskViewTraits< Unary::ManFixPTaskBwd >::Task
Unary::ManFixPTask Task
The task type.
Definition unary.hh:505
Gecode::Int::TaskViewTraits< Unary::ManFixPTaskFwd >::Task
Unary::ManFixPTask Task
The task type.
Definition unary.hh:497
Gecode::Int::TaskViewTraits< Unary::ManFlexTaskBwd >::Task
Unary::ManFlexTask Task
The task type.
Definition unary.hh:569
Gecode::Int::TaskViewTraits< Unary::ManFlexTaskFwd >::Task
Unary::ManFlexTask Task
The task type.
Definition unary.hh:561
Gecode::Int::TaskViewTraits< Unary::OptFixPSETaskBwd >::Task
Unary::OptFixPSETask Task
The task type.
Definition unary.hh:553
Gecode::Int::TaskViewTraits< Unary::OptFixPSETaskFwd >::Task
Unary::OptFixPSETask Task
The task type.
Definition unary.hh:545
Gecode::Int::TaskViewTraits< Unary::OptFixPTaskBwd >::Task
Unary::OptFixPTask Task
The task type.
Definition unary.hh:537
Gecode::Int::TaskViewTraits< Unary::OptFixPTaskFwd >::Task
Unary::OptFixPTask Task
The task type.
Definition unary.hh:529
Gecode::Int::TaskViewTraits< Unary::OptFlexTaskBwd >::Task
Unary::OptFlexTask Task
The task type.
Definition unary.hh:585
Gecode::Int::TaskViewTraits< Unary::OptFlexTaskFwd >::Task
Unary::OptFlexTask Task
The task type.
Definition unary.hh:577
Gecode::Int::TaskViewTraits
Traits class for mapping task views to tasks.
Definition task.hh:148
Gecode::Int::Unary::ManFixPSETask
Unary (mandatory) task with fixed processing, start or end time
Definition unary.hh:148
Gecode::Int::Unary::ManFixPSETask::ect
int ect(void) const
Return earliest completion time.
Definition task.hpp:188
Gecode::Int::Unary::ManFixPSETask::norun
ModEvent norun(Space &home, int e, int l)
Update such that task cannot run from e to l.
Definition task.hpp:273
Gecode::Int::Unary::ManFixPSETask::pmax
int pmax(void) const
Return maximum processing time.
Definition task.hpp:222
Gecode::Int::Unary::ManFixPSETask::pmin
int pmin(void) const
Return minimum processing time.
Definition task.hpp:212
Gecode::Int::Unary::ManFixPSETask::ManFixPSETask
ManFixPSETask(void)
Default constructor.
Definition task.hpp:170
Gecode::Int::Unary::ManFixPSETask::init
void init(TaskType t, IntVar s, int p)
Initialize task.
Definition task.hpp:175
Gecode::Int::Unary::ManFixPSETask::est
int est(void) const
Return earliest start time.
Definition task.hpp:184
Gecode::Int::Unary::ManFixPSETask::_t
TaskType _t
Task type.
Definition unary.hh:151
Gecode::Int::Unary::ManFixPSETask::lct
int lct(void) const
Return latest completion time.
Definition task.hpp:202
Gecode::Int::Unary::ManFixPSETask::lst
int lst(void) const
Return latest start time.
Definition task.hpp:198
Gecode::Int::Unary::ManFixPSETask::update
void update(Space &home, ManFixPSETask &t)
Update this task to be a clone of task t.
Definition task.hpp:299
Gecode::Int::Unary::ManFixPTask
Unary (mandatory) task with fixed processing time
Definition unary.hh:54
Gecode::Int::Unary::ManFixPTask::pmax
int pmax(void) const
Return maximum processing time.
Definition task.hpp:76
Gecode::Int::Unary::ManFixPTask::optional
bool optional(void) const
Whether task can still be optional.
Definition task.hpp:93
Gecode::Int::Unary::ManFixPTask::norun
ModEvent norun(Space &home, int e, int l)
Update such that task cannot run from e to l.
Definition task.hpp:119
Gecode::Int::Unary::ManFixPTask::ManFixPTask
ManFixPTask(void)
Default constructor.
Definition task.hpp:43
Gecode::Int::Unary::ManFixPTask::est
int est(void) const
Return earliest start time.
Definition task.hpp:56
Gecode::Int::Unary::ManFixPTask::pmin
int pmin(void) const
Return minimum processing time.
Definition task.hpp:72
Gecode::Int::Unary::ManFixPTask::init
void init(IntVar s, int p)
Initialize with start time s and processing time p.
Definition task.hpp:47
Gecode::Int::Unary::ManFixPTask::ect
int ect(void) const
Return earliest completion time.
Definition task.hpp:60
Gecode::Int::Unary::ManFixPTask::_s
Int::IntView _s
Start time.
Definition unary.hh:57
Gecode::Int::Unary::ManFixPTask::_p
int _p
Processing time.
Definition unary.hh:59
Gecode::Int::Unary::ManFixPTask::assigned
bool assigned(void) const
Test whether task is assigned.
Definition task.hpp:98
Gecode::Int::Unary::ManFixPTask::reschedule
void reschedule(Space &home, Propagator &p, PropCond pc)
Schedule propagator p.
Definition task.hpp:152
Gecode::Int::Unary::ManFixPTask::lct
int lct(void) const
Return latest completion time.
Definition task.hpp:68
Gecode::Int::Unary::ManFixPTask::st
IntVar st(void) const
Return start time.
Definition task.hpp:80
Gecode::Int::Unary::ManFixPTask::cancel
void cancel(Space &home, Propagator &p, PropCond pc)
Cancel subscription of propagator p for task.
Definition task.hpp:148
Gecode::Int::Unary::ManFixPTask::lst
int lst(void) const
Return latest start time.
Definition task.hpp:64
Gecode::Int::Unary::ManFixPTask::update
void update(Space &home, ManFixPTask &t)
Update this task to be a clone of task t.
Definition task.hpp:139
Gecode::Int::Unary::ManFixPTask::mandatory
bool mandatory(void) const
Whether task is mandatory.
Definition task.hpp:85
Gecode::Int::Unary::ManFixPTask::excluded
bool excluded(void) const
Whether task is excluded.
Definition task.hpp:89
Gecode::Int::Unary::ManFixPTask::subscribe
void subscribe(Space &home, Propagator &p, PropCond pc)
Subscribe propagator p to task.
Definition task.hpp:144
Gecode::Int::Unary::ManFlexTask
Unary (mandatory) task with flexible processing time
Definition unary.hh:270
Gecode::Int::Unary::ManFlexTask::lst
int lst(void) const
Return latest start time.
Definition task.hpp:339
Gecode::Int::Unary::ManFlexTask::est
int est(void) const
Return earliest start time.
Definition task.hpp:331
Gecode::Int::Unary::ManFlexTask::p
IntVar p(void) const
Return processing time.
Definition task.hpp:359
Gecode::Int::Unary::ManFlexTask::pmin
int pmin(void) const
Return minimum processing time.
Definition task.hpp:347
Gecode::Int::Unary::ManFlexTask::_s
Int::IntView _s
Start time.
Definition unary.hh:273
Gecode::Int::Unary::ManFlexTask::st
IntVar st(void) const
Return start time.
Definition task.hpp:355
Gecode::Int::Unary::ManFlexTask::norun
ModEvent norun(Space &home, int e, int l)
Update such that task cannot run from e to l.
Definition task.hpp:402
Gecode::Int::Unary::ManFlexTask::reschedule
void reschedule(Space &home, Propagator &p, PropCond pc)
Schedule propagator p.
Definition task.hpp:444
Gecode::Int::Unary::ManFlexTask::mandatory
bool mandatory(void) const
Whether task is mandatory.
Definition task.hpp:368
Gecode::Int::Unary::ManFlexTask::subscribe
void subscribe(Space &home, Propagator &p, PropCond pc)
Subscribe propagator p to task.
Definition task.hpp:432
Gecode::Int::Unary::ManFlexTask::ect
int ect(void) const
Return earliest completion time.
Definition task.hpp:335
Gecode::Int::Unary::ManFlexTask::_e
Int::IntView _e
End time.
Definition unary.hh:277
Gecode::Int::Unary::ManFlexTask::pmax
int pmax(void) const
Return maximum processing time.
Definition task.hpp:351
Gecode::Int::Unary::ManFlexTask::e
IntVar e(void) const
Return end time.
Definition task.hpp:363
Gecode::Int::Unary::ManFlexTask::update
void update(Space &home, ManFlexTask &t)
Update this task to be a clone of task t.
Definition task.hpp:425
Gecode::Int::Unary::ManFlexTask::_p
Int::IntView _p
Processing time.
Definition unary.hh:275
Gecode::Int::Unary::ManFlexTask::excluded
bool excluded(void) const
Whether task is excluded.
Definition task.hpp:372
Gecode::Int::Unary::ManFlexTask::lct
int lct(void) const
Return latest completion time.
Definition task.hpp:343
Gecode::Int::Unary::ManFlexTask::cancel
void cancel(Space &home, Propagator &p, PropCond pc)
Cancel subscription of propagator p for task.
Definition task.hpp:438
Gecode::Int::Unary::ManFlexTask::ManFlexTask
ManFlexTask(void)
Default constructor.
Definition task.hpp:317
Gecode::Int::Unary::ManFlexTask::optional
bool optional(void) const
Whether task can still be optional.
Definition task.hpp:376
Gecode::Int::Unary::ManFlexTask::assigned
bool assigned(void) const
Test whether task is assigned.
Definition task.hpp:381
Gecode::Int::Unary::ManFlexTask::init
void init(IntVar s, IntVar p, IntVar e)
Initialize with start time s, processing time p, end time e.
Definition task.hpp:322
Gecode::Int::Unary::ManProp::post
static ExecStatus post(Home home, TaskArray< ManTask > &t)
Post propagator that schedules tasks on unary resource.
Definition man-prop.hpp:48
Gecode::Int::Unary::ManProp::propagate
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
Definition man-prop.hpp:62
Gecode::Int::Unary::ManProp::copy
virtual Actor * copy(Space &home)
Perform copying during cloning.
Definition man-prop.hpp:56
Gecode::Int::Unary::ManProp::ManProp
ManProp(Home home, TaskArray< ManTask > &t)
Constructor for creation.
Definition man-prop.hpp:38
Gecode::Int::Unary::OmegaLambdaNode
Node for an omega lambda tree.
Definition unary.hh:695
Gecode::Int::Unary::OmegaLambdaNode::update
void update(const OmegaLambdaNode &l, const OmegaLambdaNode &r)
Update node from left child l and right child r.
Definition tree.hpp:112
Gecode::Int::Unary::OmegaLambdaNode::init
void init(const OmegaLambdaNode &l, const OmegaLambdaNode &r)
Initialize node from left child l and right child r.
Definition tree.hpp:106
Gecode::Int::Unary::OmegaLambdaNode::lp
int lp
Processing times for subtree.
Definition unary.hh:700
Gecode::Int::Unary::OmegaLambdaNode::undef
static const int undef
Undefined task.
Definition unary.hh:698
Gecode::Int::Unary::OmegaLambdaNode::resEct
int resEct
Node which is responsible for lect.
Definition unary.hh:704
Gecode::Int::Unary::OmegaLambdaNode::resLp
int resLp
Node which is responsible for lp.
Definition unary.hh:706
Gecode::Int::Unary::OmegaLambdaNode::lect
int lect
Earliest completion times for subtree.
Definition unary.hh:702
Gecode::Int::Unary::OmegaLambdaTree::responsible
int responsible(void) const
Return responsible task.
Definition tree.hpp:209
Gecode::Int::Unary::OmegaLambdaTree::OmegaLambdaTree
OmegaLambdaTree(Region &r, const TaskViewArray< TaskView > &t, bool inc=true)
Initialize tree for tasks t with all tasks included, if inc is true.
Definition tree.hpp:136
Gecode::Int::Unary::OmegaLambdaTree::shift
void shift(int i)
Shift task with index i from omega to lambda.
Definition tree.hpp:163
Gecode::Int::Unary::OmegaLambdaTree::lremove
void lremove(int i)
Remove task with index i from lambda.
Definition tree.hpp:193
Gecode::Int::Unary::OmegaLambdaTree::lempty
bool lempty(void) const
Whether has responsible task.
Definition tree.hpp:203
Gecode::Int::Unary::OmegaLambdaTree::oinsert
void oinsert(int i)
Insert task with index i to omega.
Definition tree.hpp:175
Gecode::Int::Unary::OmegaLambdaTree::lect
int lect(void) const
Return earliest completion time of all tasks excluding lambda tasks.
Definition tree.hpp:221
Gecode::Int::Unary::OmegaLambdaTree::linsert
void linsert(int i)
Insert task with index i to lambda.
Definition tree.hpp:183
Gecode::Int::Unary::OmegaLambdaTree::ect
int ect(void) const
Return earliest completion time of all tasks.
Definition tree.hpp:215
Gecode::Int::Unary::OmegaNode
Node for an omega tree.
Definition unary.hh:660
Gecode::Int::Unary::OmegaNode::ect
int ect
Earliest completion time for subtree.
Definition unary.hh:665
Gecode::Int::Unary::OmegaNode::init
void init(const OmegaNode &l, const OmegaNode &r)
Initialize node from left child l and right child r.
Definition tree.hpp:43
Gecode::Int::Unary::OmegaNode::p
int p
Processing time for subtree.
Definition unary.hh:663
Gecode::Int::Unary::OmegaNode::update
void update(const OmegaNode &l, const OmegaNode &r)
Update node from left child l and right child r.
Definition tree.hpp:48
Gecode::Int::Unary::OmegaTree::insert
void insert(int i)
Insert task with index i.
Definition tree.hpp:65
Gecode::Int::Unary::OmegaTree::ect
int ect(void) const
Return earliest completion time of all tasks.
Definition tree.hpp:80
Gecode::Int::Unary::OmegaTree::remove
void remove(int i)
Remove task with index i.
Definition tree.hpp:73
Gecode::Int::Unary::OmegaTree::OmegaTree
OmegaTree(Region &r, const TaskViewArray< TaskView > &t)
Initialize tree for tasks t.
Definition tree.hpp:55
Gecode::Int::Unary::OptFixPSETask
Unary optional task with fixed processing, start or end time.
Definition unary.hh:246
Gecode::Int::Unary::OptFixPSETask::OptFixPSETask
OptFixPSETask(void)
Default constructor.
Definition task.hpp:490
Gecode::Int::Unary::OptFixPSETask::init
void init(TaskType t, IntVar s, int p, BoolVar m)
Initialize with start time s, processing time p, and mandatory flag m.
Definition task.hpp:496
Gecode::Int::Unary::OptFixPTask
Unary optional task with fixed processing time
Definition unary.hh:222
Gecode::Int::Unary::OptFixPTask::init
void init(IntVar s, int p, BoolVar m)
Initialize with start time s, processing time p, and mandatory flag m.
Definition task.hpp:471
Gecode::Int::Unary::OptFixPTask::OptFixPTask
OptFixPTask(void)
Default constructor.
Definition task.hpp:465
Gecode::Int::Unary::OptFlexTask
Unary optional task with flexible processing time
Definition unary.hh:370
Gecode::Int::Unary::OptFlexTask::OptFlexTask
OptFlexTask(void)
Default constructor.
Definition task.hpp:515
Gecode::Int::Unary::OptFlexTask::init
void init(IntVar s, IntVar p, IntVar e, BoolVar m)
Initialize with start time s, processing time p, end time e, and mandatory flag m.
Definition task.hpp:521
Gecode::Int::Unary::OptProp::propagate
virtual ExecStatus propagate(Space &home, const ModEventDelta &med)
Perform propagation.
Definition opt-prop.hpp:77
Gecode::Int::Unary::OptProp::post
static ExecStatus post(Home home, TaskArray< OptTask > &t)
Post propagator that schedules tasks on unary resource.
Definition opt-prop.hpp:50
Gecode::Int::Unary::OptProp::OptProp
OptProp(Home home, TaskArray< OptTask > &t)
Constructor for creation.
Definition opt-prop.hpp:40
Gecode::Int::Unary::OptProp::copy
virtual Actor * copy(Space &home)
Perform copying during cloning.
Definition opt-prop.hpp:71
Gecode::Propagator
Base-class for propagators.
Definition core.hpp:1064
Gecode::Propagator::Space
friend class Space
Definition core.hpp:1066
Gecode::Propagator::med
ModEventDelta med
A set of modification events (used during propagation).
Definition core.hpp:1075
Gecode::Region
Handle to region.
Definition region.hpp:55
Gecode::Space
Computation spaces.
Definition core.hpp:1742
detectable.hpp
Gecode::ModEventDelta
int ModEventDelta
Modification event deltas.
Definition core.hpp:89
Gecode::TaskType
TaskType
Type of task for scheduling constraints.
Definition int.hh:1004
Gecode::IntPropLevel
IntPropLevel
Propagation levels for integer propagators.
Definition int.hh:974
post.hpp
Gecode::Int::Unary
Int for unary resources
Gecode::Int::Unary::optpost
ExecStatus optpost(Home home, TaskArray< OptTask > &t, IntPropLevel ipl)
Post optional task propagator according to propagation level.
Definition post.hpp:53
Gecode::Int::Unary::OptFixPSETaskBwd
FwdToBwd< OptFixPSETaskFwd > OptFixPSETaskBwd
Backward (dual) optional fixed task view.
Definition unary.hh:421
Gecode::Int::Unary::ManFlexTaskBwd
FwdToBwd< ManFlexTaskFwd > ManFlexTaskBwd
Backward (dual) mandatory flexible task view.
Definition unary.hh:427
Gecode::Int::Unary::OptFlexTaskBwd
FwdToBwd< OptFlexTaskFwd > OptFlexTaskBwd
Backward (dual) optional flexible task view.
Definition unary.hh:433
Gecode::Int::Unary::OptFlexTaskFwd
OptFlexTask OptFlexTaskFwd
Forward optional flexible task view.
Definition unary.hh:430
Gecode::Int::Unary::OptFixPTaskFwd
OptFixPTask OptFixPTaskFwd
Forward optional fixed task view.
Definition unary.hh:412
Gecode::Int::Unary::manpost
ExecStatus manpost(Home home, TaskArray< ManTask > &t, IntPropLevel ipl)
Post mandatory task propagator according to propagation level.
Definition post.hpp:38
Gecode::Int::Unary::ManFixPSETaskBwd
FwdToBwd< ManFixPSETaskFwd > ManFixPSETaskBwd
Backward (dual) mandatory fixed task view.
Definition unary.hh:409
Gecode::Int::Unary::OptFixPTaskBwd
FwdToBwd< OptFixPTaskFwd > OptFixPTaskBwd
Backward (dual) optional fixed task view.
Definition unary.hh:415
Gecode::Int::Unary::timetabling
ExecStatus timetabling(Space &home, Propagator &p, TaskArray< Task > &t)
Perform time-tabling propagation.
Definition time-tabling.hpp:40
Gecode::Int::Unary::OptFixPSETaskFwd
OptFixPSETask OptFixPSETaskFwd
Forward optional fixed task view.
Definition unary.hh:418
Gecode::Int::Unary::overload
ExecStatus overload(TaskArray< ManTask > &t)
Check mandatory tasks t for overload.
Definition overload.hpp:39
Gecode::Int::Unary::subsumed
ExecStatus subsumed(Space &home, Propagator &p, TaskArray< Task > &t)
Check tasks t for subsumption.
Definition subsumption.hpp:38
Gecode::Int::Unary::ManFixPTaskFwd
ManFixPTask ManFixPTaskFwd
Forward mandatory fixed task view.
Definition unary.hh:400
Gecode::Int::Unary::ManFixPSETaskFwd
ManFixPSETask ManFixPSETaskFwd
Forward mandatory fixed task view.
Definition unary.hh:406
Gecode::Int::Unary::ManFlexTaskFwd
ManFlexTask ManFlexTaskFwd
Forward mandatory flexible task view.
Definition unary.hh:424
Gecode::Int::Unary::detectable
ExecStatus detectable(Space &home, TaskArray< ManTask > &t)
Propagate detectable precedences.
Definition detectable.hpp:62
Gecode::Int::Unary::ManFixPTaskBwd
FwdToBwd< ManFixPTaskFwd > ManFixPTaskBwd
Backward (dual) mandatory fixed task view.
Definition unary.hh:403
Gecode::Int::Unary::notfirstnotlast
ExecStatus notfirstnotlast(Space &home, TaskArray< ManTask > &t)
Propagate not-first and not-last.
Definition not-first-not-last.hpp:72
Gecode::Int::Unary::edgefinding
ExecStatus edgefinding(Space &home, TaskArray< Task > &t)
Propagate by edge-finding.
Definition edge-finding.hpp:65
Gecode::Int::Unary::operator<<
std::basic_ostream< Char, Traits > & operator<<(std::basic_ostream< Char, Traits > &os, const ManFixPTaskBwd &t)
Definition task-view.hpp:40
Gecode::Int
Finite domain integers.
Gecode
Gecode toplevel namespace
Gecode::ExecStatus
ExecStatus
Definition core.hpp:472
Gecode::PropCond
int PropCond
Type for propagation conditions.
Definition core.hpp:72
Gecode::ModEvent
int ModEvent
Type for modification events.
Definition core.hpp:62
not-first-not-last.hpp
task.hh
edge-finding.hpp
man-prop.hpp
opt-prop.hpp
overload.hpp
subsumption.hpp
task-view.hpp
task.hpp
time-tabling.hpp
tree.hpp