SlideShare a Scribd company logo
Operations Research(Math3151)
Lecture 1
Integer programming
Teklebirhan A.
Aksum University
January 13, 2025
Teklebirhan A. Aksum University Chapter 1 Integer programming 1 / 124
Outlines
1 Integer programming
2 Deterministic dynamic programming
3 Inventory models
4 Forecasting
5 Decision theory
6 Queuing systems
7 Simulation modeling
Teklebirhan A. Aksum University Chapter 1 Integer programming 2 / 124
Motivation
resources in an organization
Management is the attainment of organizational goals in an
effective and efficient manner through planning, organizing,
leading, and controlling organizational resources.
What are resources in an organization?
Setting an objective requires strategic thinking, experiences,
vision, etc.
"Resource allocation" uses Operations Research (OR).
Names of similar subjects/ideas:
Management science.
Decision science.
Optimization method/algorithm.
Mathematical programming.
Teklebirhan A. Aksum University Chapter 1 Integer programming 3 / 124
Example: job allocation
Two people are going to hold
an event, and they need to
complete some tasks.
One task must be assigned to
exactly one person; one
person can work on one task
at a time.
How to assign the tasks so
that they can complete all
tasks the fastest?
What are the resources? What
is the objective?
ID Task Processing Time (min)
1 Boiling boba 20
2 Brewing milk tea 30
3 Baking cookies 60
4 Designing poster 15
5 Renting handcart 25
Teklebirhan A. Aksum University Chapter 1 Integer programming 4 / 124
Example: Project Management
n workers are going to
complete m jobs in a project.
Some jobs must be
processed with precedence
rules.
Some jobs cannot be done
by certain workers.
Some jobs can be split and
allocated to several
workers.
Some jobs require different
processing time if allocated
to different workers.
How many days does it take to
complete this project?
Teklebirhan A. Aksum University Chapter 1 Integer programming 5 / 124
What is Operations Research?
Operations Research (OR) is:
the methodology to allocate the available resources to the various
activities in a way that is most effective for the organization as a
whole.
It is applied to problems that concern how to conduct and
coordinate the operations (i.e., activities) within an organization.
It aims to support decision making.
Typical tools: intuitions, business senses, and experiences.
By doing OR studies, we generate some suggestions to decision
makers.
Teklebirhan A. Aksum University Chapter 1 Integer programming 6 / 124
The process of conducting an OR study
Teklebirhan A. Aksum University Chapter 1 Integer programming 7 / 124
Example: Knapsack Problem
You are preparing for hiking.
There are some useful items,
but your backpack (knapsack)
can only carry 5 kilograms.
An item cannot be split: Each
item should be either chosen
or discarded.
Which items should you bring
to maximize the total value?
ID Item Weight Value
1 Compass 0.5 6
2 Hatchet 1.5 5
3 Matches 0.4 4
4 Tarpaulin 1.0 4
5 Telescope 1.1 3
6 Cylinder 1.6 4
7 Rilakkuma 0.8 1
Teklebirhan A. Aksum University Chapter 1 Integer programming 8 / 124
Example: Knapsack Problem
A Mathematical Programming Model
Decision variables: What may we determine?
xi =







1 if item i is chosen;
0 otherwise.
Objective function: What do we want?
max6x1 + 5x2 + 4x3 + 4x4 + 3x5 + 4x6 + x7
Constraints: What are the limitations?
0.5x1 + 1.5x2 + 0.4x3 + x4 + 1.1x5 + 1.6x6 + 0.8x7 ≤ 5
and
xi ∈ {0,1},∀i = 1,...,7
Complete Formulation (Model)
max 6x1 + 5x2 + 4x3 + 4x4 + 3x5 + 4x6 + x7
s.t. 0.5x1 + 1.5x2 + 0.4x3 + x4 + 1.1x5 + 1.6x6 + 0.8x7 ≤ 5
xi ∈ {0,1}, ∀i = 1,...,7
Teklebirhan A. Aksum University Chapter 1 Integer programming 10 / 124
A Compact Formulation (Advanced)
Let wi and vi be the weight and value of item i.
Let n be the number of items and B be the maximum allowable
weight.
A compact (and more abstract) formulation is:
max
n
¼
i=1
vi xi
subject to
n
¼
i=1
wi xi ≤ B
xi ∈ {0,1} ∀i = 1,...,n.
Teklebirhan A. Aksum University Chapter 1 Integer programming 11 / 124
Application: Order Selection
Let wi and vi be the processing time and gross profit of order i.
Let n be the number of orders and B be the factory capacity (the
maximum total processing time that a factory has).
The formulation is (still)
max
n
¼
i=1
vi xi
s.t.
n
¼
i=1
wi xi ≤ B
xi ∈ {0,1} ∀i = 1,...,n
Teklebirhan A. Aksum University Chapter 1 Integer programming 12 / 124
Application: Portfolio Optimization
Let wi and vi be the maximum possible investment amount and
expected return of stock i.
Let n be the number of assets and B be the total budget.
The formulation is
max
n
¼
i=1
vi xi
s.t.
n
¼
i=1
wi xi ≤ B
0 ≤ xi ≤ 1 ∀i = 1,...,n
Note that the investment decision is not all-or-nothing.
Here, xi ∈ {0,1} becomes xi ∈ [0,1] or 0 ≤ xi ≤ 1.
Teklebirhan A. Aksum University Chapter 1 Integer programming 13 / 124
Linear Programming vs. Integer Programming
Linear Programming
This is a linear program:
max
n
¼
i=1
vi xi
s.t.
n
¼
i=1
wi xi ≤ B
0 ≤ xi ≤ 1 ∀i = 1,...,n
Integer Programming
This is an integer program:
max
n
¼
i=1
vi xi
s.t.
n
¼
i=1
wi xi ≤ B
xi ∈ {0,1} ∀i = 1,...,n
Teklebirhan A. Aksum University Chapter 1 Integer programming 14 / 124
Introduction to Linear Programming
What is Linear Programming?
Linear Programming (LP) is a mathematical optimization
technique used to find the best outcome in a mathematical model
with linear constraints.
Linear Programming is the process of formulating and solving
linear programs (also abbreviated as LPs).
A LP is a mathematical program with some special properties.
Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
Introduction to Linear Programming
What is Linear Programming?
Linear Programming (LP) is a mathematical optimization
technique used to find the best outcome in a mathematical model
with linear constraints.
Linear Programming is the process of formulating and solving
linear programs (also abbreviated as LPs).
A LP is a mathematical program with some special properties.
In a two-dimensional linear programming problem, we represent
the constraints as lines and the feasible region as the
intersection of these lines.
Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
Introduction to Linear Programming
What is Linear Programming?
Linear Programming (LP) is a mathematical optimization
technique used to find the best outcome in a mathematical model
with linear constraints.
Linear Programming is the process of formulating and solving
linear programs (also abbreviated as LPs).
A LP is a mathematical program with some special properties.
In a two-dimensional linear programming problem, we represent
the constraints as lines and the feasible region as the
intersection of these lines.
The objective function is represented as a line with the slope
determined by the coefficients of the decision variables.
Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
Introduction to Linear Programming
What is Linear Programming?
Linear Programming (LP) is a mathematical optimization
technique used to find the best outcome in a mathematical model
with linear constraints.
Linear Programming is the process of formulating and solving
linear programs (also abbreviated as LPs).
A LP is a mathematical program with some special properties.
In a two-dimensional linear programming problem, we represent
the constraints as lines and the feasible region as the
intersection of these lines.
The objective function is represented as a line with the slope
determined by the coefficients of the decision variables.
The optimal solution is the point in the feasible region where the
objective function line is maximized or minimized.
Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
Basic Elements of a Mathematical Program
In general, any mathematical program may be expressed as:
min f(x1,x2,...,xn) (objective function)
s.t. gi (x1,x2,...,xn) ≤ bi ∀i = 1,...,m (constraints)
xj ∈ ‘ ∀j = 1,...,n (decision variable)
There are m constraints and n variables.
x1,x2,...,xn are real-valued decision variables.
We may write
x =










x1
.
.
.
xn










