5.11. Convert the proof of Proposition 5.18 into an algorithm and use it to write each of the following numbers n as a sum of positive and negative powers of 2 with at most ½ [log n] + 1 nonzero terms. Compare the number of nonzero terms in the binary expansion of n with the number of nonzero terms in the ternary expansion of n. (a) 349. (b) 9337. (c) 38728. (d) 8379483273489.

Calculus: Early Transcendentals
8th Edition
ISBN:9781285741550
Author:James Stewart
Publisher:James Stewart
Chapter1: Functions And Models
Section: Chapter Questions
Problem 1RCC: (a) What is a function? What are its domain and range? (b) What is the graph of a function? (c) How...
icon
Related questions
Question

(a) only

Proposition 5.18. Let n be a positive integer and let k = [logn] +1, which
means that 2k > n. Then we can always write
n =
uo+u₁·2+U₂·4+u3 · 8+ ··· + Uk ·
2k
.
with uo, u₁,..., Uk € {−1,0,1} and at most k of the u; nonzero.
(5.5)
Transcribed Image Text:Proposition 5.18. Let n be a positive integer and let k = [logn] +1, which means that 2k > n. Then we can always write n = uo+u₁·2+U₂·4+u3 · 8+ ··· + Uk · 2k . with uo, u₁,..., Uk € {−1,0,1} and at most k of the u; nonzero. (5.5)
5.11. Convert the proof of Proposition 5.18 into an algorithm and use it to write
each of the following numbers n as a sum of positive and negative powers of 2 with
at most [logn] + 1 nonzero terms. Compare the number of nonzero terms in the
binary expansion of n with the number of nonzero terms in the ternary expansion
of n.
(a) 349.
(b) 9337. (c) 38728. (d) 8379483273489.
Transcribed Image Text:5.11. Convert the proof of Proposition 5.18 into an algorithm and use it to write each of the following numbers n as a sum of positive and negative powers of 2 with at most [logn] + 1 nonzero terms. Compare the number of nonzero terms in the binary expansion of n with the number of nonzero terms in the ternary expansion of n. (a) 349. (b) 9337. (c) 38728. (d) 8379483273489.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 2 images

Blurred answer
Recommended textbooks for you
Calculus: Early Transcendentals
Calculus: Early Transcendentals
Calculus
ISBN:
9781285741550
Author:
James Stewart
Publisher:
Cengage Learning
Thomas' Calculus (14th Edition)
Thomas' Calculus (14th Edition)
Calculus
ISBN:
9780134438986
Author:
Joel R. Hass, Christopher E. Heil, Maurice D. Weir
Publisher:
PEARSON
Calculus: Early Transcendentals (3rd Edition)
Calculus: Early Transcendentals (3rd Edition)
Calculus
ISBN:
9780134763644
Author:
William L. Briggs, Lyle Cochran, Bernard Gillett, Eric Schulz
Publisher:
PEARSON
Calculus: Early Transcendentals
Calculus: Early Transcendentals
Calculus
ISBN:
9781319050740
Author:
Jon Rogawski, Colin Adams, Robert Franzosa
Publisher:
W. H. Freeman
Precalculus
Precalculus
Calculus
ISBN:
9780135189405
Author:
Michael Sullivan
Publisher:
PEARSON
Calculus: Early Transcendental Functions
Calculus: Early Transcendental Functions
Calculus
ISBN:
9781337552516
Author:
Ron Larson, Bruce H. Edwards
Publisher:
Cengage Learning