Chapter 2: Q2E (page 83)
Show that for any positive integers n and any base b , there must some power of b lying in the range .
Short Answer
To show that some power of b falls in the range of
Chapter 2: Q2E (page 83)
Show that for any positive integers n and any base b , there must some power of b lying in the range .
To show that some power of b falls in the range of
All the tools & learning materials you need for study success - in one app.
Get started for freeThis problem illustrates how to do the Fourier Transform (FT) in modular arithmetic, for example, modulo .(a) There is a number such that all the powers are distinct (modulo ). Find this role="math" localid="1659339882657" , and show that . (Interestingly, for any prime modulus there is such a number.)
(b) Using the matrix form of the FT, produce the transform of the sequence modulo 7; that is, multiply this vector by the matrix , for the value of you found earlier. In the matrix multiplication, all calculations should be performed modulo 7.
(c) Write down the matrix necessary to perform the inverse FT. Show that multiplying by this matrix returns the original sequence. (Again all arithmetic should be performed modulo 7.)
(d) Now show how to multiply the polynomials and using the FT modulo 7.
Consider the task of searching a sorted array for a given element a task we usually perform by binary search in time . Show that any algorithm that accesses the array only via comparisons (that is, by asking questions of the form “is 0?”), must take steps.
What is the sum of the nth roots of unity? What is their product if n is odd? If n is even?
A way merge operation. Suppose you have sorted arrays, each with elements, and you want to combine them into a single sorted array of elements.
(a)Here’s one strategy: Using the merge procedure from Section 2.3, merge the first two arrays, then merge in the third, then merge in the fourth, and so on. What is the time complexity of this algorithm, in terms of and ?
(b) Give a more efficient solution to this problem, using divide-and-conquer.
Find the unique polynomial of degree 4 that takes on values . Write your answer in the coefficient representation.
What do you think about this solution?
We value your feedback to improve our textbook solutions.