= (x1,...,xn)
as a vector of decision variables (or a decision vector).
f : ‘n → ‘ and gi : ‘n → ‘ are all real-valued functions.
Mostly we will omit xj ∈ ‘.
Teklebirhan A. Aksum University Chapter 1 Integer programming 16 / 124
Transformation
Transformation of Objective and Constraints
How about a maximization objective function?
maxf(x) ⇔ min−f(x).
How about "=" or "≥" constraints?
gi (x) ≥ bi ⇔ −gi (x) ≤ −bi .
gi (x) = bi ⇔ gi (x) ≤ bi and gi (x) ≥ bi , i.e., −gi (x) ≤ −bi .
Example
max x1 − x2
s.t. − 2x1 + x2 ≥ −3
x1 + 4x2 = 5
⇔
min − x1 + x2
s.t. 2x1 − x2 ≤ 3
x1 + 4x2 ≤ 5
− x1 − 4x2 ≤ −5.
Teklebirhan A. Aksum University Chapter 1 Integer programming 17 / 124
Feasible Solutions
For a mathematical program:
A feasible solution satisfies all the constraints.
An infeasible solution violates at least one constraint.
For example:
min2x1 + x2
s.t x1 ≤ 10
x1 + 2x2 ≤ 12
x1 − 2x2 ≥ −8
x1 ≥ 0,x2 ≥ 0
Feasible Solutions
x1 = (2,3)
x2 = (6,0)
x3 = (6,6)
Teklebirhan A. Aksum University Chapter 1 Integer programming 18 / 124
Feasible region and optimal solutions
Feasible Region
The feasible region (or feasible set) is the set of feasible solutions.
The feasible region may be empty.
Optimal Solutions
An optimal solution is a feasible solution that:
Attains the largest objective value for a maximization problem.
Attains the smallest objective value for a minimization problem.
In short, no feasible solution is better than it.
An optimal solution may not be unique.
There may be multiple optimal solutions.
There may be no optimal solution.
Teklebirhan A. Aksum University Chapter 1 Integer programming 19 / 124
Binding Constraints
Definition
At a solution, a constraint may be binding:
Let g(·) ≤ b be an inequality constraint and x̄ be a solution. g(·) ≤ b
is binding at x̄ if g(x̄) = b.
An inequality is nonbinding at a point if it is strict at that point.
An equality constraint is always binding at any feasible solution.
Some Examples:
x1 + x2 ≤ 10 is binding at (x1,x2) = (2,8).
2x1 + x2 ≥ 6 is nonbinding at (x1,x2) = (2,8).
x1 + 3x2 = 9 is binding at (x1,x2) = (6,1).
Teklebirhan A. Aksum University Chapter 1 Integer programming 20 / 124
Linear Programs
A mathematical program
minf(x) s.t. gi (x) ≤ bi ∀i = 1,...,m,
is a LP if f and gi are all linear functions.
Each of these linear functions may be expressed as
a1x1 + a2x2 + ··· + anxn =
´n
j=1 aj xj ,
where aj ∈ ‘, j = 1,...,n, are the coefficients.
We may write a = (a1,...,an) and f(x) = aT x.
An example:
minimize x1 + x2
subject to
x1 + 2x2 ≤ 6
2x1 + x2 ≤ 6
x1 ≥ 0, x2 ≥ 0.
Teklebirhan A. Aksum University Chapter 1 Integer programming 21 / 124
Linear Programs
In general, an LP may always
be expressed as
min
n
¼
j=1
cj xj
s.t.
n
¼
j=1
Aij xj ≤ bi ∀i = 1,...,m.
Aij s: constraint coefficients
bi s: right-hand-side values
(RHS).
cj s: objective coefficients.
Or by vectors:
mincT
x
s.t. aT
i x ≤ bi ∀i = 1,...,m.
ai ∈ ‘n, bi ∈ ‘, c ∈ ‘n
x ∈ ‘n
Or by matrices:
min cT
x
subject to: Ax ≤ b
A ∈ ‘m×n, b ∈ ‘m
Teklebirhan A. Aksum University Chapter 1 Integer programming 22 / 124
Standard Form of LP
Standard Form:
Maximize cT
x
Subject to Ax ≤ b
x ≥ 0
where:
x is the vector of decision variables.
c is the vector of coefficients of the objective function.
A is the matrix of coefficients of the constraints.
b is the vector of right-hand side constants of the constraints.
Teklebirhan A. Aksum University Chapter 1 Integer programming 23 / 124
Solution Techniques
Graphical Method
It is applicable only for LP problems with two decision variables.
Steps:
1 Graph the Constraints:
Convert each inequality constraint into an equation (replace ≤ with
=).
Plot the equations on a graph. Use the axes for x1 and x2.
Identify the feasible region by testing a point (often the origin) in the
inequalities. The resulting area where all inequalities overlap is the
feasible region.
2 Determine the Corners of the Feasible Region:
Identify the vertices (corner points) of the feasible region. These
vertices are typically where the constraint lines intersect.
3 Calculate the objective function value at each corner point of the
feasible region.
4 Identify the Optimal Solution:
If the LPP is maximization, take the highest value.
If the LPP is minimization, take the lowest value.
Teklebirhan A. Aksum University Chapter 1 Integer programming 24 / 124
Graphical approach
For LPs with only two decision variables, we may solve them with
the graphical approach.
Consider the following example:
maximize 2x1 + x2
subject to x1 ≤ 10
x1 + 2x2 ≤ 12
x1 − 2x2 ≥ −8
x1 ≥ 0
x2 ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 25 / 124
Graphical Approach
Step 1: Draw the Feasible Region
Draw each constraint one by one, and then find the intersection.
max 2x1 + x2
s.t. x1 ≤ 10
x1 + 2x2 ≤ 12
x1 − 2x2 ≥ −8
x1 ≥ 0
x2 ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 26 / 124
Graphical Approach
Step 2: Draw Some Isoquant Lines.
A line such that all points on it result in the same objective value.
Also called isoprofit or isocost lines when it is appropriate.
Also called indifference lines (curves) in Economics.
max 2x1 + x2
s.t. x1 ≤ 10
x1 + 2x2 ≤ 12
x1 − 2x2 ≥ −8
x1 ≥ 0
x2 ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 27 / 124
Graphical Approach
Step 3: Indicate the direction to push the isoquant line.
The direction that decreases/increases the objective value for a
minimization/maximization problem.
max 2x1 + x2
s.t. x1 ≤ 10
x1 + 2x2 ≤ 12
x1 − 2x2 ≥ −8
x1 ≥ 0
x2 ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 28 / 124
Step 4: Push the isoquant line to the "end" of the feasible region.
Stop when any further step makes all points on the isoquant line
infeasible.
Teklebirhan A. Aksum University Chapter 1 Integer programming 29 / 124
Step 5: Identify the binding constraints at an optimal solution.
Teklebirhan A. Aksum University Chapter 1 Integer programming 30 / 124
Graphical Approach
Step 6: Set the binding constraints to equalities and then solve
the linear system for an optimal solution.
In the example, the binding constraints are: x1 ≤ 10 and
x1 + 2x2 ≤ 12
We may solve the linear system:
x1 = 10
x1 + 2x2 = 12
in any way and obtain an optimal solution (x∗
1,x∗
2) = (10,1).
For example, through Gaussian elimination:
1 0 10
1 2 12
!
→
1 0 10
0 2 2
!
→
1 0 10
0 1 1
!
Step 7: Plug in an optimal solution obtained into the objective
function to get the associated objective value.
In the example, 2x∗
1 + x∗
2 = 21.
Teklebirhan A. Aksum University Chapter 1 Integer programming 31 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 32 / 124
Three types of LPs
For any LPs, it must be one of the following:
Infeasible.
Unbounded.
Finitely optimal (having an optimal solution).
A finitely optimal LP may have:
A unique optimal solution.
Multiple optimal solutions.
Teklebirhan A. Aksum University Chapter 1 Integer programming 33 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 34 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 35 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 36 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 37 / 124
Linear Programming Problem
Example
Solve the Linear programming problem
Maximize: Z = 4x1 + 7x2
Subject to:
2x1 + 5x2 ≤ 40
x1 + x2 ≤ 11
x2 ≥ 4
x1,x2 ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 38 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 39 / 124
Summary
Teklebirhan A. Aksum University Chapter 1 Integer programming 40 / 124
Simple LP Formulations: Introduction
It is important to learn how to model a practical situation as an LP.
Once you do so, you have "solved" the problem.
This process is typically called LP formulation or modeling.
Here we will see some examples of LP formulation.
Then we formulate large-scale problems with compact
formulations.
Example
A product mix problem
We produce several products to sell.
Each product requires some resources. Resources are limited.
We want to maximize the total sales revenue with available
resources.
Teklebirhan A. Aksum University Chapter 1 Integer programming 41 / 124
Description
Problem description
We produce desks and tables.
Producing a desk requires three units of wood, one hour of labor,
and 50 minutes of machine time.
Producing a table requires five units of wood, two hours of labor,
and 20 minutes of machine time.
We may sell everything we produce.
For each day, we have
Two hundred workers that each works for eight hours.
Fifty machines that each runs for sixteen hours.
A supply of 3600 units of wood.
Desks and tables are sold at $700 and $900 per unit, respectively.
Teklebirhan A. Aksum University Chapter 1 Integer programming 42 / 124
Variables
Define Variables
What do we need to decide?
Let
x1 = number of desks produced in a day
x2 = number of tables produced in a day
With these variables, we now try to express how much we will
earn and how many resources we will consume.
Formulate the Objective Function
We want to maximize the total sales revenue.
Given our variables x1 and x2, the sales revenue is 700x1 + 900x2.
The objective function is thus:
max 700x1 + 900x2.
Teklebirhan A. Aksum University Chapter 1 Integer programming 43 / 124
Formulate Constraints
For each restriction or limitation, we write a constraint:
The supply of wood is limited: 3x1 + 5x2 ≤ 3600
The number of labor hours is limited: x1 + 2x2 ≤ 1600
The amount of machine time is limited: 50x1 + 20x2 ≤ 48000
Note: Use the same unit of measurement!
Teklebirhan A. Aksum University Chapter 1 Integer programming 44 / 124
Complete Formulation
Collectively, our formulation is:
max 700x1 + 900x2 (Objective Function)
s.t. 3x1 + 5x2 ≤ 3600 (wood)
x1 + 2x2 ≤ 1600 (labor)
50x1 + 20x2 ≤ 48000 (machine)
x1 ≥ 0
x2 ≥ 0
In any case:
Clearly define decision variables in front of your formulation.
Write comments after the objective function and constraints.
Teklebirhan A. Aksum University Chapter 1 Integer programming 45 / 124
Solve and Interpret
An optimal solution of this LP is (884.21,189.47).
So, the interpretation is... to produce 884.21 desks and 189.47
tables?
Producing 884.21 desks and 189.47 tables seems weird, but in
fact:
We may produce 884.21 desks and 189.47 tables per day on
average (i.e., roughly 88,420 desks and 18,947 tables per 100
days).
We may suggest to produce, e.g., 884 desks and 189 tables.
It still supports our decision making.
It may not really be optimal, but we spend a very short time to
make a good suggestion.
"All models are wrong, but some are useful."
Teklebirhan A. Aksum University Chapter 1 Integer programming 46 / 124
Personnel scheduling
Teklebirhan A. Aksum University Chapter 1 Integer programming 47 / 124
Personnel scheduling
Teklebirhan A. Aksum University Chapter 1 Integer programming 48 / 124
Personnel scheduling
Teklebirhan A. Aksum University Chapter 1 Integer programming 49 / 124
Constraints
Demand fulfillment:
110 employees are needed on Monday:
x1 + x4 + x5 + x6 + x7 ≥ 110.
80 employees are needed on Tuesday:
x1 + x2 + x5 + x6 + x7 ≥ 80.
120 employees are needed on Sunday:
x3 + x4 + x5 + x6 + x7 ≥ 120.
Nonnegativity constraints:
xi ≥ 0 ∀i = 1,...,7.
Teklebirhan A. Aksum University Chapter 1 Integer programming 50 / 124
Personnel scheduling
Teklebirhan A. Aksum University Chapter 1 Integer programming 51 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 52 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 53 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 54 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 55 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 56 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 57 / 124
Compact
Teklebirhan A. Aksum University Chapter 1 Integer programming 58 / 124
Problems vs. instances
Teklebirhan A. Aksum University Chapter 1 Integer programming 59 / 124
Integer Programming
Introduction to integer programming
We have worked with LPs.
In linear programming problem, the variables are allowed to take
any real or fractional value, however in some cases, variables
must only take integer values.
The subject of formulating and solving models with integer
variables is Integer Programming (IP).
An IP is typically a linear IP (LIP).
If the objective function or any functional constraint is nonlinear, it
is a nonlinear IP (NLIP).
We will focus on linear IP.
Teklebirhan A. Aksum University Chapter 1 Integer programming 60 / 124
Personnel Scheduling (Again)
We know that United Airlines developed an LP to determine the
number of staff in each of their service locations.
The same problem is faced by Taco Bell.
It has more than 6500 restaurants in the US.
It asks how many staff to have at each restaurant in each shift.
Taco Bell developed an Integer Program (i.e., an LP with integer
variables) to solve its workforce scheduling problem.
The number of staff is typically small! Rounding is very inaccurate.
$13 million are saved per year.
Teklebirhan A. Aksum University Chapter 1 Integer programming 61 / 124
Route Selection
Waste Management Inc. operates an recycling network with 293
landfill sites, 16 waste-to-energy plants, 72 gas-to-energy
facilities, 146 recycling plants, 346 transfer stations, and 435
collection depots.
20,000 routes must be traversed by its vehicles each day.
How to determine a route?
Construct a network with nodes and edges.
Assign a binary variable to each edge: 1 if included, 0 otherwise.
Constraints are required to ensure that selected edges form a valid
route.
A large Integer Programming (IP) model is constructed to save the
company $498 million in operational expenses over a 5-year
period.
Teklebirhan A. Aksum University Chapter 1 Integer programming 62 / 124
Integer programming formulation
The Knapsack Problem
We start our illustration with the classic knapsack problem.
There are four items to select:
Item 1 2 3 4
Value ($) 16 22 12 8
Weight (kg) 5 7 4 3
The knapsack capacity is 10 kg.
We maximize the total value without exceeding the knapsack
capacity.
The Complete Formulation is
max16x1 + 22x2 + 12x3 + 8x4
s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10
xi ∈ {0,1} ∀i = 1,...,4
Teklebirhan A. Aksum University Chapter 1 Integer programming 63 / 124
Types of Integer Programming Problems
Integer programming problems can be classified into three categories:
1 Pure (all) integer programming problems in which all decision
variables are restricted to integer values.
2 Mixed integer programming problems in which some, but not all,
of the decision variables are restricted to integer values.
3 Zero-one integer programming problems in which all decision
variables are restricted to either zero (0) or one (1).
Teklebirhan A. Aksum University Chapter 1 Integer programming 64 / 124
Standard form of Pure Integer Programming Problem
The pure integer programming problem in its standard form can be
written as follows:
Maximize Z = c1x1 + c2x2 + ··· + cnxn,
subject to Constraints:
a11x1 + a12x2 + ··· + a1nxn = b1,
a21x1 + a22x2 + ··· + a2nxn = b2,
.
.
.
am1x1 + am2x2 + ··· + amnxn = bm,
x1,x2,...,xn ≥ 0 and integer.
Teklebirhan A. Aksum University Chapter 1 Integer programming 65 / 124
Solving IP
The branch-and-bound algorithm finds an optimal solution for
any IP.
It decomposes an IP to multiple LPs, solve all the LPs, and
compares those outcomes to reach a conclusion.
Each LP is solved separately (with the simplex method or other
ways).
In general, the process may take a very long time.
As finding an optimal solution for an IP may be too
time-consuming, we often look for a near-optimal feasible
solution instead in practice.
An algorithm that generates a feasible solution in a short time is
called a heuristic algorithm.
Hopefully it is near-optimal.
A good heuristic algorithm does not always work, but it works for
most of the time.
Teklebirhan A. Aksum University Chapter 1 Integer programming 66 / 124
Solving Integer Programs
Suppose we are given an IP,
how may we solve it?
The simplex method does not
work!
The feasible region is not a
region.
It is discrete.
There is no way to move
along edges.
But all we know is how to solve
LPs. How about solving a
linear relaxation first?
Definition
The LP obtained by removing all
the integer constraints from the
given IP is called Linear Relaxation.
Teklebirhan A. Aksum University Chapter 1 Integer programming 67 / 124
Linear Relaxation
What is the linear relaxation of
maxx1 + x2
s.t.x1 + 3x2 ≤ 10
2x1 − x2 ≥ 5
xi ∈ ™+
∀i = 1,2
where ™ is the set of all integers and ™+ is the set of all
non-negative integers.
The linear relaxation is
max x1 + x2
s.t. x1 + 3x2 ≤ 10
2x1 − x2 ≥ 5
xi ≥ 0 ∀i = 1,2
Teklebirhan A. Aksum University Chapter 1 Integer programming 68 / 124
Linear Relaxation
For the Knapsack Problem:
maximize 16x1 + 22x2 + 12x3 + 8x4
s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10
xi ∈ {0,1} ∀i = 1,...,4
The Linear Relaxation is:
maximize 16x1 + 22x2 + 12x3 + 8x4
s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10
xi ∈ [0,1] ∀i = 1,...,4
Note: xi ∈ [0,1] is equivalent to xi ≥ 0 and xi ≤ 1.
Teklebirhan A. Aksum University Chapter 1 Integer programming 69 / 124
Linear Relaxation Provides a Bound
For a minimization IP, its linear relaxation provides a lower bound.
Proposition
Let z∗ and z0 be the objective values associated with optimal solutions
of a minimization IP and its linear relaxation, respectively. Then,
z0 ≤ z∗.
Proof
Both have the same objective function.
The feasible region of the linear relaxation is (weakly) larger than that
of the IP.
For a maximization IP, linear relaxation provides an upper bound.
Teklebirhan A. Aksum University Chapter 1 Integer programming 70 / 124
Linear Relaxation and Integer Programming
Linear relaxation may solve the Integer Program (IP):
If we are lucky, the linear relaxation may be infeasible or
unbounded.
The IP is then infeasible or unbounded.
If we are lucky, an optimal solution to the linear relaxation may be
feasible to the original IP. When this happens, the IP is solved.
Proposition
Let x0 be an optimal solution to the linear relaxation of an IP. If x0 is
feasible to the IP, it is optimal to the IP.
Proof
Suppose x0 is not optimal to the IP; there must be another feasible
solution x00 that is better. However, as x00 is feasible to the IP, it is also
feasible to the linear relaxation, which implies that x0 cannot be
optimal to the linear relaxation.
What if we are unlucky?
Teklebirhan A. Aksum University Chapter 1 Integer programming 71 / 124
Rounding a Fractional Solution
Suppose we solve a linear relaxation with an LR-optimal solution
x0.
"LR-optimal" means x0 is optimal to the linear relaxation.
x0, however, has at least one variable violating the integer
constraint in the original Integer Program (IP).
We may choose to round the variable.
Round up or down?
Is the resulting solution always feasible?
Will the resulting solution be close to an IP-optimal solution x∗?
Teklebirhan A. Aksum University Chapter 1 Integer programming 72 / 124
Rounding
Teklebirhan A. Aksum University Chapter 1 Integer programming 73 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 74 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 75 / 124
Rounding a Fractional Solution
Rounding a fractional solution involves the following steps:
When we solve the linear relaxation and find any variable
violating an integer constraint, we will branch this problem into
two new problems, one with an additional constraint.
The two new programs are still linear programs.
Once we have solved them:
If their LR-optimal solutions are both IP-feasible, compare them and
choose the better one.
If any of them results in a variable violating the integer constraint,
branch on that variable recursively.
Eventually compare all the IP-feasible solutions we obtain.
Teklebirhan A. Aksum University Chapter 1 Integer programming 76 / 124
Illustration of the Branch-and-Bound Algorithm
Example
Let’s illustrate the
branch-and-bound algorithm
with the following example:
maximize 3x1 + x2
(P0) s.t. 4x1 + 2x2 ≤ 11
x1,x2 ∈ ™+
Teklebirhan A. Aksum University Chapter 1 Integer programming 77 / 124
Sub-problem 1
We first solve the linear
relaxation:
max 3x1 + x2
(P1) Subject to:
4x1 + 2x2 ≤ 11
xi ≥ 0 ∀i = 1,2
The optimal solution is:
x1
=

