1 / 10

Solving Special Cases Challenges Optimal Solutions

Explore extreme limits, manipulate problem space, and analyze special cases to refine solutions. Apply heuristics in problem-solving approaches for intricate scenarios. Example problems and techniques included.

mclaughlina
Download Presentation

Solving Special Cases Challenges Optimal Solutions

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Problem A man leaves his camp by traveling due north for 1 mile. He then makes a right turn (90 degrees) and travels due east for 1 mile. He makes another right turn and travels dues south for 1 mile and finds himself precisely at the point he departed from, that is, back at his campsite. Where is the campsite located? This is searching the space of the solutions for special cases. What are the special cases worth considering?

  2. Go to Extremes • Manipulate the problem space • Look at extreme limits of the problem space.

  3. The “analyze extreme cases” heuristic is often useful in testing of solutions/algorithms. • Example problem: find the illumination I (amount of energy ) that light brings into the room. Here Q is the angle that the blades of the blinds make with the window plane. Choices: cos^2(theta), sin^2(theta), cos(2theta)sin(theta). Q Light

  4. Eliminate wrong choices.

  5. Example Problem Two flagpoles are standing, each 100 feet tall. A 150-foot rope is strung from the top of one of the flagpoles to the top of the other and hangs freely between them. The lowest point of the rope is 25 feet above the ground. How far apart are the two flagpoles? Hint: Start by drawing pictures.

  6. The two extreme cases are:

  7. Another example • What is the length of k? • Important fact: k remains the same no matter what rectangle is inscribed. k r = 1 inch

  8. Another Example You have a large, solid sphere of gold. A cylinder of space is “bored” (drilled) through this sphere, producing a ring. The length of that cylindrical line is 6 inches. You want to know how much gold you have left in the ring. Specifically, what is the volume of the ring? Fact: the amount of gold in the ring does not depend on the width of the bored cylinder. Note: For any sphere, V = pD3/6.

  9. Find the Diagonal • You are given A, B, C. Calculate X. • What is the simpler problem? • How does it relate? x C A B

  10. Real Interview Questions http://www.sellsbrothers.com/fun/msiview/default.aspx?content=question.htm Thanks to Val Komarov for pointing it out to me.

More Related