Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Assignment: Introduction to Algorithms

Problems

1.

(a) We have n users on a P2P network who want to pick distinct IDs in a distributed fashion. Each user independently picks one uniformly random b bit number. Show that when b ≥ 6 + 2 log n, the probability of the users picking distinct IDs is at least 0:99.

(b) We have n users with distinct IDs on a P2P network, who want to elect a leader in a distributed fashion. Each user independently picks a uniformly random b-bit number, and the leader is determined to be the user with the smallest number. Show that when b ≥ 8 + log n, the probability that a unique leader is chosen is at least 0:99.

(Hint: To obtain a simple bound on the sum of a series, approximate it by an integral. In particular, for a positive increasing function h, i=1k h(i) ≥ i=0k h(i) di.)

2.

(a) You are given a circle of unit circumference. You pick k points on the circle independently and uniformly at random and snip the circle at those points, obtaining k different arcs. Determine the expected length of any single arc.

(Hint: Note that the length of each arc is identically distributed, so each has the same expectation. What is the sum of their expectations?)

(b) You are given a sorted circular linked list containing n integers, where every element has a "next" pointer to the next larger element. (The largest element's "next" pointer points to the smallest element.) You are asked to determine whether a given target element belongs to the list. There are only two ways you can access an element of the list: (1) to follow the next pointer from a previously accessed element, or (2) via a given function RAND that returns a pointer to a uniformly random element of the list.

Develop a randomized algorithm for ?nding the target that makes at most O(√n) accesses in expectation and always returns the correct answer.

(Hint: Your algorithm will perform some random accesses and some amount of linear search. Use part (a) to analyze the number of steps in the linear search.)

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92781023

Have any Question?


Related Questions in Computer Engineering

Discuss why a financial services organization would benefit

Discuss why a financial services organization would benefit from using one framework over another (COSO, COBIT,) -- choose a framework or frameworks that in your opinion would be most ideally suited for such an organizat ...

What are content management systems cms describe the

What are Content Management Systems (CMS). Describe the challenges in implementing and maintaining CMS. Can internet search engines be considered as Content Management Systems - explain your answer.

We have seen how dynamic arrays enable arrays to grow while

We have seen how dynamic arrays enable arrays to grow while still achieving constant-time amortized performance. This problem concerns extending dynamic arrays to let them both grow and shrink on demand. a) Consider an u ...

You are on a system in which the finger program has been

You are on a system in which the finger program has been disabled and you want a quicky finger type program and you decide that greping/etc/passwd would be sufficient. However the system that you are on uses nis+ and so ...

Question subject digital securitywhat do you think about

Question : Subject : Digital Security What do you think about how cloud makes DLP (Data Loss Prevention) more difficult? The response must be typed, single spaced, must be in times new roman font (size 12) and must follo ...

Nbspintroduction to software developmentusing only

Introduction to Software Development Using only Flowgorithm program. Please do not answer if you do not know the answer or you are nor sure .... I need only the Flowgorithm program. Rainfall statistics. Design a program ...

Select a company or any existing business this can be the

Select a company or any existing business. This can be the company you currently work for. If you cannot find information about the security infrastructure of a company, you may make up the details as realistic as possib ...

Why are some nations economically strong and others

Why are some nations economically strong and others economically weak?

You are studying the number of defective parts produced

You are studying the number of defective parts produced each week by several machines to help adjust maintenance protocols. Assume the rows of matrix Def represent different machines and all columns except the last repre ...

Question suppose a wireless channel has a coherence

Question : Suppose a wireless channel has a coherence bandwidth of 100 kHz. What range of bit rates can be supported to have flat fading? The response must be typed, single spaced, must be in times new roman font (size 1 ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As