11
4
,0

So we need to branch on x1.
Teklebirhan A. Aksum University Chapter 1 Integer programming 78 / 124
Branching tree
The branch and bound algorithm produces a branching tree.
Each node represents a sub-problem (which is an LP).
Each time we branch on a variable, we create two child nodes.
Teklebirhan A. Aksum University Chapter 1 Integer programming 79 / 124
Sub-problem 2
When we add x1 ≤ 2:
max 3x1 + x2
(P2) Subject to:
4x1 + 2x2 ≤ 11
x1 ≤ 2
xi ≥ 0 ∀i = 1,2
An (P2)-optimal solution is
x2 = (2, 3
2).
So later we need to branch
on x2.
Before that, let’s solve (P3).
Teklebirhan A. Aksum University Chapter 1 Integer programming 80 / 124
Sub-problem 3
When we add x1 ≤ 3:
max 3x1 + x2
Subject to:
(P3) 4x1 + 2x2 ≤ 11
x1 ≥ 3
xi ≥ 0 ∀i = 1,2
The problem is infeasible!
This node is dead and does
not produce any candidate
solution
Teklebirhan A. Aksum University Chapter 1 Integer programming 81 / 124
Branching tree
The current progress can be summarized in the branching tree
Note that z2 = 7.5  8.25 = z1.
In general, when we branch to the next level, the objective value
associated with a sub-problem-optimal solution will always be
weakly lower (for a maximization problem). Why?
Teklebirhan A. Aksum University Chapter 1 Integer programming 82 / 124
Branching tree
As x2 = 3
2 in x2, we will branch sub-problem 2 on x2.
Teklebirhan A. Aksum University Chapter 1 Integer programming 83 / 124
Subproblem-4
Teklebirhan A. Aksum University Chapter 1 Integer programming 84 / 124
Subproblem-5
Teklebirhan A. Aksum University Chapter 1 Integer programming 85 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 86 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 87 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 88 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 89 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 90 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 91 / 124
Summary
In running the branch-and-bound algorithm, we maintain a tree.
If a subproblem-optimal solution is IP-feasible, set it to the
candidate solution if it is currently the best among all IP-feasible
solutions. Stop branching this node.
If a subproblem is infeasible, stop branching this node.
If a subproblem-optimal solution is not IP-feasible:
If it is better than the current candidate solution, branch.
Otherwise, stop branching.
Teklebirhan A. Aksum University Chapter 1 Integer programming 92 / 124
The Knapsack Problem
We start our illustration with the classic knapsack problem.
There are five items to select:
Item 1 2 3 4 5
Value ($) 2 3 4 1 3
Weight (kg) 4 5 3 1 4
The knapsack capacity is 11 kg.
We maximize the total value without exceeding the knapsack
capacity.
The Complete Formulation
max 2x1 + 3x2 + 4x3 + x4 + 3x5
s.t. 4x1 + 5x2 + 3x3 + x4 + 4x5 ≤ 11
xi ∈ {0,1} ∀i = 1,...,5
Let’s solve the knapsack problem with the branch-and-bound
algorithm.
Teklebirhan A. Aksum University Chapter 1 Integer programming 93 / 124
Solving the linear relaxation
The first step is always to solve the linear relaxation:
max 2x1 + 3x2 + 4x3 + x4 + 3x5
s.t. 4x1 + 5x2 + 3x3 + x4 + 4x5 ≤ 11
xi ∈ [0,1] ∀i = 1,...,5.
A very intuitive way works:
Sort all items in the descending order of vi
wi
, where vi and wi are the
value and weight of item i, respectively.
Select items one by one according to the order until the knapsack
is full. Note that the last item may be partially selected.
The five ratios are 2
4, 3
5, 4
3, 1
1, and 3
4. The order is item 3, item 4,
item 5, item 2, and lastly item 1.
An optimal solution to the linear relaxation is (0, 3
5 ,1,1,1).
Teklebirhan A. Aksum University Chapter 1 Integer programming 94 / 124
Subproblems
Teklebirhan A. Aksum University Chapter 1 Integer programming 95 / 124
Cont...
Teklebirhan A. Aksum University Chapter 1 Integer programming 96 / 124
Cont...
Teklebirhan A. Aksum University Chapter 1 Integer programming 97 / 124
Cont...
Teklebirhan A. Aksum University Chapter 1 Integer programming 98 / 124
Remarks
The major process is still branch and bound.
The only unique thing is that we have a special way to solve the
linear relaxation of the knapsack problem.
In other words, we may customize the branch-and-bound
algorithm for each specific type of IP.
Teklebirhan A. Aksum University Chapter 1 Integer programming 99 / 124
Procedure of Branch and Bound Algorithm
Step: 1 (Initialization)
Consider the following all integer programming problem:
Max Z = c1x1 + c2x2+... + cnxn
Subject to the constraints:
a11x1 + a12x2 + ... + a1nxn = b1
a21x1 + a22x2 + ... + a2nxn = b2
...
am1x1 + am2x2 + ... + amnxn = bm
and xj ≥ 0 and non-negative integer.
Teklebirhan A. Aksum University Chapter 1 Integer programming 100 / 124
Obtain the optimal solution of the given problem
ignoring integer restriction on the variables
1 If the solution to this LP problem (say LP-A) is infeasible or
unbounded, the solution to the all integer programming problem
is also infeasible or unbounded, as the case may be.
2 If the solution satisfies the integer restriction, the optimal integer
solution has been obtained. If one or more basic variables do not
satisfy the integer requirement, then go to step 2. Let the optimal
value of the objective function of LP-A be Z1. This value provides
an initial upper bound on the objective function value and it is
denoted by ZU .
3 Find the feasible value by rounding off each variable value. The
value of the objective function so obtained is the least upper
bound and it is denoted by ZL .
Teklebirhan A. Aksum University Chapter 1 Integer programming 101 / 124
Step 2: Branching Step
1 Let xk be one basic variable which does not have an integer value
and also has the largest fractional value.
2 Branch (or partition) the LP-A into two new LP sub-problems (also
called nodes) based on integer values of xk that are immediately
above and below its non-integer value. That is, it is partitioned by
adding two mutually exclusive constraints: xk ≤ ⌊xk ⌋ and
xk ≥ ⌊xk ⌋ + 1 to the original LP problem.
3 Here ⌊xk ⌋ is the integer portion of the current non-integer value of
the variable xk . This is obviously done to exclude the non-integer
value of the variable xk . The two new LP sub-problems are as
follows:
Teklebirhan A. Aksum University Chapter 1 Integer programming 102 / 124
LP Sub-problem B
Max Z =
n
¼
j=1
cj xj
subject to
n
¼
j=1
aij xj = bi
xk ≤ ⌊xk ⌋
and xj ≥ 0
LP Sub-problem C
Max Z =
n
¼
j=1
cj xj
subject to
n
¼
j=1
aij xj = bi
xk ≥ ⌊xk ⌋ + 1
and xj ≥ 0
Teklebirhan A. Aksum University Chapter 1 Integer programming 103 / 124
Step 3: Bound Step
Obtain the optimal solution of LP Subproblem B. Let the optimal
value of the objective function of LP-B be Z2.
Obtain the optimal solution of LP Subproblem C. Let the optimal
value of the objective function of LP-C be Z3.
The best integer solution value becomes the lower bound on the
integer LP problem objective function value (initially this is the
rounded off value). Let the lower bound be denoted by ZL .
Teklebirhan A. Aksum University Chapter 1 Integer programming 104 / 124
Step 04: (Fathoming Step) Examining the solution of
both LP-B and LP-C:
1 If the sub-problem yields an infeasible solution, then terminate
the branch.
2 If the sub-problems yield a feasible solution, but not an integer
solution, then go to Step 02.
3 If the sub-problem yields an integer feasible solution, then
examine the value of the objective function.
If the value is equal to the upper bound, then the optimal solution
has been obtained.
If it is not equal to the upper bound but exceeds the lower bound,
then this value is considered as the new upper bound and return to
step 2. Finally, If it is less than the lower bound terminate the
branch.
Teklebirhan A. Aksum University Chapter 1 Integer programming 105 / 124
Step 05 (Termination)
Procedure of branching and bounded continues, until no sub
problem remains to be examined.
At this stage, the integer solution corresponding to the current
lower bound is optimal all integer programming problem.
Teklebirhan A. Aksum University Chapter 1 Integer programming 106 / 124
Branch and bound method example
Example
Solve the following integer programming problem using branch and
bound method:
Maximize Z = 2x1 + 3x2
Subject to 6x1 + 5x2 ≤ 25,
x1 + 3x2 ≤ 10,
x1,x2 ≥ 0, x1,x2 are integers.
Teklebirhan A. Aksum University Chapter 1 Integer programming 107 / 124
Solution: Step 01
Relaxing the integer condition, Let us find the optimal solution to the
given LP problem by graphical method.
Graphical Method
Let us draw the line 6x1 + 4x2 = 25
Let x1 = 0, 6(0) + 4x2 = 25 =⇒ x2 = 25/4 i.e. (0,5)
Let x2 = 0, 6x1 + 4(0) = 25 =⇒ x1 = 25/6 i.e. (4.16,0)
Let us draw the line x1 + 3x2 = 10
Let x1 = 0, 0 + 3x2 = 10 =⇒ x2 = 10/3 i.e. (0,3.33)
Let x2 = 0, x1 + 3(0) = 10 =⇒ x1 = 10 i.e. (10,0)
Teklebirhan A. Aksum University Chapter 1 Integer programming 108 / 124
Step 1 Cont.
To find the intersection point:
(1) ⇒ 6x1 + 5x2 = 25
(2) ⇒ 6x1 + 18x2 = 60
Subtracting the two equations:
−13x2 = −35 =⇒ x2 = 35
13
Substitute x2 value in equation (1) to get x1 = 35
13 i.e. the
intersection point is (1.92,2.69)
At (4.16,0), Max Z = 2(4.16) + 3(0) = 8.32
At (0,3.33), Max Z = 2(0) + 3(3.33) = 9.99
At (1.92,2.69), Max Z = 2(1.92) + 3(2.69) = 11.91
Teklebirhan A. Aksum University Chapter 1 Integer programming 109 / 124
Teklebirhan A. Aksum University Chapter 1 Integer programming 110 / 124
Cont.
The optimum solution is x1 = 1.92, x2 = 2.69 and Max Z1 = 11.91.
Let ZU = 11.91 be the initial upper bound.
The feasible solution by rounding off the solution gives the initial
lower bound ZL = 11 (rounding off x1 = 1, x2 = 3).
The optimal solution lies between these two bounds.
Teklebirhan A. Aksum University Chapter 1 Integer programming 111 / 124
Step 02 (Branching step)
Here both x1 and x2 are not integers, therefore we can select the
variable for branching with the highest fractional value, here x2
has a higher fractional value compared to x1.
Solving the variable x2 for branching, divide the given problem
into two subproblems A and B to eliminate the fractional part of
x2 = 2.69.
The new constraints to be added are x2 ≤ 2 and x2 ≥ 3.
Teklebirhan A. Aksum University Chapter 1 Integer programming 112 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 113 / 124
Cont’d
The corresponding graph is given by
Teklebirhan A. Aksum University Chapter 1 Integer programming 114 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 115 / 124
Step 03 (Bound step)
Rule: The best integer solution gives the lower bound.
Here the best integer solution is x1 = 1, x2 = 3 and Max Z3 = 11.
The value ZL = 11 is the lower bound for the given LP problem.
Step 04 (Fathoming step)
Both the sub-problems B and C give the same Z value.
In the sub-problem C, both the variables x1 and x2 are integers, so
there is no need to branch the sub-problem C further.
Since ZL ≤ Z3  ZU (11 ≤ 11  11.91), therefore the new upper
bound is ZU = 11.
In the sub-problem B, x1 is not an integer and since ZL ≤ Z2
(11 ≤ 11), therefore the sub-problem B can be branched further.
Teklebirhan A. Aksum University Chapter 1 Integer programming 116 / 124
Stet 05 (Branch step)
Let us divide the sub problem B into two sub problems, D and E, by
taking variable x1 = 2.5.
The new constraints to be added are x1 ≤ 2 and x1 ≥ 3.
Teklebirhan A. Aksum University Chapter 1 Integer programming 117 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 118 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 119 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 120 / 124
Cont’d
Rule: The best integer solution gives the lower bound.
Here the best integer solution is x1 = 2, x2 = 2, and MaxZ4 = 10.
The solution to the LP sub problem D is integer feasible, but Z4  ZL
(10  11), and since the value of the lower bound remains unchanged
(ZL = 11), therefore the sub problem D is not considered for further
branching.
Teklebirhan A. Aksum University Chapter 1 Integer programming 121 / 124
Cont’d
Since the solution of sub problem E is non-integer (x2 is not an
integer), it can be further branched with variable x2, but Z5  ZL
(10.2  11). Therefore, sub problem E is not considered for further
branching.
Thus, the integer solution corresponding to the current lower
bound is the optimal solution.
Hence the integer optimal solution is corresponding to sub
problem C and is given by x1 = 1, x2 = 3, and MaxZ = 11.
The entire branch and bound procedure can be represented by the
following enumeration tree. Each node is a sub problem.
Teklebirhan A. Aksum University Chapter 1 Integer programming 122 / 124
Cont’d
Teklebirhan A. Aksum University Chapter 1 Integer programming 123 / 124
Note
If both sub-problems give non-integer solutions, then the
sub-problem with the maximum objective value should be further
branched.
If one of the sub-problems has no feasible solution and the other
has a feasible solution, but it is not integer, and any other
sub-problem is the same. kind exist, always select the sub
problem which has maximum objective function value for further
branching.
Teklebirhan A. Aksum University Chapter 1 Integer programming 124 / 124
Ad

