1 early printings of clrs3 say on pages 546-547 we treat

Assignment Help Data Structure & Algorithms
Reference no: EM13370197

1. Early printings of CLRS3 say on pages 546-547 "we treat min and max differently: the element stored in min does not appear in any of the clusters, but the element stored in max does." This is not true (they may have corrected it in later printings)-what that sentence should say is "we treat min and max differently: the element stored in min does not appear in any of the clusters, but unless the vEB tree contains just one element (so that the minimum and maximum elements are the same), the element stored in max does." Rewrite the code for vEB-Empty-Tree-Insert, vEB-Tree-Insert, and vEB- Tree-Delete so that indeed, max does not appear in any of the clusters, just as min does not appear in any of the clusters.

2. Problem 20-1, parts (a) and (b) only, on page 557. In part (b), be careful that you do not get snagged by the pitfall described in the middle of page 86 of CLRS3. (Hint : For part (b), can you prove, under reasonable assumptions, that P(u) = u - 2?) Do not do parts (c)-(g); instead, do the following replacement for part (c):

(c) We can store all of the array-of-pointers substructures in a single array outside the vEB tree itself. This would change the recurrence (20.5) to

P(u) = (√u + 1)P(√u) + O(1).

Solve this recurrence. Does this idea improve the vEB structure?

3. Consider the "dynamic range minimum query problem." Let S ⊆ U = {0, 1, 2, . . . , u-1}. Each s ∈ S is labeled with a real number v(s). We need to maintain a data structure on S that supports the following operations:

• initialize(S): Construct and initialize the data structure for S.
• decreaseKey(s, x): If x < v(s), change v(s) to x; otherwise, do nothing.
• minimum(x): Return min{v(s)|s ∈ S, s ≤ x}.

Show how a vEB tree can be used to support these three operations. Analyze the time/space complexity of your algorithms.

Reference no: EM13370197

Questions Cloud

You make a really solid point in noting that traditional : you make a really solid point in noting that traditional organizations are not able to transform into a lean
1 demonstrate knowledge and understanding of the key : 1. demonstrate knowledge and understanding of the key engineering principles that underpin current geotechnical and
1 your company appointed you as the project manager for a : 1. your company appointed you as the project manager for a new innovative hr project. this project will need a
Question 1antibodies directed against hiv can enhance the : question 1antibodies directed against hiv can enhance the infection by facilitating entry of virus into immune
1 early printings of clrs3 say on pages 546-547 we treat : 1. early printings of clrs3 say on pages 546-547 we treat min and max differently the element stored in min does not
Jane wants to setup a photo shop the cost to rent an office : jane wants to setup a photo shop. the cost to rent an office is 150 per week. the variable cost of making one photo is
What is the cellular tropism of hiv does it change during : what is the cellular tropism of hiv? does it change during the course of an infection? which cellular receptors confer
Question 1 echinoderms describe the specialized structures : question 1 echinoderms describe the specialized structures and functions of echinoderms. include in your answera. a
Strategic operation management and the discussion topic is : strategic operation management and the discussion topic is the overall nature of demand affects planning and control

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Determine complete list of nodes which ancestor

Let the following tree: tree a. Determine the children of Q? b. What is the complete list of nodes which have D as ancestor? c. Determine the height of this tree (as height is defined in text)?

  Identify the most important facts about the diet

Identify the most important facts about the diet. State your opinion about the diet.Support your opinion with relevant facts or research

  Describe a fair coin algorithm to returns either 0 or 1

Describe a FAIRCOIN algorithm that returns either 0 or 1 with equal probability, using ONEINTHREE as your only source of randomness.

  Difference between formulas and functions

Assume your mother in law heard that you prepared the budget for the high school reunion picnic and has asked if you could help her to make a monthly household budget.

  Creating decision tree

Premium Airlines has currently offered to settle claims for a class action suit, which was originated for alleged price fixing of tickets. The settlement is stated as follows. Create a decision tree for this condition.

  Question about pure aloha

A group of N stations share a 56-kbps pure ALOHA channel. Every station outputs a 1000-bit frame on an average of once every one-hundred secs, even if the previous one has not yet been sent.

  Write the relation r as a set if ordered pairs

let A={a,b,c,d,e} and suppose R is an equivalence relation on A . Suppose R has two equivalence classes. also aRd ,bRc and eRd in R . WRITE the relation R as a set if ordered pairs

  Entity relationship diagrams

Discuss why are Entity Relationship Diagrams an important initial stage in developing databases? Who would be the initial parties interacting to develop the ERDs?

  Explain how to modify knuth-morris-pratt algorithm

Explain how to modify Knuth-Morris-Pratt algorithm to support patterns with these wild cards, and analyze modified algorithm. Your algorithm must find first substring in text which matches the pattern.

  Use separate chaining to store the

Use separate chaining to store the following keys. Consider that each letter is a number corresponding to the sequence of English alphabets. That is, A->1,

  Describe the requirement for complex data structures

Describe the requirement for complex data structures and how they are utilized. Describe the design and application of arrays and how the array simplifies program development.

  Use sequential search algortithm to locate the number

These numbers should be stored in an array. Use the sequential search algortithm to locate the number entered by the user. If the number is in the array, the program should display a message.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd