# find the 1991st term

• January 13th 2011, 06:37 PM
chris86
find the 1991st term
Let 2,3,5,6,7,10,11,... be an increasing sequence of positive integers that are neither the perfect squares nor the cubes. Find the 1991st term.
• January 13th 2011, 06:57 PM
chiph588@
Quote:

Originally Posted by chris86
Let 2,3,5,6,7,10,11,... be an increasing sequence of positive integers that are neither the perfect squares nor the cubes. Find the 1991st term.

Let's define $f(n)$ to be the number of numbers less than or equal to $n$ such that they are neither the perfect squares or cubes.

We then have $\displaystyle f(n) = n - \lfloor \sqrt{n}\rfloor - \lfloor \sqrt[3]{n}\rfloor + \lfloor \sqrt[6]{n}\rfloor$.

The intuition behind $f(n)$ is we take every number up to $n$ and then subtract all of the perfect squares and cubes. We must then account for any duplicates.

Now solve $f(n) = 1991$.
• January 13th 2011, 07:05 PM
chiph588@
Quote:

Originally Posted by chiph588@
Let's define $f(n)$ to be the number of numbers less than or equal to $n$ such that they are neither the perfect squares or cubes.

We have $\displaystyle f(n) = n - \lfloor \sqrt{n}\rfloor - \lfloor \sqrt[3]{n}\rfloor + \lfloor \sqrt[6]{n}\rfloor$.

Intuition behind $f(n)$ is we take every number up to $n$ and then subtract all of the perfect squares and cubes. We then must account for duplicate counting.

Now solve $f(n) = 1991$.

Don't know a great way to solve that though. Perhaps binary search in the interval $[0,4000]$ or something like that. Or you could just plot it and solve via inspection (that's how I did it).