Recommended

A0311010106
A0311010106
theijes
 
Duality Theory in Multi Objective Linear Programming Problems
Duality Theory in Multi Objective Linear Programming Problems
theijes
 
Tudelft stramien 16_9_on_optimization
Tudelft stramien 16_9_on_optimization
Pirouz Nourian
 
nnml.ppt
nnml.ppt
yang947066
 
Ch11_LPIntro.pdf
Ch11_LPIntro.pdf
yebegashet
 
1 resource optimization 2
1 resource optimization 2
shushay hailu
 
Operations research.pptx
Operations research.pptx
ssuserad3989
 
Machine Learning and Artificial Neural Networks.ppt
Machine Learning and Artificial Neural Networks.ppt
Anshika865276
 
LINEAR PROGRAMMING
LINEAR PROGRAMMING
rashi9
 
Optimization and particle swarm optimization (O & PSO)
Optimization and particle swarm optimization (O & PSO)
Engr Nosheen Memon
 
Optimization Techniques.pdf
Optimization Techniques.pdf
anandsimple
 
Ms nikita greedy agorithm
Ms nikita greedy agorithm
Nikitagupta123
 
Efficient projections
Efficient projections
Tomasz Waszczyk
 
Efficient projections
Efficient projections
Tomasz Waszczyk
 
Deep learning Unit1 BasicsAllllllll.pptx
Deep learning Unit1 BasicsAllllllll.pptx
FreefireGarena30
 
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
glorypreciousj
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Algorithm Design Techiques, divide and conquer
Algorithm Design Techiques, divide and conquer
Minakshee Patil
 
linear programing is the model that can be
linear programing is the model that can be
BegetaChalkut
 
Introduction to Optimization revised.ppt
Introduction to Optimization revised.ppt
JahnaviGautam
 
Chapter 5.pptx
Chapter 5.pptx
Tekle12
 
Minimization of Assignment Problems
Minimization of Assignment Problems
ijtsrd
 
Thesis
Thesis
Yehia ABD ALRahman
 
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
danielgetachew0922
 
#2. Limitations of Operation Research.pdf
#2. Limitations of Operation Research.pdf
bizuayehuadmasu1
 
Machine learning and Neural Networks
Machine learning and Neural Networks
butest
 
Recursion in Java
Recursion in Java
Fulvio Corno
 
How to Customize Quotation Layouts in Odoo 18
How to Customize Quotation Layouts in Odoo 18
Celine George
 
HistoPathology Ppt. Arshita Gupta for Diploma
HistoPathology Ppt. Arshita Gupta for Diploma
arshitagupta674
 

More Related Content

Similar to Chapter 1 Integer programming problemspdf (20)

LINEAR PROGRAMMING
LINEAR PROGRAMMING
rashi9
 
Optimization and particle swarm optimization (O & PSO)
Optimization and particle swarm optimization (O & PSO)
Engr Nosheen Memon
 
Optimization Techniques.pdf
Optimization Techniques.pdf
anandsimple
 
Ms nikita greedy agorithm
Ms nikita greedy agorithm
Nikitagupta123
 
Efficient projections
Efficient projections
Tomasz Waszczyk
 
Efficient projections
Efficient projections
Tomasz Waszczyk
 
Deep learning Unit1 BasicsAllllllll.pptx
Deep learning Unit1 BasicsAllllllll.pptx
FreefireGarena30
 
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
glorypreciousj
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Algorithm Design Techiques, divide and conquer
Algorithm Design Techiques, divide and conquer
Minakshee Patil
 
linear programing is the model that can be
linear programing is the model that can be
BegetaChalkut
 
Introduction to Optimization revised.ppt
Introduction to Optimization revised.ppt
JahnaviGautam
 
Chapter 5.pptx
Chapter 5.pptx
Tekle12
 
Minimization of Assignment Problems
Minimization of Assignment Problems
ijtsrd
 
Thesis
Thesis
Yehia ABD ALRahman
 
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
danielgetachew0922
 
#2. Limitations of Operation Research.pdf
#2. Limitations of Operation Research.pdf
bizuayehuadmasu1
 
Machine learning and Neural Networks
Machine learning and Neural Networks
butest
 
Recursion in Java
Recursion in Java
Fulvio Corno
 
LINEAR PROGRAMMING
LINEAR PROGRAMMING
rashi9
 
Optimization and particle swarm optimization (O & PSO)
Optimization and particle swarm optimization (O & PSO)
Engr Nosheen Memon
 
Optimization Techniques.pdf
Optimization Techniques.pdf
anandsimple
 
Ms nikita greedy agorithm
Ms nikita greedy agorithm
Nikitagupta123
 
Deep learning Unit1 BasicsAllllllll.pptx
Deep learning Unit1 BasicsAllllllll.pptx
FreefireGarena30
 
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
SINGLE VARIABLE OPTIMIZATION AND MULTI VARIABLE OPTIMIZATIUON.pptx
glorypreciousj
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
Determination of Optimal Product Mix for Profit Maximization using Linear Pro...
IJERA Editor
 
Algorithm Design Techiques, divide and conquer
Algorithm Design Techiques, divide and conquer
Minakshee Patil
 
linear programing is the model that can be
linear programing is the model that can be
BegetaChalkut
 
Introduction to Optimization revised.ppt
Introduction to Optimization revised.ppt
JahnaviGautam
 
Chapter 5.pptx
Chapter 5.pptx
Tekle12
 
Minimization of Assignment Problems
Minimization of Assignment Problems
ijtsrd
 
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
Ch3(1).pptxbbbbbbbbbbbbbbbbbbbhhhhhhhhhh
danielgetachew0922
 
