Chapter 6: Test Practice Problems

Total Page:16

File Type:pdf, Size:1020Kb

Chapter 6: Test Practice Problems

Chapter 6: Test Practice Problems

1. The number of Hamilton circuits in is 2. The number of edges in is

A) 15! A) 210 B) 105 B) 15 C) 14! C) 14! D) 15 D) 105 E) None of these E) None of these

Questions 3 to 6 refer to the following situation: A delivery truck must deliver furniture to 4 different locations (A, B, C, and D). The trip must start and end at A. The graph below shows the distances between locations (in miles). We want to minimize the total distance traveled.

3. The nearest neighbor algorithm applied to the graph from vertex A yields the following solution:

A) A, B, D, C, A B) A, D, B, C, A C) A, C, B, D, A. D) A, D, C, B, A E) None of these

4. The cheapest link algorithm applied to the graph yields the following solution:

A) A, B, D, C, A B) A, D, B, C, A C) A, C, B, D, A. D) A, D, C, B, A E) None of these

5. The repetitive nearest neighbor algorithm applied to the graph yields the following solution:

A) A, B, D, C, A B) A, D, B, C, A C) A, C, B, D, A. D) A, D, C, B, A E) None of these

6. An optimal solution to this problem is given by

A) A, B, D, C, A B) A, B, C, D, A C) A, C, D, B, A. D) A, D, C, B, A E) None of these

A B C D E A ** 446 963 735 941 B 446 ** 522 326 532 C 963 522 ** 308 292 D 735 326 308 ** 209 E 941 532 292 209 ** Questions 7 to 9 refer to the following situation: A traveling salesman’s territory consists of the 5 cities shown on the following mileage chart. The salesman must organize a round trip that starts and ends at city E (his hometown) and will pass through each of the other four cities exactly once

7. The nearest neighbor algorithm applied to this problem from city E yields the following solution:

A) E, D, C, B, A, E B) E, A, C, B, D, E C) E, C, B, A, D, E D) E, D, B, A, C, E E) None of these

8. The cheapest link algorithm applied to this problem yields the following solution

A) E, D, C, B, A, E B) E, A, B, C, D, E C) E, C, B, A, D, E D) E, D, B, A, C, E E) None of these

9. The repetitive nearest neighbor algorithm applied to this problem yields the following solution

A) E, D, C, B,A, E B) E, A, B, C, D, E C) E, C, B, A, D, E D) E, D, B, A, C, E E) None of these

10. Circle the correct words: The repetitive nearest neighbor algorithm for solving the Traveling Salesman Problem is

( Approximate or Optimal ) and ( Efficient or Inefficient )

11. Circle the correct words: The nearest neighbor algorithm for solving the Traveling Salesman Problem is

( Approximate or Optimal ) and ( Efficient or Inefficient )

12. Circle the correct words: The brute force algorithm for solving the Traveling Salesman Problem is

( Approximate or Optimal ) and ( Efficient or Inefficient )

13. Circle the correct words: The cheapest link algorithm for solving the Traveling Salesman Problem is

( Approximate or Optimal ) and ( Efficient or Inefficient )

14. The number of edges in K10 is

A) 10! B) 90 C) 10 D) 45 E) None of these

15. In a complete graph with 14 vertices (A through N), the total number of Hamilton circuits (including mirror-image circuits) that start at vertex A is

A) 14! B)13! C)15! D)91 E) None of these

16. In a complete graph with 6 vertices, the total number of Hamilton circuits, not including mirror image circuits is: (do not count the same circuit traveled backwards)

A) 15 B) 120 C) 60 D) 30 E) None of these

Questions 17 through 22 refer to the following situation. A delivery truck must deliver furniture to 4 different locations (A,B,C, and D). The trip must start and end at A. The graph in Figure 6.1 shows the distances between locations (in miles). We want to minimize the total distance traveled.

17 The nearest neighbor algorithm applied to the graph from vertex A yields the following solution

A) A, D, B, C, A B) A, D, C, B, A C) A, C, B, D, A. D) A, B, D, C, A E) None of these

18. The cheapest link algorithm applied to the graph yields the following solution

A) A, D, B, C, A B) A, D, C, B, A C) A, C, B, D, A. D) A, B, D, C, A E) None of these

19. The repetitive nearest neighbor algorithm applied to the graph yields the following solution:

