main page
modules
namespaces
classes
files
Gecode home
Generated on Mon Feb 8 2021 00:00:00 for Gecode by
doxygen
1.8.20
gecode
minimodel
ipl.hpp
Go to the documentation of this file.
1
/* -*- mode: C++; c-basic-offset: 2; indent-tabs-mode: nil -*- */
2
/*
3
* Main author:
4
* Christian Schulte <schulte@gecode.org>
5
*
6
* Copyright:
7
* Christian Schulte, 2018
8
*
9
* This file is part of Gecode, the generic constraint
10
* development environment:
11
* http://www.gecode.org
12
*
13
* Permission is hereby granted, free of charge, to any person obtaining
14
* a copy of this software and associated documentation files (the
15
* "Software"), to deal in the Software without restriction, including
16
* without limitation the rights to use, copy, modify, merge, publish,
17
* distribute, sublicense, and/or sell copies of the Software, and to
18
* permit persons to whom the Software is furnished to do so, subject to
19
* the following conditions:
20
*
21
* The above copyright notice and this permission notice shall be
22
* included in all copies or substantial portions of the Software.
23
*
24
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
28
* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
29
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
30
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
31
*
32
*/
33
34
namespace
Gecode
{
35
36
inline
37
IntPropLevels::IntPropLevels
(
IntPropLevel
ipl)
38
: _linear2(ipl), _linear(ipl),
39
_abs(ipl),
40
_max2(ipl),
_max
(ipl), _min2(ipl),
_min
(ipl),
41
_mult(ipl), _div(ipl), _mod(ipl),
42
_sqr(ipl), _sqrt(ipl), _pow(ipl), _nroot(ipl),
43
_element(ipl),
44
_ite
(ipl) {}
45
46
inline
IntPropLevel
47
IntPropLevels::linear2
(
void
)
const
{
48
return
_linear2
;
49
}
50
inline
IntPropLevels
&
51
IntPropLevels::linear2
(
IntPropLevel
ipl) {
52
_linear2
=ipl;
return
*
this
;
53
}
54
inline
IntPropLevel
55
IntPropLevels::linear
(
void
)
const
{
56
return
_linear
;
57
}
58
inline
IntPropLevels
&
59
IntPropLevels::linear
(
IntPropLevel
ipl) {
60
_linear
=ipl;
return
*
this
;
61
}
62
63
inline
IntPropLevel
64
IntPropLevels::abs
(
void
)
const
{
65
return
_abs
;
66
}
67
inline
IntPropLevels
&
68
IntPropLevels::abs
(
IntPropLevel
ipl) {
69
_abs
=ipl;
return
*
this
;
70
}
71
72
inline
IntPropLevel
73
IntPropLevels::max2
(
void
)
const
{
74
return
_max2
;
75
}
76
inline
IntPropLevels
&
77
IntPropLevels::max2
(
IntPropLevel
ipl) {
78
_max2
=ipl;
return
*
this
;
79
}
80
inline
IntPropLevel
81
IntPropLevels::max
(
void
)
const
{
82
return
_max
;
83
}
84
inline
IntPropLevels
&
85
IntPropLevels::max
(
IntPropLevel
ipl) {
86
_max
=ipl;
return
*
this
;
87
}
88
inline
IntPropLevel
89
IntPropLevels::min2
(
void
)
const
{
90
return
_min2
;
91
}
92
inline
IntPropLevels
&
93
IntPropLevels::min2
(
IntPropLevel
ipl) {
94
_min2
=ipl;
return
*
this
;
95
}
96
inline
IntPropLevel
97
IntPropLevels::min
(
void
)
const
{
98
return
_min
;
99
}
100
inline
IntPropLevels
&
101
IntPropLevels::min
(
IntPropLevel
ipl) {
102
_min
=ipl;
return
*
this
;
103
}
104
105
inline
IntPropLevel
106
IntPropLevels::mult
(
void
)
const
{
107
return
_mult
;
108
}
109
inline
IntPropLevels
&
110
IntPropLevels::mult
(
IntPropLevel
ipl) {
111
_mult
=ipl;
return
*
this
;
112
}
113
inline
IntPropLevel
114
IntPropLevels::div
(
void
)
const
{
115
return
_div
;
116
}
117
inline
IntPropLevels
&
118
IntPropLevels::div
(
IntPropLevel
ipl) {
119
_div
=ipl;
return
*
this
;
120
}
121
inline
IntPropLevel
122
IntPropLevels::mod
(
void
)
const
{
123
return
_mod
;
124
}
125
inline
IntPropLevels
&
126
IntPropLevels::mod
(
IntPropLevel
ipl) {
127
_mod
=ipl;
return
*
this
;
128
}
129
130
inline
IntPropLevel
131
IntPropLevels::sqr
(
void
)
const
{
132
return
_sqr
;
133
}
134
inline
IntPropLevels
&
135
IntPropLevels::sqr
(
IntPropLevel
ipl) {
136
_sqr
=ipl;
return
*
this
;
137
}
138
inline
IntPropLevel
139
IntPropLevels::sqrt
(
void
)
const
{
140
return
_sqrt
;
141
}
142
inline
IntPropLevels
&
143
IntPropLevels::sqrt
(
IntPropLevel
ipl) {
144
_sqrt
=ipl;
return
*
this
;
145
}
146
inline
IntPropLevel
147
IntPropLevels::pow
(
void
)
const
{
148
return
_pow
;
149
}
150
inline
IntPropLevels
&
151
IntPropLevels::pow
(
IntPropLevel
ipl) {
152
_pow
=ipl;
return
*
this
;
153
}
154
inline
IntPropLevel
155
IntPropLevels::nroot
(
void
)
const
{
156
return
_nroot
;
157
}
158
inline
IntPropLevels
&
159
IntPropLevels::nroot
(
IntPropLevel
ipl) {
160
_nroot
=ipl;
return
*
this
;
161
}
162
163
inline
IntPropLevel
164
IntPropLevels::element
(
void
)
const
{
165
return
_element
;
166
}
167
inline
IntPropLevels
&
168
IntPropLevels::element
(
IntPropLevel
ipl) {
169
_element
=ipl;
return
*
this
;
170
}
171
172
inline
IntPropLevel
173
IntPropLevels::ite
(
void
)
const
{
174
return
_ite
;
175
}
176
inline
IntPropLevels
&
177
IntPropLevels::ite
(
IntPropLevel
ipl) {
178
_ite
=ipl;
return
*
this
;
179
}
180
181
}
182
183
// STATISTICS: minimodel-any
184
Gecode::IntPropLevels::nroot
IntPropLevel nroot(void) const
Return integer propagation level for root constraints.
Definition:
ipl.hpp:155
Gecode::IntPropLevels::IntPropLevels
IntPropLevels(IntPropLevel ipl=IPL_DEF)
Initialize with default propagation level.
Definition:
ipl.hpp:37
Gecode::IntPropLevels::_min
IntPropLevel _min
For minimum.
Definition:
minimodel.hh:109
Gecode::IntPropLevels::_linear
IntPropLevel _linear
For n-ary linear.
Definition:
minimodel.hh:104
Gecode::IntPropLevels::_sqr
IntPropLevel _sqr
For square.
Definition:
minimodel.hh:113
Gecode::IntPropLevels::pow
IntPropLevel pow(void) const
Return integer propagation level for power constraints.
Definition:
ipl.hpp:147
Gecode::IntPropLevels::_element
IntPropLevel _element
For element.
Definition:
minimodel.hh:117
Gecode::IntPropLevels::_max2
IntPropLevel _max2
For binary maximum.
Definition:
minimodel.hh:106
Gecode::IntPropLevels::_pow
IntPropLevel _pow
For power.
Definition:
minimodel.hh:115
Gecode::IntPropLevels::mod
IntPropLevel mod(void) const
Return integer propagation level for modulo constraints.
Definition:
ipl.hpp:122
Gecode::IntPropLevel
IntPropLevel
Propagation levels for integer propagators.
Definition:
int.hh:974
Gecode::IntPropLevels::_min2
IntPropLevel _min2
For binary minimum.
Definition:
minimodel.hh:108
Gecode::IntPropLevels::_sqrt
IntPropLevel _sqrt
For square root.
Definition:
minimodel.hh:114
Test::Set::Rel::_ite
ITE _ite
Definition:
rel.cpp:179
Gecode::IntPropLevels::_abs
IntPropLevel _abs
For absolute value.
Definition:
minimodel.hh:105
Gecode::IntPropLevels
Class for specifying integer propagation levels used by minimodel.
Definition:
minimodel.hh:101
Gecode::IntPropLevels::_ite
IntPropLevel _ite
For if-then-else.
Definition:
minimodel.hh:118
Gecode
Gecode toplevel namespace
Gecode::IntPropLevels::abs
IntPropLevel abs(void) const
Return integer propagation level for absolute value constraints.
Definition:
ipl.hpp:64
Gecode::IntPropLevels::sqrt
IntPropLevel sqrt(void) const
Return integer propagation level for square root constraints.
Definition:
ipl.hpp:139
Gecode::IntPropLevels::max2
IntPropLevel max2(void) const
Return integer propagation level for binary maximum constraints.
Definition:
ipl.hpp:73
Gecode::IntPropLevels::_div
IntPropLevel _div
For division.
Definition:
minimodel.hh:111
Gecode::IntPropLevels::_max
IntPropLevel _max
For n-ary maximum.
Definition:
minimodel.hh:107
Gecode::IntPropLevels::mult
IntPropLevel mult(void) const
Return integer propagation level for multiplication constraints.
Definition:
ipl.hpp:106
Gecode::IntPropLevels::_mult
IntPropLevel _mult
For multiplication.
Definition:
minimodel.hh:110
Gecode::IntPropLevels::max
IntPropLevel max(void) const
Return integer propagation level for non-binary maximum constraints.
Definition:
ipl.hpp:81
Gecode::IntPropLevels::div
IntPropLevel div(void) const
Return integer propagation level for division constraints.
Definition:
ipl.hpp:114
Gecode::IntPropLevels::ite
IntPropLevel ite(void) const
Return integer propagation level for if-then-else constraints.
Definition:
ipl.hpp:173
Gecode::IntPropLevels::min
IntPropLevel min(void) const
Return integer propagation level for non-binary minimum constraints.
Definition:
ipl.hpp:97
Gecode::IntPropLevels::_nroot
IntPropLevel _nroot
For root.
Definition:
minimodel.hh:116
Gecode::IntPropLevels::min2
IntPropLevel min2(void) const
Return integer propagation level for binary minimum constraints.
Definition:
ipl.hpp:89
Gecode::IntPropLevels::linear2
IntPropLevel linear2(void) const
Return integer propagation level for binary linear constraints.
Definition:
ipl.hpp:47
Gecode::IntPropLevels::_linear2
IntPropLevel _linear2
For binary linear.
Definition:
minimodel.hh:103
Test::Set::Int::_min
Min _min("Int::Min")
Gecode::IntPropLevels::sqr
IntPropLevel sqr(void) const
Return integer propagation level for square constraints.
Definition:
ipl.hpp:131
Gecode::IntPropLevels::element
IntPropLevel element(void) const
Return integer propagation level for element constraints.
Definition:
ipl.hpp:164
Test::Set::Int::_max
Max _max("Int::Max")
Gecode::IntPropLevels::linear
IntPropLevel linear(void) const
Return integer propagation level for non-binary linear constraints.
Definition:
ipl.hpp:55
Gecode::IntPropLevels::_mod
IntPropLevel _mod
For modulo.
Definition:
minimodel.hh:112