MathLabs

Problem 3

A function ff on positive integers is defined by f(1)=1f(1)=1, f(3)=3f(3)=3, f(2n)=f(n)f(2n)=f(n), f(4n+1)=2f(2n+1)−f(n)f(4n+1)=2f(2n+1)-f(n), and f(4n+3)=3f(2n+1)−2f(n)f(4n+3)=3f(2n+1)-2f(n). Determine the number of positive integers n≤1988n\le1988 for which f(n)=nf(n)=n.
Step 4 of 6: Step 4
1+1+2+2+4+4+8+8+16+16=621+1+2+2+4+4+8+8+16+16=62
Detailed analysis

For lengths 1 through 10, the counts are 1,1,2,2,4,4,8,8,16,16, totaling 62 through 1023.