#2. Limitations of Operation Research.pdf
#2. Limitations of Operation Research.pdf
bizuayehuadmasu1
 
Machine learning and Neural Networks
Machine learning and Neural Networks
butest
 

Recently uploaded (20)

How to Customize Quotation Layouts in Odoo 18
How to Customize Quotation Layouts in Odoo 18
Celine George
 
HistoPathology Ppt. Arshita Gupta for Diploma
HistoPathology Ppt. Arshita Gupta for Diploma
arshitagupta674
 
How to use _name_search() method in Odoo 18
How to use _name_search() method in Odoo 18
Celine George
 
2025 June Year 9 Presentation: Subject selection.pptx
2025 June Year 9 Presentation: Subject selection.pptx
mansk2
 
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
nabilahk908
 
English 3 Quarter 1_LEwithLAS_Week 1.pdf
English 3 Quarter 1_LEwithLAS_Week 1.pdf
DeAsisAlyanajaneH
 
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
Ultimatewinner0342
 
Romanticism in Love and Sacrifice An Analysis of Oscar Wilde’s The Nightingal...
Romanticism in Love and Sacrifice An Analysis of Oscar Wilde’s The Nightingal...
KaryanaTantri21
 
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
Kweku Zurek
 
How to use search fetch method in Odoo 18
How to use search fetch method in Odoo 18
Celine George
 
Gladiolous Cultivation practices by AKL.pdf
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
Q1_TLE 8_Week 1- Day 1 tools and equipment
Q1_TLE 8_Week 1- Day 1 tools and equipment
clairenotado3
 
Tanja Vujicic - PISA for Schools contact Info
Tanja Vujicic - PISA for Schools contact Info
EduSkills OECD
 
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
IIT Kharagpur Quiz Club
 
Photo chemistry Power Point Presentation
Photo chemistry Power Point Presentation
mprpgcwa2024
 
VCE Literature Section A Exam Response Guide
VCE Literature Section A Exam Response Guide
jpinnuck
 
Values Education 10 Quarter 1 Module .pptx
Values Education 10 Quarter 1 Module .pptx
JBPafin
 
Learning Styles Inventory for Senior High School Students
Learning Styles Inventory for Senior High School Students
Thelma Villaflores
 
ENGLISH-5 Q1 Lesson 1.pptx - Story Elements
ENGLISH-5 Q1 Lesson 1.pptx - Story Elements
Mayvel Nadal
 
LDMMIA Yoga S10 Free Workshop Grad Level
LDMMIA Yoga S10 Free Workshop Grad Level
LDM & Mia eStudios
 
How to Customize Quotation Layouts in Odoo 18
How to Customize Quotation Layouts in Odoo 18
Celine George
 
HistoPathology Ppt. Arshita Gupta for Diploma
HistoPathology Ppt. Arshita Gupta for Diploma
arshitagupta674
 
How to use _name_search() method in Odoo 18
How to use _name_search() method in Odoo 18
Celine George
 
2025 June Year 9 Presentation: Subject selection.pptx
2025 June Year 9 Presentation: Subject selection.pptx
mansk2
 
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
nabilahk908
 
English 3 Quarter 1_LEwithLAS_Week 1.pdf
English 3 Quarter 1_LEwithLAS_Week 1.pdf
DeAsisAlyanajaneH
 
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
Ultimatewinner0342
 
Romanticism in Love and Sacrifice An Analysis of Oscar Wilde’s The Nightingal...
Romanticism in Love and Sacrifice An Analysis of Oscar Wilde’s The Nightingal...
KaryanaTantri21
 
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
Kweku Zurek
 
How to use search fetch method in Odoo 18
How to use search fetch method in Odoo 18
Celine George
 
Gladiolous Cultivation practices by AKL.pdf
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
Q1_TLE 8_Week 1- Day 1 tools and equipment
Q1_TLE 8_Week 1- Day 1 tools and equipment
clairenotado3
 
Tanja Vujicic - PISA for Schools contact Info
Tanja Vujicic - PISA for Schools contact Info
EduSkills OECD
 
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
IIT Kharagpur Quiz Club
 
Photo chemistry Power Point Presentation
Photo chemistry Power Point Presentation
mprpgcwa2024
 
VCE Literature Section A Exam Response Guide
VCE Literature Section A Exam Response Guide
jpinnuck
 
Values Education 10 Quarter 1 Module .pptx
Values Education 10 Quarter 1 Module .pptx
JBPafin
 
Learning Styles Inventory for Senior High School Students
Learning Styles Inventory for Senior High School Students
Thelma Villaflores
 
ENGLISH-5 Q1 Lesson 1.pptx - Story Elements
ENGLISH-5 Q1 Lesson 1.pptx - Story Elements
Mayvel Nadal
 
LDMMIA Yoga S10 Free Workshop Grad Level
LDMMIA Yoga S10 Free Workshop Grad Level
LDM & Mia eStudios
 
Ad

