subject

The selection algorithm (to find the kth smallest value in a list), described in the class (and in the book), uses columns of size 5. Assume you implement the same selection algorithm using columns of size 9, rather than 5. (a) Exactly how far from either end of the array is the median of medians guaranteed to be. Just give the high order term. (Recall that with columns of size 5 we got 3n 10 .) (b) It turns out that there is an algorithm that finds the median of 9 elements with 14 comparisons. Using this algorithm, briefly list each step of Selection with columns of size 9 and how many comparisons the step takes. Note that partition can now be done with only (4/9)n comparisons; use this value in your analysis. (c) Write a recurrence for the number of comparisons the algorithm uses. (d) Solve the recurrence using constructive induction. Just get the high order term exactly. (e) With more careful analysis, in class we could have obtained 16n comparisons using columns of size 5. How does this new value, using columns of size 9, compare?

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 00:00
11. is the ability to understand how another person is feeling. a. authority b. sympathy c. empathy d. taking a stand
Answers: 1
question
Computers and Technology, 22.06.2019 10:20
Shown below is the start of a coding region within the fist exon of a gene. 5'--3' 3'--5' how many cas9 pam sequences are present?
Answers: 1
question
Computers and Technology, 22.06.2019 21:00
Describir textbook icon_person mira los dibujos y describe lo que está pasando. usa los verbos de la lista.
Answers: 1
question
Computers and Technology, 23.06.2019 04:31
Type the correct answer in the box. spell all words correctly. the managing director of a company sends a christmas greeting to all his employees through the company email. which type of network does he use? he uses an
Answers: 1
You know the right answer?
The selection algorithm (to find the kth smallest value in a list), described in the class (and in t...
Questions
question
Mathematics, 21.04.2020 19:52
question
English, 21.04.2020 19:53
question
Mathematics, 21.04.2020 19:53
Questions on the website: 13722361