You, Alice and Bob manage "Robo-Pizzeria" a company that uses drones to deliver pizza. Here are some important features of your business model: • Drones can fly directly to a location so the time it takes to travel to a location is proportional to the distance between the two locations. • Delivery locations are given as points in a 2-dimensional plane. The Robo-Pizzeria is located at the origin (0,0). The first problem you are trying to solve is planning the route for your drone to follow while delivering pizzas to n locations. The route must leave from the Robo-Pizzeria, visit all locations, and return while travelling the minimum total distance. a) Show how you can turn these 4 delivery locations into a complete weighted graph with 5 nodes (including the Robo-Pizzeria at the origin) by stating the adjacency matrix for the graph. {(1, 1), (-2,-1), (2, 1), (-3,5)} (Since the graph is undirected you only need to state the upper triangle of the matrix.) b) Now describe the procedure you followed so that you could convert an arbitrary set of n delivery points (and the origin) into a complete weighted graph G = {V, E) with n + 1 nodes. c) Formalize the problem of finding the minimum cost route for your drone as a graph problem with input and output criteria. d) Bob has begun carrying out a brute force algorithm trying all possible paths from the Robo-Pizzeria and back again for the example graph. Help him by listing all 24 possible routes and the cost of each route. (Hint: I used a spreadsheet to help with this step.) e) Alice notices that this problem is very similar to the well known Travelling Salesper- son Problem. This problem has no known solutions that take a reasonable amount of time. However, it does have some efficient approximation algorithms. Alice has found one that works as follows: • First, compute a minimum spanning tree of the input graph. • Visit nodes in order of the depth-first traversal of the tree (starting at any node). Perform this algorithm on your input graph (show your work). What order should you visit the locations and what is the total distance travelled by the drone? Did your algorithm find an optimal path?
You, Alice and Bob manage "Robo-Pizzeria" a company that uses drones to deliver pizza. Here are some important features of your business model: • Drones can fly directly to a location so the time it takes to travel to a location is proportional to the distance between the two locations. • Delivery locations are given as points in a 2-dimensional plane. The Robo-Pizzeria is located at the origin (0,0). The first problem you are trying to solve is planning the route for your drone to follow while delivering pizzas to n locations. The route must leave from the Robo-Pizzeria, visit all locations, and return while travelling the minimum total distance. a) Show how you can turn these 4 delivery locations into a complete weighted graph with 5 nodes (including the Robo-Pizzeria at the origin) by stating the adjacency matrix for the graph. {(1, 1), (-2,-1), (2, 1), (-3,5)} (Since the graph is undirected you only need to state the upper triangle of the matrix.) b) Now describe the procedure you followed so that you could convert an arbitrary set of n delivery points (and the origin) into a complete weighted graph G = {V, E) with n + 1 nodes. c) Formalize the problem of finding the minimum cost route for your drone as a graph problem with input and output criteria. d) Bob has begun carrying out a brute force algorithm trying all possible paths from the Robo-Pizzeria and back again for the example graph. Help him by listing all 24 possible routes and the cost of each route. (Hint: I used a spreadsheet to help with this step.) e) Alice notices that this problem is very similar to the well known Travelling Salesper- son Problem. This problem has no known solutions that take a reasonable amount of time. However, it does have some efficient approximation algorithms. Alice has found one that works as follows: • First, compute a minimum spanning tree of the input graph. • Visit nodes in order of the depth-first traversal of the tree (starting at any node). Perform this algorithm on your input graph (show your work). What order should you visit the locations and what is the total distance travelled by the drone? Did your algorithm find an optimal path?
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
100%
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 6 steps with 3 images