Relaxed problems - PowerPoint PPT Presentation

1 / 8
About This Presentation
Title:

Relaxed problems

Description:

Relaxed problems. COMP3170. Supplement. Shortest Path Problem. 122 km ... Find the sequence of cities from A to F with a shortest path. Shortest Path Problem ... – PowerPoint PPT presentation

Number of Views:41
Avg rating:3.0/5.0
Slides: 9
Provided by: pin8
Category:

less

Transcript and Presenter's Notes

Title: Relaxed problems


1
Relaxed problems
  • COMP3170
  • Supplement

2
Shortest Path Problem
136 km
D
B
113 km
129 km
96 km
F
102 km
122 km
C
78 km
E
137 km
97 km
A
218 km
Find the sequence of cities from A to F with a
shortest path
3
Shortest Path Problem
Relaxed problem we can drive straight line
from one city to another (pass through all
mountains!) Solution of relaxed problem Sum
of straight line distance Admissible heuristic
straight line distance (SLD) This is the
heuristics used in textbook
4
Traveling Salesman Problem
275 (flight)
350 (flight)
150
D
B
120
120
90
F
100
120
C
100
E
140
80
A
250
Find the sequence of cities to visit if a
salesman in A wants to visit all cities once only
before go back to A with a minimal traveling cost
5
Traveling Salesman Problem
Relaxed problem we dont need to pay from one
city to another (I got a free ride!) Solution
of relaxed problem Number of city I want to
visit Admissible heuristic number of city the
salesman has not visited
6
Traveling Salesman Problem
Another relaxed problem we only need to pay
once for traveling from one city to another (I
got a free ride when I travel back!) Solution
of relaxed problem The total cost in a Minimum
Spanning Tree (MST) generated from the
graph Admissible heuristic Minimum Spanning
Tree of unvisited cities
7
Tower of Hanoi
  • given three pegs and a stack of n disks of
    distinct sizes on an initial peg with larger disk
    on the bottom of a smaller one
  • Rule move the disks one at a time from one peg
    to another, but never stacking a larger disk on
    top of a smaller one
  • Goal all disks are filled in a goal peg with
    minimal moves (optimal solution 2n 1 moves)

goal
initial
8
Tower of Hanoi
  • Relaxed problem
  • move the disks one at a time from one peg to
    another, but not by stacking them on top of
    others. Instead, we can insert them (magically)
    into the correct position.
  • Solution of relaxed problem n moves (total
    number of misplaced disks)
  • Admissible heuristics number of misplaced disks

goal
initial
Write a Comment
User Comments (0)
About PowerShow.com