 1 
Tutorial
Supplement: IP Modeling Tricks
Note: If you introduce any decision variables (integer/continuous), please define
them properly; do not leave up to the reader to interpret the correct definition of
decision variables.
There can be multiple ways of modeling a restriction/logic in IP. But there exists only
one truth table that corresponds to a particular restriction/logic condition. Words
such as “must”, “can”, “could”, “should” etc. defines the logical conditions, so be
careful in interpreting them.
Logical Conditions and ZeroOne Variable:
In Boolean algebra:
“v” means “or” (this is inclusive, i.e. A or B or both)
“.”means “and”
“~”means “not”
±
means “implies” (if ….
. then)
²
means “if and only if”
Let X
1
= 1 if statement 1 is true; 0 otherwise.
Let X
2
= 1 if statement 2 is true; 0 otherwise.
Logic
Equivalent to
Comments
1
X
A
v X
B
X
A
+X
B
≥
1
X
A
 X
B
10
01
11
2
X
A
.X
B
X
A
=1 and X
B
=1
X
A
 X
B
11
3
~X
A
X
A
=0 or 1X
A
=1
X
A
=0
4
X
A
±
X
B
X
B
≥
X
A
or X
B
 X
A
≥
0
X
A
 X
B
11
00 or 1
5
X
A
±
~X
B
X
B
≤
1X
A
X
A
 X
B
10
00 or 1
6
X
A
²
X
B
X
A
– X
B
= 0
X
A
 X
B
11
00
7
Either X
A
or X
B
(but
not both) is true.
(They are mutually
exclusive)
X
A
+ X
B
= 1
X
A
 X
B
10
01
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document 2 
Q.No. 1:
Formulate the following restriction to fit an IP model: “
If
product A is
produced, and B is produced,
then
product C must be produced” (or “
If
statement A
is true, and statement B is true,
then
statement C must be true.”
This is the end of the preview.
Sign up
to
access the rest of the document.
 Spring '08
 OBEIDI
 Logic, Mathematical logic, xa, binary decision variables

Click to edit the document details