Maths Olympiad Prep

Library / /121 of 860

Number theory Difficulty 4.8 AIME Find the answer

How many positive integers n2009n \leq 2009 have the property that log2(n)\left\lfloor\log _{2}(n)\right\rfloor is odd?

A number or a short expression. Spacing and $ signs are ignored.

Solution

We wish to find nn such that there is some natural number kk for which 2k1log2n<2 k-1 \leq \log _{2} n< 2k2 k. Since n2009n \leq 2009 we must have k5k \leq 5. This is equivalent to finding the number of positive integers n2009n \leq 2009 satisfying 22k1n<22k2^{2 k-1} \leq n<2^{2 k} for some k5k \leq 5, so the number of such integers is 2+23+25+27+29=6822+2^{3}+2^{5}+2^{7}+2^{9}=682

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.