Lecture topic-BruteForce

# Design and analysis of algorithms chapter 3 43 convex

This preview shows page 1. Sign up to view the full content.

This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: he plane into two half-planes: Such for all the points in one of them: ax + by > c, while for all the points in the other, ax + by < c. Design and Analysis of Algorithms – Chapter 3 43 Convex hull brute force algorithm a Algorithm: For each pair of points p1 and p2 For determine whether all other points lie to the same side of the straight line through p1 and p2, i.e. whether ax+by-c all have the same sign ax+by-c a Efficiency: Design and Analysis of Algorithms – Chapter 3 44 Convex hull brute force algorithm a Algorithm: For each pair of points p1 and p2 For determine whether all other points lie to the same side of the straight line through p1 and p2, i.e. whether ax+by-c all have the same sign whether a Efficiency: Θ (n3) Design and Analysis of Algorithms – Chapter 3 45 Exhaustive search: definition a A brute force solution to a problem involving brute search for an element with a special property, usually among combinatorial objects such as a permutations, combinations, or subsets of a set. permutations, Design and Analysis of Algorithms – Chapter 3 46 Exhaustive search: method a Construct a way of listing all potential solutions to Construct the problem in a systematic manner the • all solutions are eventually listed • no solution is repeated a a Evaluate solutions one by one, perhaps Evaluate disqualifying infeasible ones and keeping track of the best one found so far the When search ends, announce the winner Design and Analysis of Algorithms –...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online