A) A, D, B, C, A B) A, D, C, B, A C) A, B, C, D, A. D) A, B, D, C, A E) None of these

20. How many different Hamilton circuits would we have to check if we use the brute force algorithm? (Do not count the same circuit traveled backward.)

A) 3 B) 6 C) 24 D) 4 E) None of these

21. An optimal solution to this problem is given by 22. What is the length of the optimal route? A) A, D, B, C, A A) 22 miles B) A, D, C, B, A B) 29 miles C) A, C, D, B, A. C) 23 miles D) A, B, D, C, A D) 24 miles E) None of these E) None of these Chicago Des Moines Fargo Minneapolis Indianapolis Chicago * 333 643 409 94 Des Moines 333 * 477 244 375 Fargo 643 477 * 235 571 Minneapolis 409 244 235 * 337 Indianapolis 94 375 571 337 * Questions 23 through 26 refer to the following situation: A traveling salesman’s territory consists of the 5 cities shown on the following mileage chart. The salesman must organize a round trip that starts and ends at Minneapolis (his hometown) and will pass through each of the other four cities exactly once.

23. The nearest neighbor algorithm applied to this problem from Minneapolis yields the following solution

A) Minneapolis, Indianapolis, Chicago, Fargo, Des Moines, Minneapolis B) Minneapolis, Chicago, Indianapolis, Des Moines, Fargo, Minneapolis C) Minneapolis, Des Moines, Chicago, Indianapolis, Fargo, Minneapolis. D) Minneapolis, Indianapolis, Chicago, Des Moines, Fargo, Minneapolis. E) None of these

24. The cheapest link algorithm applied to this problem yields the following solution

A) Minneapolis, Indianapolis, Chicago, Fargo, Des Moines, Minneapolis B) Minneapolis, Chicago, Indianapolis, Des Moines, Fargo, Minneapolis C) Minneapolis, Des Moines, Chicago, Indianapolis, Fargo, Minneapolis. D) Minneapolis, Indianapolis, Chicago, Des Moines, Fargo, Minneapolis. E) None of these

25. The repetitive nearest neighbor algorithm applied to this problem yields the following solution

A) Minneapolis, Indianapolis, Chicago, Fargo, Des Moines, Minneapolis B) Minneapolis, Chicago, Indianapolis, Des Moines, Fargo, Minneapolis C) Minneapolis, Des Moines, Chicago, Indianapolis, Fargo, Minneapolis. D) Minneapolis, Indianapolis, Chicago, Des Moines, Fargo, Minneapolis. E) None of these

26. At an average cost of 50 cents per mile, the cheapest possible trip (out of those found from #23 – 25 above) that starts at Minneapolis and passes through each of the other cities exactly once would cost

A) $738.00 B) $737.00 C)$738.50 D)$739.00 E) None of these

27. Given an optimal value of 200 miles, what is the relative error of a Hamilton circuit of 245 miles, rounded to the nearest whole percent?

A) 23% B) 18% C) 82% D) 123% E) None of these

28. Given an optimal value of $63, what is the relative error of a Hamilton circuit with a value of $70, rounded to the nearest whole percent?

A) 10% B) 90% C) 11% D) 111%

To be successful on the Chapter 6 Test you need to be able to do/know the following:

For any graph:  Know what a Hamilton Circuit is and find one if it exists

 Know what a Hamilton Path is and find one if it exists

For a complete graph KN  Determine the number of possible Hamilton Circuits (including and not including mirror images)

 Determine the number of edges in the graph

 Apply the following algorithms successfully and accurately . Brute Force . Nearest Neighbor . Repetitive Nearest Neighbor . Cheapest Link

 Understand that the only way to find an optimal solution is by checking every possibility (Brute Force)

 Determine the Relative error of a TSP (Traveling Salesman Problem)

 Recognize the difference and know which algorithms are OPTIMAL or APPROXIMATE

 Recognize the difference and know which algorithms are EFFICIENT of INEFFICIENT

SOLUTIONS TO REVIEW

1. C 2. D 3. D 4. A 5. A 6. E 7. A 8. D 9. C 10. Approximate/Efficient 11. Approximate/Efficient 12. Optimal/Inefficient 13. Approximate/Efficient 14. D 15. B 16 C 17. D 18. D 19. A 20. A 21. A 22. E 23. D 24. C 25. D 26. A 27. A 28. C

Recommended publications