Chapter 1 Integer programming problemspdf

  • 1. Operations Research(Math3151) Lecture 1 Integer programming Teklebirhan A. Aksum University January 13, 2025 Teklebirhan A. Aksum University Chapter 1 Integer programming 1 / 124
  • 2. Outlines 1 Integer programming 2 Deterministic dynamic programming 3 Inventory models 4 Forecasting 5 Decision theory 6 Queuing systems 7 Simulation modeling Teklebirhan A. Aksum University Chapter 1 Integer programming 2 / 124
  • 3. Motivation resources in an organization Management is the attainment of organizational goals in an effective and efficient manner through planning, organizing, leading, and controlling organizational resources. What are resources in an organization? Setting an objective requires strategic thinking, experiences, vision, etc. "Resource allocation" uses Operations Research (OR). Names of similar subjects/ideas: Management science. Decision science. Optimization method/algorithm. Mathematical programming. Teklebirhan A. Aksum University Chapter 1 Integer programming 3 / 124
  • 4. Example: job allocation Two people are going to hold an event, and they need to complete some tasks. One task must be assigned to exactly one person; one person can work on one task at a time. How to assign the tasks so that they can complete all tasks the fastest? What are the resources? What is the objective? ID Task Processing Time (min) 1 Boiling boba 20 2 Brewing milk tea 30 3 Baking cookies 60 4 Designing poster 15 5 Renting handcart 25 Teklebirhan A. Aksum University Chapter 1 Integer programming 4 / 124
  • 5. Example: Project Management n workers are going to complete m jobs in a project. Some jobs must be processed with precedence rules. Some jobs cannot be done by certain workers. Some jobs can be split and allocated to several workers. Some jobs require different processing time if allocated to different workers. How many days does it take to complete this project? Teklebirhan A. Aksum University Chapter 1 Integer programming 5 / 124
  • 6. What is Operations Research? Operations Research (OR) is: the methodology to allocate the available resources to the various activities in a way that is most effective for the organization as a whole. It is applied to problems that concern how to conduct and coordinate the operations (i.e., activities) within an organization. It aims to support decision making. Typical tools: intuitions, business senses, and experiences. By doing OR studies, we generate some suggestions to decision makers. Teklebirhan A. Aksum University Chapter 1 Integer programming 6 / 124
  • 7. The process of conducting an OR study Teklebirhan A. Aksum University Chapter 1 Integer programming 7 / 124
  • 8. Example: Knapsack Problem You are preparing for hiking. There are some useful items, but your backpack (knapsack) can only carry 5 kilograms. An item cannot be split: Each item should be either chosen or discarded. Which items should you bring to maximize the total value? ID Item Weight Value 1 Compass 0.5 6 2 Hatchet 1.5 5 3 Matches 0.4 4 4 Tarpaulin 1.0 4 5 Telescope 1.1 3 6 Cylinder 1.6 4 7 Rilakkuma 0.8 1 Teklebirhan A. Aksum University Chapter 1 Integer programming 8 / 124
  • 10. A Mathematical Programming Model Decision variables: What may we determine? xi =        1 if item i is chosen; 0 otherwise. Objective function: What do we want? max6x1 + 5x2 + 4x3 + 4x4 + 3x5 + 4x6 + x7 Constraints: What are the limitations? 0.5x1 + 1.5x2 + 0.4x3 + x4 + 1.1x5 + 1.6x6 + 0.8x7 ≤ 5 and xi ∈ {0,1},∀i = 1,...,7 Complete Formulation (Model) max 6x1 + 5x2 + 4x3 + 4x4 + 3x5 + 4x6 + x7 s.t. 0.5x1 + 1.5x2 + 0.4x3 + x4 + 1.1x5 + 1.6x6 + 0.8x7 ≤ 5 xi ∈ {0,1}, ∀i = 1,...,7 Teklebirhan A. Aksum University Chapter 1 Integer programming 10 / 124
  • 11. A Compact Formulation (Advanced) Let wi and vi be the weight and value of item i. Let n be the number of items and B be the maximum allowable weight. A compact (and more abstract) formulation is: max n ¼ i=1 vi xi subject to n ¼ i=1 wi xi ≤ B xi ∈ {0,1} ∀i = 1,...,n. Teklebirhan A. Aksum University Chapter 1 Integer programming 11 / 124
  • 12. Application: Order Selection Let wi and vi be the processing time and gross profit of order i. Let n be the number of orders and B be the factory capacity (the maximum total processing time that a factory has). The formulation is (still) max n ¼ i=1 vi xi s.t. n ¼ i=1 wi xi ≤ B xi ∈ {0,1} ∀i = 1,...,n Teklebirhan A. Aksum University Chapter 1 Integer programming 12 / 124
  • 13. Application: Portfolio Optimization Let wi and vi be the maximum possible investment amount and expected return of stock i. Let n be the number of assets and B be the total budget. The formulation is max n ¼ i=1 vi xi s.t. n ¼ i=1 wi xi ≤ B 0 ≤ xi ≤ 1 ∀i = 1,...,n Note that the investment decision is not all-or-nothing. Here, xi ∈ {0,1} becomes xi ∈ [0,1] or 0 ≤ xi ≤ 1. Teklebirhan A. Aksum University Chapter 1 Integer programming 13 / 124
  • 14. Linear Programming vs. Integer Programming Linear Programming This is a linear program: max n ¼ i=1 vi xi s.t. n ¼ i=1 wi xi ≤ B 0 ≤ xi ≤ 1 ∀i = 1,...,n Integer Programming This is an integer program: max n ¼ i=1 vi xi s.t. n ¼ i=1 wi xi ≤ B xi ∈ {0,1} ∀i = 1,...,n Teklebirhan A. Aksum University Chapter 1 Integer programming 14 / 124
  • 15. Introduction to Linear Programming What is Linear Programming? Linear Programming (LP) is a mathematical optimization technique used to find the best outcome in a mathematical model with linear constraints. Linear Programming is the process of formulating and solving linear programs (also abbreviated as LPs). A LP is a mathematical program with some special properties. Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
  • 16. Introduction to Linear Programming What is Linear Programming? Linear Programming (LP) is a mathematical optimization technique used to find the best outcome in a mathematical model with linear constraints. Linear Programming is the process of formulating and solving linear programs (also abbreviated as LPs). A LP is a mathematical program with some special properties. In a two-dimensional linear programming problem, we represent the constraints as lines and the feasible region as the intersection of these lines. Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
  • 17. Introduction to Linear Programming What is Linear Programming? Linear Programming (LP) is a mathematical optimization technique used to find the best outcome in a mathematical model with linear constraints. Linear Programming is the process of formulating and solving linear programs (also abbreviated as LPs). A LP is a mathematical program with some special properties. In a two-dimensional linear programming problem, we represent the constraints as lines and the feasible region as the intersection of these lines. The objective function is represented as a line with the slope determined by the coefficients of the decision variables. Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
  • 18. Introduction to Linear Programming What is Linear Programming? Linear Programming (LP) is a mathematical optimization technique used to find the best outcome in a mathematical model with linear constraints. Linear Programming is the process of formulating and solving linear programs (also abbreviated as LPs). A LP is a mathematical program with some special properties. In a two-dimensional linear programming problem, we represent the constraints as lines and the feasible region as the intersection of these lines. The objective function is represented as a line with the slope determined by the coefficients of the decision variables. The optimal solution is the point in the feasible region where the objective function line is maximized or minimized. Teklebirhan A. Aksum University Chapter 1 Integer programming 15 / 124
  • 19. Basic Elements of a Mathematical Program In general, any mathematical program may be expressed as: min f(x1,x2,...,xn) (objective function) s.t. gi (x1,x2,...,xn) ≤ bi ∀i = 1,...,m (constraints) xj ∈ ‘ ∀j = 1,...,n (decision variable) There are m constraints and n variables. x1,x2,...,xn are real-valued decision variables. We may write x =           x1 . . . xn           = (x1,...,xn) as a vector of decision variables (or a decision vector). f : ‘n → ‘ and gi : ‘n → ‘ are all real-valued functions. Mostly we will omit xj ∈ ‘. Teklebirhan A. Aksum University Chapter 1 Integer programming 16 / 124
  • 20. Transformation Transformation of Objective and Constraints How about a maximization objective function? maxf(x) ⇔ min−f(x). How about "=" or "≥" constraints? gi (x) ≥ bi ⇔ −gi (x) ≤ −bi . gi (x) = bi ⇔ gi (x) ≤ bi and gi (x) ≥ bi , i.e., −gi (x) ≤ −bi . Example max x1 − x2 s.t. − 2x1 + x2 ≥ −3 x1 + 4x2 = 5 ⇔ min − x1 + x2 s.t. 2x1 − x2 ≤ 3 x1 + 4x2 ≤ 5 − x1 − 4x2 ≤ −5. Teklebirhan A. Aksum University Chapter 1 Integer programming 17 / 124
  • 21. Feasible Solutions For a mathematical program: A feasible solution satisfies all the constraints. An infeasible solution violates at least one constraint. For example: min2x1 + x2 s.t x1 ≤ 10 x1 + 2x2 ≤ 12 x1 − 2x2 ≥ −8 x1 ≥ 0,x2 ≥ 0 Feasible Solutions x1 = (2,3) x2 = (6,0) x3 = (6,6) Teklebirhan A. Aksum University Chapter 1 Integer programming 18 / 124
  • 22. Feasible region and optimal solutions Feasible Region The feasible region (or feasible set) is the set of feasible solutions. The feasible region may be empty. Optimal Solutions An optimal solution is a feasible solution that: Attains the largest objective value for a maximization problem. Attains the smallest objective value for a minimization problem. In short, no feasible solution is better than it. An optimal solution may not be unique. There may be multiple optimal solutions. There may be no optimal solution. Teklebirhan A. Aksum University Chapter 1 Integer programming 19 / 124
  • 23. Binding Constraints Definition At a solution, a constraint may be binding: Let g(·) ≤ b be an inequality constraint and x̄ be a solution. g(·) ≤ b is binding at x̄ if g(x̄) = b. An inequality is nonbinding at a point if it is strict at that point. An equality constraint is always binding at any feasible solution. Some Examples: x1 + x2 ≤ 10 is binding at (x1,x2) = (2,8). 2x1 + x2 ≥ 6 is nonbinding at (x1,x2) = (2,8). x1 + 3x2 = 9 is binding at (x1,x2) = (6,1). Teklebirhan A. Aksum University Chapter 1 Integer programming 20 / 124
  • 24. Linear Programs A mathematical program minf(x) s.t. gi (x) ≤ bi ∀i = 1,...,m, is a LP if f and gi are all linear functions. Each of these linear functions may be expressed as a1x1 + a2x2 + ··· + anxn = ´n j=1 aj xj , where aj ∈ ‘, j = 1,...,n, are the coefficients. We may write a = (a1,...,an) and f(x) = aT x. An example: minimize x1 + x2 subject to x1 + 2x2 ≤ 6 2x1 + x2 ≤ 6 x1 ≥ 0, x2 ≥ 0. Teklebirhan A. Aksum University Chapter 1 Integer programming 21 / 124
  • 25. Linear Programs In general, an LP may always be expressed as min n ¼ j=1 cj xj s.t. n ¼ j=1 Aij xj ≤ bi ∀i = 1,...,m. Aij s: constraint coefficients bi s: right-hand-side values (RHS). cj s: objective coefficients. Or by vectors: mincT x s.t. aT i x ≤ bi ∀i = 1,...,m. ai ∈ ‘n, bi ∈ ‘, c ∈ ‘n x ∈ ‘n Or by matrices: min cT x subject to: Ax ≤ b A ∈ ‘m×n, b ∈ ‘m Teklebirhan A. Aksum University Chapter 1 Integer programming 22 / 124
  • 26. Standard Form of LP Standard Form: Maximize cT x Subject to Ax ≤ b x ≥ 0 where: x is the vector of decision variables. c is the vector of coefficients of the objective function. A is the matrix of coefficients of the constraints. b is the vector of right-hand side constants of the constraints. Teklebirhan A. Aksum University Chapter 1 Integer programming 23 / 124
  • 27. Solution Techniques Graphical Method It is applicable only for LP problems with two decision variables. Steps: 1 Graph the Constraints: Convert each inequality constraint into an equation (replace ≤ with =). Plot the equations on a graph. Use the axes for x1 and x2. Identify the feasible region by testing a point (often the origin) in the inequalities. The resulting area where all inequalities overlap is the feasible region. 2 Determine the Corners of the Feasible Region: Identify the vertices (corner points) of the feasible region. These vertices are typically where the constraint lines intersect. 3 Calculate the objective function value at each corner point of the feasible region. 4 Identify the Optimal Solution: If the LPP is maximization, take the highest value. If the LPP is minimization, take the lowest value. Teklebirhan A. Aksum University Chapter 1 Integer programming 24 / 124
  • 28. Graphical approach For LPs with only two decision variables, we may solve them with the graphical approach. Consider the following example: maximize 2x1 + x2 subject to x1 ≤ 10 x1 + 2x2 ≤ 12 x1 − 2x2 ≥ −8 x1 ≥ 0 x2 ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 25 / 124
  • 29. Graphical Approach Step 1: Draw the Feasible Region Draw each constraint one by one, and then find the intersection. max 2x1 + x2 s.t. x1 ≤ 10 x1 + 2x2 ≤ 12 x1 − 2x2 ≥ −8 x1 ≥ 0 x2 ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 26 / 124
  • 30. Graphical Approach Step 2: Draw Some Isoquant Lines. A line such that all points on it result in the same objective value. Also called isoprofit or isocost lines when it is appropriate. Also called indifference lines (curves) in Economics. max 2x1 + x2 s.t. x1 ≤ 10 x1 + 2x2 ≤ 12 x1 − 2x2 ≥ −8 x1 ≥ 0 x2 ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 27 / 124
  • 31. Graphical Approach Step 3: Indicate the direction to push the isoquant line. The direction that decreases/increases the objective value for a minimization/maximization problem. max 2x1 + x2 s.t. x1 ≤ 10 x1 + 2x2 ≤ 12 x1 − 2x2 ≥ −8 x1 ≥ 0 x2 ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 28 / 124
  • 32. Step 4: Push the isoquant line to the "end" of the feasible region. Stop when any further step makes all points on the isoquant line infeasible. Teklebirhan A. Aksum University Chapter 1 Integer programming 29 / 124
  • 33. Step 5: Identify the binding constraints at an optimal solution. Teklebirhan A. Aksum University Chapter 1 Integer programming 30 / 124
  • 34. Graphical Approach Step 6: Set the binding constraints to equalities and then solve the linear system for an optimal solution. In the example, the binding constraints are: x1 ≤ 10 and x1 + 2x2 ≤ 12 We may solve the linear system: x1 = 10 x1 + 2x2 = 12 in any way and obtain an optimal solution (x∗ 1,x∗ 2) = (10,1). For example, through Gaussian elimination: 1 0 10 1 2 12 ! → 1 0 10 0 2 2 ! → 1 0 10 0 1 1 ! Step 7: Plug in an optimal solution obtained into the objective function to get the associated objective value. In the example, 2x∗ 1 + x∗ 2 = 21. Teklebirhan A. Aksum University Chapter 1 Integer programming 31 / 124
  • 35. Teklebirhan A. Aksum University Chapter 1 Integer programming 32 / 124
  • 36. Three types of LPs For any LPs, it must be one of the following: Infeasible. Unbounded. Finitely optimal (having an optimal solution). A finitely optimal LP may have: A unique optimal solution. Multiple optimal solutions. Teklebirhan A. Aksum University Chapter 1 Integer programming 33 / 124
  • 37. Teklebirhan A. Aksum University Chapter 1 Integer programming 34 / 124
  • 38. Teklebirhan A. Aksum University Chapter 1 Integer programming 35 / 124
  • 39. Teklebirhan A. Aksum University Chapter 1 Integer programming 36 / 124
  • 40. Teklebirhan A. Aksum University Chapter 1 Integer programming 37 / 124
  • 41. Linear Programming Problem Example Solve the Linear programming problem Maximize: Z = 4x1 + 7x2 Subject to: 2x1 + 5x2 ≤ 40 x1 + x2 ≤ 11 x2 ≥ 4 x1,x2 ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 38 / 124
  • 42. Teklebirhan A. Aksum University Chapter 1 Integer programming 39 / 124
  • 43. Summary Teklebirhan A. Aksum University Chapter 1 Integer programming 40 / 124
  • 44. Simple LP Formulations: Introduction It is important to learn how to model a practical situation as an LP. Once you do so, you have "solved" the problem. This process is typically called LP formulation or modeling. Here we will see some examples of LP formulation. Then we formulate large-scale problems with compact formulations. Example A product mix problem We produce several products to sell. Each product requires some resources. Resources are limited. We want to maximize the total sales revenue with available resources. Teklebirhan A. Aksum University Chapter 1 Integer programming 41 / 124
  • 45. Description Problem description We produce desks and tables. Producing a desk requires three units of wood, one hour of labor, and 50 minutes of machine time. Producing a table requires five units of wood, two hours of labor, and 20 minutes of machine time. We may sell everything we produce. For each day, we have Two hundred workers that each works for eight hours. Fifty machines that each runs for sixteen hours. A supply of 3600 units of wood. Desks and tables are sold at $700 and $900 per unit, respectively. Teklebirhan A. Aksum University Chapter 1 Integer programming 42 / 124
  • 46. Variables Define Variables What do we need to decide? Let x1 = number of desks produced in a day x2 = number of tables produced in a day With these variables, we now try to express how much we will earn and how many resources we will consume. Formulate the Objective Function We want to maximize the total sales revenue. Given our variables x1 and x2, the sales revenue is 700x1 + 900x2. The objective function is thus: max 700x1 + 900x2. Teklebirhan A. Aksum University Chapter 1 Integer programming 43 / 124
  • 47. Formulate Constraints For each restriction or limitation, we write a constraint: The supply of wood is limited: 3x1 + 5x2 ≤ 3600 The number of labor hours is limited: x1 + 2x2 ≤ 1600 The amount of machine time is limited: 50x1 + 20x2 ≤ 48000 Note: Use the same unit of measurement! Teklebirhan A. Aksum University Chapter 1 Integer programming 44 / 124
  • 48. Complete Formulation Collectively, our formulation is: max 700x1 + 900x2 (Objective Function) s.t. 3x1 + 5x2 ≤ 3600 (wood) x1 + 2x2 ≤ 1600 (labor) 50x1 + 20x2 ≤ 48000 (machine) x1 ≥ 0 x2 ≥ 0 In any case: Clearly define decision variables in front of your formulation. Write comments after the objective function and constraints. Teklebirhan A. Aksum University Chapter 1 Integer programming 45 / 124
  • 49. Solve and Interpret An optimal solution of this LP is (884.21,189.47). So, the interpretation is... to produce 884.21 desks and 189.47 tables? Producing 884.21 desks and 189.47 tables seems weird, but in fact: We may produce 884.21 desks and 189.47 tables per day on average (i.e., roughly 88,420 desks and 18,947 tables per 100 days). We may suggest to produce, e.g., 884 desks and 189 tables. It still supports our decision making. It may not really be optimal, but we spend a very short time to make a good suggestion. "All models are wrong, but some are useful." Teklebirhan A. Aksum University Chapter 1 Integer programming 46 / 124
  • 50. Personnel scheduling Teklebirhan A. Aksum University Chapter 1 Integer programming 47 / 124
  • 51. Personnel scheduling Teklebirhan A. Aksum University Chapter 1 Integer programming 48 / 124
  • 52. Personnel scheduling Teklebirhan A. Aksum University Chapter 1 Integer programming 49 / 124
  • 53. Constraints Demand fulfillment: 110 employees are needed on Monday: x1 + x4 + x5 + x6 + x7 ≥ 110. 80 employees are needed on Tuesday: x1 + x2 + x5 + x6 + x7 ≥ 80. 120 employees are needed on Sunday: x3 + x4 + x5 + x6 + x7 ≥ 120. Nonnegativity constraints: xi ≥ 0 ∀i = 1,...,7. Teklebirhan A. Aksum University Chapter 1 Integer programming 50 / 124
  • 54. Personnel scheduling Teklebirhan A. Aksum University Chapter 1 Integer programming 51 / 124
  • 55. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 52 / 124
  • 56. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 53 / 124
  • 57. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 54 / 124
  • 58. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 55 / 124
  • 59. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 56 / 124
  • 60. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 57 / 124
  • 61. Compact Teklebirhan A. Aksum University Chapter 1 Integer programming 58 / 124
  • 62. Problems vs. instances Teklebirhan A. Aksum University Chapter 1 Integer programming 59 / 124
  • 63. Integer Programming Introduction to integer programming We have worked with LPs. In linear programming problem, the variables are allowed to take any real or fractional value, however in some cases, variables must only take integer values. The subject of formulating and solving models with integer variables is Integer Programming (IP). An IP is typically a linear IP (LIP). If the objective function or any functional constraint is nonlinear, it is a nonlinear IP (NLIP). We will focus on linear IP. Teklebirhan A. Aksum University Chapter 1 Integer programming 60 / 124
  • 64. Personnel Scheduling (Again) We know that United Airlines developed an LP to determine the number of staff in each of their service locations. The same problem is faced by Taco Bell. It has more than 6500 restaurants in the US. It asks how many staff to have at each restaurant in each shift. Taco Bell developed an Integer Program (i.e., an LP with integer variables) to solve its workforce scheduling problem. The number of staff is typically small! Rounding is very inaccurate. $13 million are saved per year. Teklebirhan A. Aksum University Chapter 1 Integer programming 61 / 124
  • 65. Route Selection Waste Management Inc. operates an recycling network with 293 landfill sites, 16 waste-to-energy plants, 72 gas-to-energy facilities, 146 recycling plants, 346 transfer stations, and 435 collection depots. 20,000 routes must be traversed by its vehicles each day. How to determine a route? Construct a network with nodes and edges. Assign a binary variable to each edge: 1 if included, 0 otherwise. Constraints are required to ensure that selected edges form a valid route. A large Integer Programming (IP) model is constructed to save the company $498 million in operational expenses over a 5-year period. Teklebirhan A. Aksum University Chapter 1 Integer programming 62 / 124
  • 66. Integer programming formulation The Knapsack Problem We start our illustration with the classic knapsack problem. There are four items to select: Item 1 2 3 4 Value ($) 16 22 12 8 Weight (kg) 5 7 4 3 The knapsack capacity is 10 kg. We maximize the total value without exceeding the knapsack capacity. The Complete Formulation is max16x1 + 22x2 + 12x3 + 8x4 s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10 xi ∈ {0,1} ∀i = 1,...,4 Teklebirhan A. Aksum University Chapter 1 Integer programming 63 / 124
  • 67. Types of Integer Programming Problems Integer programming problems can be classified into three categories: 1 Pure (all) integer programming problems in which all decision variables are restricted to integer values. 2 Mixed integer programming problems in which some, but not all, of the decision variables are restricted to integer values. 3 Zero-one integer programming problems in which all decision variables are restricted to either zero (0) or one (1). Teklebirhan A. Aksum University Chapter 1 Integer programming 64 / 124
  • 68. Standard form of Pure Integer Programming Problem The pure integer programming problem in its standard form can be written as follows: Maximize Z = c1x1 + c2x2 + ··· + cnxn, subject to Constraints: a11x1 + a12x2 + ··· + a1nxn = b1, a21x1 + a22x2 + ··· + a2nxn = b2, . . . am1x1 + am2x2 + ··· + amnxn = bm, x1,x2,...,xn ≥ 0 and integer. Teklebirhan A. Aksum University Chapter 1 Integer programming 65 / 124
  • 69. Solving IP The branch-and-bound algorithm finds an optimal solution for any IP. It decomposes an IP to multiple LPs, solve all the LPs, and compares those outcomes to reach a conclusion. Each LP is solved separately (with the simplex method or other ways). In general, the process may take a very long time. As finding an optimal solution for an IP may be too time-consuming, we often look for a near-optimal feasible solution instead in practice. An algorithm that generates a feasible solution in a short time is called a heuristic algorithm. Hopefully it is near-optimal. A good heuristic algorithm does not always work, but it works for most of the time. Teklebirhan A. Aksum University Chapter 1 Integer programming 66 / 124
  • 70. Solving Integer Programs Suppose we are given an IP, how may we solve it? The simplex method does not work! The feasible region is not a region. It is discrete. There is no way to move along edges. But all we know is how to solve LPs. How about solving a linear relaxation first? Definition The LP obtained by removing all the integer constraints from the given IP is called Linear Relaxation. Teklebirhan A. Aksum University Chapter 1 Integer programming 67 / 124
  • 71. Linear Relaxation What is the linear relaxation of maxx1 + x2 s.t.x1 + 3x2 ≤ 10 2x1 − x2 ≥ 5 xi ∈ ™+ ∀i = 1,2 where ™ is the set of all integers and ™+ is the set of all non-negative integers. The linear relaxation is max x1 + x2 s.t. x1 + 3x2 ≤ 10 2x1 − x2 ≥ 5 xi ≥ 0 ∀i = 1,2 Teklebirhan A. Aksum University Chapter 1 Integer programming 68 / 124
  • 72. Linear Relaxation For the Knapsack Problem: maximize 16x1 + 22x2 + 12x3 + 8x4 s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10 xi ∈ {0,1} ∀i = 1,...,4 The Linear Relaxation is: maximize 16x1 + 22x2 + 12x3 + 8x4 s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 10 xi ∈ [0,1] ∀i = 1,...,4 Note: xi ∈ [0,1] is equivalent to xi ≥ 0 and xi ≤ 1. Teklebirhan A. Aksum University Chapter 1 Integer programming 69 / 124
  • 73. Linear Relaxation Provides a Bound For a minimization IP, its linear relaxation provides a lower bound. Proposition Let z∗ and z0 be the objective values associated with optimal solutions of a minimization IP and its linear relaxation, respectively. Then, z0 ≤ z∗. Proof Both have the same objective function. The feasible region of the linear relaxation is (weakly) larger than that of the IP. For a maximization IP, linear relaxation provides an upper bound. Teklebirhan A. Aksum University Chapter 1 Integer programming 70 / 124
  • 74. Linear Relaxation and Integer Programming Linear relaxation may solve the Integer Program (IP): If we are lucky, the linear relaxation may be infeasible or unbounded. The IP is then infeasible or unbounded. If we are lucky, an optimal solution to the linear relaxation may be feasible to the original IP. When this happens, the IP is solved. Proposition Let x0 be an optimal solution to the linear relaxation of an IP. If x0 is feasible to the IP, it is optimal to the IP. Proof Suppose x0 is not optimal to the IP; there must be another feasible solution x00 that is better. However, as x00 is feasible to the IP, it is also feasible to the linear relaxation, which implies that x0 cannot be optimal to the linear relaxation. What if we are unlucky? Teklebirhan A. Aksum University Chapter 1 Integer programming 71 / 124
  • 75. Rounding a Fractional Solution Suppose we solve a linear relaxation with an LR-optimal solution x0. "LR-optimal" means x0 is optimal to the linear relaxation. x0, however, has at least one variable violating the integer constraint in the original Integer Program (IP). We may choose to round the variable. Round up or down? Is the resulting solution always feasible? Will the resulting solution be close to an IP-optimal solution x∗? Teklebirhan A. Aksum University Chapter 1 Integer programming 72 / 124
  • 76. Rounding Teklebirhan A. Aksum University Chapter 1 Integer programming 73 / 124
  • 77. Teklebirhan A. Aksum University Chapter 1 Integer programming 74 / 124
  • 78. Teklebirhan A. Aksum University Chapter 1 Integer programming 75 / 124
  • 79. Rounding a Fractional Solution Rounding a fractional solution involves the following steps: When we solve the linear relaxation and find any variable violating an integer constraint, we will branch this problem into two new problems, one with an additional constraint. The two new programs are still linear programs. Once we have solved them: If their LR-optimal solutions are both IP-feasible, compare them and choose the better one. If any of them results in a variable violating the integer constraint, branch on that variable recursively. Eventually compare all the IP-feasible solutions we obtain. Teklebirhan A. Aksum University Chapter 1 Integer programming 76 / 124
  • 80. Illustration of the Branch-and-Bound Algorithm Example Let’s illustrate the branch-and-bound algorithm with the following example: maximize 3x1 + x2 (P0) s.t. 4x1 + 2x2 ≤ 11 x1,x2 ∈ ™+ Teklebirhan A. Aksum University Chapter 1 Integer programming 77 / 124
  • 81. Sub-problem 1 We first solve the linear relaxation: max 3x1 + x2 (P1) Subject to: 4x1 + 2x2 ≤ 11 xi ≥ 0 ∀i = 1,2 The optimal solution is: x1 = 11 4 ,0 So we need to branch on x1. Teklebirhan A. Aksum University Chapter 1 Integer programming 78 / 124
  • 82. Branching tree The branch and bound algorithm produces a branching tree. Each node represents a sub-problem (which is an LP). Each time we branch on a variable, we create two child nodes. Teklebirhan A. Aksum University Chapter 1 Integer programming 79 / 124
  • 83. Sub-problem 2 When we add x1 ≤ 2: max 3x1 + x2 (P2) Subject to: 4x1 + 2x2 ≤ 11 x1 ≤ 2 xi ≥ 0 ∀i = 1,2 An (P2)-optimal solution is x2 = (2, 3 2). So later we need to branch on x2. Before that, let’s solve (P3). Teklebirhan A. Aksum University Chapter 1 Integer programming 80 / 124
  • 84. Sub-problem 3 When we add x1 ≤ 3: max 3x1 + x2 Subject to: (P3) 4x1 + 2x2 ≤ 11 x1 ≥ 3 xi ≥ 0 ∀i = 1,2 The problem is infeasible! This node is dead and does not produce any candidate solution Teklebirhan A. Aksum University Chapter 1 Integer programming 81 / 124
  • 85. Branching tree The current progress can be summarized in the branching tree Note that z2 = 7.5 8.25 = z1. In general, when we branch to the next level, the objective value associated with a sub-problem-optimal solution will always be weakly lower (for a maximization problem). Why? Teklebirhan A. Aksum University Chapter 1 Integer programming 82 / 124
  • 86. Branching tree As x2 = 3 2 in x2, we will branch sub-problem 2 on x2. Teklebirhan A. Aksum University Chapter 1 Integer programming 83 / 124
  • 87. Subproblem-4 Teklebirhan A. Aksum University Chapter 1 Integer programming 84 / 124
  • 88. Subproblem-5 Teklebirhan A. Aksum University Chapter 1 Integer programming 85 / 124
  • 89. Teklebirhan A. Aksum University Chapter 1 Integer programming 86 / 124
  • 90. Teklebirhan A. Aksum University Chapter 1 Integer programming 87 / 124
  • 91. Teklebirhan A. Aksum University Chapter 1 Integer programming 88 / 124
  • 92. Teklebirhan A. Aksum University Chapter 1 Integer programming 89 / 124
  • 93. Teklebirhan A. Aksum University Chapter 1 Integer programming 90 / 124
  • 94. Teklebirhan A. Aksum University Chapter 1 Integer programming 91 / 124
  • 95. Summary In running the branch-and-bound algorithm, we maintain a tree. If a subproblem-optimal solution is IP-feasible, set it to the candidate solution if it is currently the best among all IP-feasible solutions. Stop branching this node. If a subproblem is infeasible, stop branching this node. If a subproblem-optimal solution is not IP-feasible: If it is better than the current candidate solution, branch. Otherwise, stop branching. Teklebirhan A. Aksum University Chapter 1 Integer programming 92 / 124
  • 96. The Knapsack Problem We start our illustration with the classic knapsack problem. There are five items to select: Item 1 2 3 4 5 Value ($) 2 3 4 1 3 Weight (kg) 4 5 3 1 4 The knapsack capacity is 11 kg. We maximize the total value without exceeding the knapsack capacity. The Complete Formulation max 2x1 + 3x2 + 4x3 + x4 + 3x5 s.t. 4x1 + 5x2 + 3x3 + x4 + 4x5 ≤ 11 xi ∈ {0,1} ∀i = 1,...,5 Let’s solve the knapsack problem with the branch-and-bound algorithm. Teklebirhan A. Aksum University Chapter 1 Integer programming 93 / 124
  • 97. Solving the linear relaxation The first step is always to solve the linear relaxation: max 2x1 + 3x2 + 4x3 + x4 + 3x5 s.t. 4x1 + 5x2 + 3x3 + x4 + 4x5 ≤ 11 xi ∈ [0,1] ∀i = 1,...,5. A very intuitive way works: Sort all items in the descending order of vi wi , where vi and wi are the value and weight of item i, respectively. Select items one by one according to the order until the knapsack is full. Note that the last item may be partially selected. The five ratios are 2 4, 3 5, 4 3, 1 1, and 3 4. The order is item 3, item 4, item 5, item 2, and lastly item 1. An optimal solution to the linear relaxation is (0, 3 5 ,1,1,1). Teklebirhan A. Aksum University Chapter 1 Integer programming 94 / 124
  • 98. Subproblems Teklebirhan A. Aksum University Chapter 1 Integer programming 95 / 124
  • 99. Cont... Teklebirhan A. Aksum University Chapter 1 Integer programming 96 / 124
  • 100. Cont... Teklebirhan A. Aksum University Chapter 1 Integer programming 97 / 124
  • 101. Cont... Teklebirhan A. Aksum University Chapter 1 Integer programming 98 / 124
  • 102. Remarks The major process is still branch and bound. The only unique thing is that we have a special way to solve the linear relaxation of the knapsack problem. In other words, we may customize the branch-and-bound algorithm for each specific type of IP. Teklebirhan A. Aksum University Chapter 1 Integer programming 99 / 124
  • 103. Procedure of Branch and Bound Algorithm Step: 1 (Initialization) Consider the following all integer programming problem: Max Z = c1x1 + c2x2+... + cnxn Subject to the constraints: a11x1 + a12x2 + ... + a1nxn = b1 a21x1 + a22x2 + ... + a2nxn = b2 ... am1x1 + am2x2 + ... + amnxn = bm and xj ≥ 0 and non-negative integer. Teklebirhan A. Aksum University Chapter 1 Integer programming 100 / 124
  • 104. Obtain the optimal solution of the given problem ignoring integer restriction on the variables 1 If the solution to this LP problem (say LP-A) is infeasible or unbounded, the solution to the all integer programming problem is also infeasible or unbounded, as the case may be. 2 If the solution satisfies the integer restriction, the optimal integer solution has been obtained. If one or more basic variables do not satisfy the integer requirement, then go to step 2. Let the optimal value of the objective function of LP-A be Z1. This value provides an initial upper bound on the objective function value and it is denoted by ZU . 3 Find the feasible value by rounding off each variable value. The value of the objective function so obtained is the least upper bound and it is denoted by ZL . Teklebirhan A. Aksum University Chapter 1 Integer programming 101 / 124
  • 105. Step 2: Branching Step 1 Let xk be one basic variable which does not have an integer value and also has the largest fractional value. 2 Branch (or partition) the LP-A into two new LP sub-problems (also called nodes) based on integer values of xk that are immediately above and below its non-integer value. That is, it is partitioned by adding two mutually exclusive constraints: xk ≤ ⌊xk ⌋ and xk ≥ ⌊xk ⌋ + 1 to the original LP problem. 3 Here ⌊xk ⌋ is the integer portion of the current non-integer value of the variable xk . This is obviously done to exclude the non-integer value of the variable xk . The two new LP sub-problems are as follows: Teklebirhan A. Aksum University Chapter 1 Integer programming 102 / 124
  • 106. LP Sub-problem B Max Z = n ¼ j=1 cj xj subject to n ¼ j=1 aij xj = bi xk ≤ ⌊xk ⌋ and xj ≥ 0 LP Sub-problem C Max Z = n ¼ j=1 cj xj subject to n ¼ j=1 aij xj = bi xk ≥ ⌊xk ⌋ + 1 and xj ≥ 0 Teklebirhan A. Aksum University Chapter 1 Integer programming 103 / 124
  • 107. Step 3: Bound Step Obtain the optimal solution of LP Subproblem B. Let the optimal value of the objective function of LP-B be Z2. Obtain the optimal solution of LP Subproblem C. Let the optimal value of the objective function of LP-C be Z3. The best integer solution value becomes the lower bound on the integer LP problem objective function value (initially this is the rounded off value). Let the lower bound be denoted by ZL . Teklebirhan A. Aksum University Chapter 1 Integer programming 104 / 124
  • 108. Step 04: (Fathoming Step) Examining the solution of both LP-B and LP-C: 1 If the sub-problem yields an infeasible solution, then terminate the branch. 2 If the sub-problems yield a feasible solution, but not an integer solution, then go to Step 02. 3 If the sub-problem yields an integer feasible solution, then examine the value of the objective function. If the value is equal to the upper bound, then the optimal solution has been obtained. If it is not equal to the upper bound but exceeds the lower bound, then this value is considered as the new upper bound and return to step 2. Finally, If it is less than the lower bound terminate the branch. Teklebirhan A. Aksum University Chapter 1 Integer programming 105 / 124
  • 109. Step 05 (Termination) Procedure of branching and bounded continues, until no sub problem remains to be examined. At this stage, the integer solution corresponding to the current lower bound is optimal all integer programming problem. Teklebirhan A. Aksum University Chapter 1 Integer programming 106 / 124
  • 110. Branch and bound method example Example Solve the following integer programming problem using branch and bound method: Maximize Z = 2x1 + 3x2 Subject to 6x1 + 5x2 ≤ 25, x1 + 3x2 ≤ 10, x1,x2 ≥ 0, x1,x2 are integers. Teklebirhan A. Aksum University Chapter 1 Integer programming 107 / 124
  • 111. Solution: Step 01 Relaxing the integer condition, Let us find the optimal solution to the given LP problem by graphical method. Graphical Method Let us draw the line 6x1 + 4x2 = 25 Let x1 = 0, 6(0) + 4x2 = 25 =⇒ x2 = 25/4 i.e. (0,5) Let x2 = 0, 6x1 + 4(0) = 25 =⇒ x1 = 25/6 i.e. (4.16,0) Let us draw the line x1 + 3x2 = 10 Let x1 = 0, 0 + 3x2 = 10 =⇒ x2 = 10/3 i.e. (0,3.33) Let x2 = 0, x1 + 3(0) = 10 =⇒ x1 = 10 i.e. (10,0) Teklebirhan A. Aksum University Chapter 1 Integer programming 108 / 124
  • 112. Step 1 Cont. To find the intersection point: (1) ⇒ 6x1 + 5x2 = 25 (2) ⇒ 6x1 + 18x2 = 60 Subtracting the two equations: −13x2 = −35 =⇒ x2 = 35 13 Substitute x2 value in equation (1) to get x1 = 35 13 i.e. the intersection point is (1.92,2.69) At (4.16,0), Max Z = 2(4.16) + 3(0) = 8.32 At (0,3.33), Max Z = 2(0) + 3(3.33) = 9.99 At (1.92,2.69), Max Z = 2(1.92) + 3(2.69) = 11.91 Teklebirhan A. Aksum University Chapter 1 Integer programming 109 / 124
  • 113. Teklebirhan A. Aksum University Chapter 1 Integer programming 110 / 124
  • 114. Cont. The optimum solution is x1 = 1.92, x2 = 2.69 and Max Z1 = 11.91. Let ZU = 11.91 be the initial upper bound. The feasible solution by rounding off the solution gives the initial lower bound ZL = 11 (rounding off x1 = 1, x2 = 3). The optimal solution lies between these two bounds. Teklebirhan A. Aksum University Chapter 1 Integer programming 111 / 124
  • 115. Step 02 (Branching step) Here both x1 and x2 are not integers, therefore we can select the variable for branching with the highest fractional value, here x2 has a higher fractional value compared to x1. Solving the variable x2 for branching, divide the given problem into two subproblems A and B to eliminate the fractional part of x2 = 2.69. The new constraints to be added are x2 ≤ 2 and x2 ≥ 3. Teklebirhan A. Aksum University Chapter 1 Integer programming 112 / 124
  • 116. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 113 / 124
  • 117. Cont’d The corresponding graph is given by Teklebirhan A. Aksum University Chapter 1 Integer programming 114 / 124
  • 118. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 115 / 124
  • 119. Step 03 (Bound step) Rule: The best integer solution gives the lower bound. Here the best integer solution is x1 = 1, x2 = 3 and Max Z3 = 11. The value ZL = 11 is the lower bound for the given LP problem. Step 04 (Fathoming step) Both the sub-problems B and C give the same Z value. In the sub-problem C, both the variables x1 and x2 are integers, so there is no need to branch the sub-problem C further. Since ZL ≤ Z3 ZU (11 ≤ 11 11.91), therefore the new upper bound is ZU = 11. In the sub-problem B, x1 is not an integer and since ZL ≤ Z2 (11 ≤ 11), therefore the sub-problem B can be branched further. Teklebirhan A. Aksum University Chapter 1 Integer programming 116 / 124
  • 120. Stet 05 (Branch step) Let us divide the sub problem B into two sub problems, D and E, by taking variable x1 = 2.5. The new constraints to be added are x1 ≤ 2 and x1 ≥ 3. Teklebirhan A. Aksum University Chapter 1 Integer programming 117 / 124
  • 121. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 118 / 124
  • 122. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 119 / 124
  • 123. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 120 / 124
  • 124. Cont’d Rule: The best integer solution gives the lower bound. Here the best integer solution is x1 = 2, x2 = 2, and MaxZ4 = 10. The solution to the LP sub problem D is integer feasible, but Z4 ZL (10 11), and since the value of the lower bound remains unchanged (ZL = 11), therefore the sub problem D is not considered for further branching. Teklebirhan A. Aksum University Chapter 1 Integer programming 121 / 124
  • 125. Cont’d Since the solution of sub problem E is non-integer (x2 is not an integer), it can be further branched with variable x2, but Z5 ZL (10.2 11). Therefore, sub problem E is not considered for further branching. Thus, the integer solution corresponding to the current lower bound is the optimal solution. Hence the integer optimal solution is corresponding to sub problem C and is given by x1 = 1, x2 = 3, and MaxZ = 11. The entire branch and bound procedure can be represented by the following enumeration tree. Each node is a sub problem. Teklebirhan A. Aksum University Chapter 1 Integer programming 122 / 124
  • 126. Cont’d Teklebirhan A. Aksum University Chapter 1 Integer programming 123 / 124
  • 127. Note If both sub-problems give non-integer solutions, then the sub-problem with the maximum objective value should be further branched. If one of the sub-problems has no feasible solution and the other has a feasible solution, but it is not integer, and any other sub-problem is the same. kind exist, always select the sub problem which has maximum objective function value for further branching. Teklebirhan A. Aksum University Chapter 1 Integer programming 124 / 124