Download as pdf or txt
Download as pdf or txt
You are on page 1of 29

Network Optimization Models

Networks
2 13
Network is a collection of nodes
5 (vertices) & arcs (edges).
6 5

1 8 7 Nodes represented as 1,2,3, etc.


6 Arcs represented as 1-2, 1-3, etc.
3

7 1 Characteristics…
16 6
1) Direction (with or without)
2) Weight
4 • Cost (unit cost of travel)
• Time
Useful in representing various systems, such • Distance
as distribution systems, production
systems, and transportation systems.

Network models are an important approach for problem solving because:


• They can be used to model a wide range of problems.
• They are relatively simple to work with.
• They provide a visual portrayal of a problem. 2
Network Example
Transportation
network • This kind of network
is called bipartite
graph (or bigraph),
a graph whose vertices
can be divided into
two disjoint sets
• There is no
connection among
sources or among
destinations

In mathematics, networks are often referred to as graphs, and the area of


mathematics concerning the study of graphs is called graph theory.
Here, we'll use the terms network and graph interchangeably.
3
Frequently Used Algorithms
Shortest-Route Algorithm
Used for determining the shortest time,
distance, or cost from an origin to a
destination through a network.

Minimum Spanning Tree Algorithm


Used in determining the minimum
distance (cost, time) needed to connect a
set of locations into a single system.

Maximal Flow Algorithm


Used for determining the greatest
amount of flow that can be transmitted
through a system in which various
branches, or connections, have specified
flow capacity limitations. 4
7-4
Shortest-Route Problem
Dijkstra's Algorithm
Shortest Path First (SPF) algorithm

The shortest-route problem is concerned with finding the


shortest path in a network from one node (or set of nodes)
to another node (or set of nodes).

5
7-5
Applications

6
The Shortest Route Problem
Definition and Example Problem Data (1 of 2)
Problem: Determine the shortest routes (shortest travel time) from the origin to all
destinations.

5
4 6

2
3

1
The Shortest Route Problem
Definition and Example Problem Data (2 of 2)

Network Representation
The Shortest Route Problem
Solution Approach (1 of 8)
Select origin. Put the origin in permanent set. Determine all nodes directly connected
to the permanent set. Determine the initial shortest route from the origin (node
1) to the closest node. Mark the node with the shortest time from origin. Mark
the branch as well.

Network with Node 1 in the Permanent Set


The Shortest Route Problem
Solution Approach (2 of 8)
Put the newly marked node in the permanent set (node 3). Determine all nodes directly
connected to the permanent set. Determine the shortest route from the origin (node 1) to
the closest node. Mark the node with the shortest time from origin. Mark the branch as
well.

Network with Nodes 1 and 3 in the Permanent Set


The Shortest Route Problem
Solution Approach (3 of 8)
Repeat the previous step.

Network with Nodes 1, 2, and 3 in the Permanent Set


The Shortest Route Problem
Solution Approach (4 of 8)

Network with Nodes 1, 2, 3, and 4 in the Permanent Set


The Shortest Route Problem
Solution Approach (5 of 8)

Network with Nodes 1, 2, 3, 4, & 6 in the Permanent Set


The Shortest Route Problem
Solution Approach (6 of 8)

Network with Nodes 1, 2, 3, 4, 5 & 6 in the Permanent Set


The Shortest Route Problem
Solution Approach (7 of 8)

Network with Optimal Routes


The Shortest Route Problem
Solution Approach (8 of 8)

From Node 1: Route Total Hours


Node 2 1-2 16
Node 3 1-3 9
Node 4 1-3-4 24
Node 5 1-3-4-5 38
Node 6 1-3-6 31
Node 7 1-3-4-7 43

Shortest Travel Time from Origin to Each Destination


The Shortest Route Problem
Solution Method Summary
1. Select the node with the shortest direct route from the
origin.
2. Establish a permanent set with the origin node and the
node that was selected in step 1.
3. Determine all nodes directly connected to the permanent
set of nodes.
4. Select the node with the shortest route from the group of
nodes directly connected to the permanent set of nodes.
5. Repeat steps 3 & 4 until all nodes have joined the
permanent set.
Minimal Spanning Tree Problem
Prim’s Minimum Spanning Tree (MST) Algorithm
or
Greedy Algorithm

Seeks to determine the minimum sum of arc weights necessary


to connect all nodes in a network.

18
What is a Spanning Tree ?
Consider the following
Graph G 4 vertices Spanning Tree
4 edges
Connected n vertices
5
2 Edges are having some weight n-1 edges
6 Form a cycle
1 2
A graph can have… 5
3 6
n vertices
7 >=n edges 1
1
4 Connected & form a cycle 3
7
2 4 Sum of arc
Consider a subgraph G’ of G 5 lengths = 18

2 1
5
2
5
7
1
3 4 1
3
Tree Tree 7
<=n vertices <=n vertices 1
4 Sum of arc
<= n-1 edges <= n-1 edges
lengths = 13
Not connected Connected
19
Does not form cycle Does not form cycle
Minimal Spanning Tree Problem
• A tree is a subnetwork of a network that does not form a
cycle.

• A spanning tree is a tree that connects all nodes of a


network.

• The minimal spanning tree problem seeks to determine the


minimum sum of arc lengths necessary to connect all nodes
in a network.

• The criterion to be minimized in the minimal spanning tree


problem is not limited to distance but also can have criteria
such as time and cost.
20
Application
Network design.
– telephone, electrical, hydraulic, TV cable, computer, road
The standard application is to a problem like phone network design.
You have a business with several offices; you want to lease phone lines
to connect them up with each other; and the phone company charges
different amounts of money to connect different pairs of cities. You
want a set of lines that connects all your offices with a minimum total
cost. It should be a spanning tree.

21
Network for Oil Pipeline Problem

22
Arbitrarily begin at any node and connect it to the closest node (shortest distance).
The two nodes are referred to as connected nodes, and the remaining nodes are
referred to as unconnected nodes.

23
Identify the unconnected node that is closest to one of the connected nodes (break ties
arbitrarily). Add this new node to the set of connected nodes. Repeat this step until all nodes
have been connected.

24
Repeat previous step until all nodes have been connected.

25
The length of pipe that will be needed for this system can be found by summing
the arc lengths:

18+13+22+18+24+32 = 127 meters 26


Minimal Spanning Tree Algorithm
• Step 1: Arbitrarily begin at any node and connect it to the
closest node. The two nodes are referred to as connected
nodes, and the remaining nodes are referred to as
unconnected nodes.

• Step 2: Identify the unconnected node that is closest to one


of the connected nodes (break ties arbitrarily). Add this new
node to the set of connected nodes. Repeat this step until all
nodes have been connected.

• Note: A problem with n nodes to be connected will require


n - 1 iterations of the above steps.
27
Exercise

Arcs:
0-1, 0-7, 2-8, 7-6, 2-5, 6-5, 2-3, 3-4
MST length=
4+8+4+2+1+7+2+9
= 37

Another solution:
Arcs
0-1, 1-2, 2-8, 7-6, 2-5, 6-5, 2-3, 3-4
Backup

You might also like