Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

THIS IS THE QUESTION ABOUT THE D&L OF ALGORITHMS Asymptotic Notation, Comparing Orders and Order Formula QUESTION 1: Using the Ratio Limit Theorem , prove

THIS IS THE QUESTION ABOUT THE D&L OF ALGORITHMS

Asymptotic Notation, Comparing Orders and Order Formula

QUESTION 1: Using the Ratio Limit Theorem , prove the following.

O(108)image text in transcribed O( ln n)image text in transcribed O(n) image text in transcribed O( n ln n) image text in transcribed O( n^2) image text in transcribed O( n^3) image text in transcribed O( 2^n) image text in transcribed O( 3^n) .

QUESTION 2: Obtain a formula for the order of image text in transcribed .

Recurrence Relations for Complexity Analysis

QUESTION 3: A very natural question to ask related to MergeSort is whether we can do better by dividing the list into more than two parts. It turns out we can't do any better, at least in the worst case. In this exercise you will verify this fact mathematically. TriMergeSort, given below, is a variant of MergeSort, where the list is split into three equal parts instead of two. For convenience, assume that n= 3^k , for some nonnegative integer k.

(a) Give a recurrence relation for the worst-case complexity W(n) of TriMergeSort for an input list of size n.

(b) Solve the recurrence formula you have given in (a) to obtain an explicit formula for the worst-case complexity W(n) of TriMergeSort.

(c) Which is more efficient in the worst case, MergeSort or TriMergeSort? Discuss.

QUESTION 4: Consider the sorting algorithm Insertion Sort for sorting a list L[0:n 1]. Derive a recurrence relation for the worst-case complexity W(n) and solve.

Solving Recurrence Relations

QUESTION 5: Solve the following recurrence relations:

a. t(n) = 3t (n-1) + n, nimage text in transcribed 1, init.cond. t(0) = 0.

b. t(n) = 4t (n-1) + 5, nimage text in transcribed 1, init.cond. t(0) = 2.

Mathematical induction

QUESTION 6: a. Prove by induction that

image text in transcribedimage text in transcribed = image text in transcribedimage text in transcribed

b. Briefly describe how the preceding formula can be employed to design an algorithm for computing fib(n) using only at most 8log2n multiplications.

Please help me solve for all the six questions. Thanks.

S(n) = (logi)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

Describe three types of guided media.

Answered: 1 week ago

Question

3. Contrast relational contexts in organizations

Answered: 1 week ago

Question

2. Describe ways in which organizational culture is communicated

Answered: 1 week ago

Question

1. Describe and compare approaches to managing an organization

Answered: 1 week ago