Chapter 2: Problem 27
How many multiplications would be performed in finding the product of two \(64 \times 64\) matrices using the standard algorithm?
/*! This file is auto-generated */ .wp-block-button__link{color:#fff;background-color:#32373c;border-radius:9999px;box-shadow:none;text-decoration:none;padding:calc(.667em + 2px) calc(1.333em + 2px);font-size:1.125em}.wp-block-file__button{background:#32373c;color:#fff;text-decoration:none}
Learning Materials
Features
Discover
Chapter 2: Problem 27
How many multiplications would be performed in finding the product of two \(64 \times 64\) matrices using the standard algorithm?
All the tools & learning materials you need for study success - in one app.
Get started for free
Suppose that, even unrealistically, we are to search a list of 700 million items using Binary Search (Algorithm 2.1). What is the maximum number of com parisons that this algorithm must perform before finding a given item or concluding that it is not in the list?
Write an algorithm that sorts a list of \(n\) items by dividing it into three sublists or almost \(n / 3\) items, sorting each sublist recursively and merging the three sorted sublists. Analyze your algorithm, and give the results using order notation.
Use the divide-and-conquer approach to write an algorithm that finds the largest item in a list of \(n\) items. Analyze your algorithm, and show the results in order notation.
Show that if \\[ W(n) \leq \frac{(p-1)(p-2)}{2}+\frac{(n-p)(n-p-1)}{2} \\] then \\[ W(n) \leq \frac{n(n-1)}{2} \quad \text { for } \quad 1 \leq p \leq n \\] This result is used in the discussion of the worst-case time complexity analysis of Algorithm 2.6 (Quicksort).
Consider procedure solve \((P, I, O)\) given below. This algorithm solves problem \(P\) by finding the output (solution) \(O\) corresponding to any input \(l\) Assume \(g(n)\) basic operations for partitioning and combining and no basic operations for an instance of size 1 (a) Write a recurrence equation \(T(n)\) for the number of basic operations needed to solve \(P\) when the input size is \(n\) (b) What is the solution to this recurrence equation if \(g(n) \in \Theta(n)\) (proof not required \() ?\) (c) Assuming that \(g(n)=n^{2},\) solve the recurrence equation exactly for \(n=\) 27 (d) Find the general solution for \(n\) a power of 3
What do you think about this solution?
We value your feedback to improve our textbook solutions.