COMS
assignment1

# assignment1 - Jacob Manske 31 August 2007 Exercise 01 Let f...

• Notes
• 2

This preview shows pages 1–2. Sign up to view the full content.

31 August 2007 Jacob Manske Com S 511 - Assignment 1 Exercise 01 Let f , g be asymptotically positive functions such that the limit lim n →∞ f ( n ) g ( n ) exists and is finite. Prove that f O ( g ) . Proof. Since lim n →∞ f ( n ) g ( n ) exists and is finite and f and g are asymptotically positive, c R + ∪ { 0 } such that lim n →∞ f ( n ) g ( n ) = c. Then N such that n N , f ( n ) g ( n ) - c < 1. Then f ( n ) g ( n ) - c < 1, so f ( n ) < ( c + 1) g ( n ) n N . Hence f O ( g ), as desired. Exercise 02 Suppose you have a choice of four algorithms to solve a given problem with the following (approximate) running times as a function of input size n : Algorithm 1: n 4 seconds, Algorithm 2: 30 n 3 seconds, Algorithm 3: 1200 n 2 seconds, Algorithm 4: 60000 n seconds. Specify a range of n for which each of the algorithms is optimal. Solution. To find a range of n for which algorithm i is optimal, we find those n such that the running time for algorithm i is less than the running time for algorithm j j = i .

This preview has intentionally blurred sections. Sign up to view the full version.

This is the end of the preview. Sign up to access the rest of the document.
• Fall '07
• Dick
• Graph Theory, lim, Computational complexity theory, 1920, 1916

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern