Alex is an undergraduate computer science student, he was given the task to find the first number consisting of n digits, such that it's square contains 2 * n digits, he is trying to come up with an efficient algorithm. The young student tries to incorporate his answer in a limit, so he only has to consider near-limit cases. Let f(n) represent the value of the first number of n digits, such that it's square contains 2*n digits, evaluate the following limit:
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
For the square of a number a to have twice as many digits as a but still be minimal, a has to be the smallest integer greater than the square root of the power of 10 that has the required number of digits.
Example:
a is a four digit number. Hence, it's square has to be an 8 digit number, so at least 1 0 7 = 1 0 , 0 0 0 , 0 0 0 . To be minimal, a has to be just above this number's square root, a = ⌈ 1 0 7 ⌉ = 3 1 6 3 . And, in fact, 3 1 6 3 2 = 1 0 , 0 0 , 4 5 6 9 > 1 0 , 0 0 0 , 0 0 0 but 3 1 6 2 2 = 9 , 9 9 8 , 2 4 4 < 1 0 , 0 0 0 , 0 0 0 .
In general, for an n digit number, f ( n ) = a = ⌈ 1 0 2 n − 1 ⌉ .
= = = = = = ≈ n → ∞ lim 1 0 n f ( n ) n → ∞ lim 1 0 n ⌈ 1 0 2 n − 1 ⌉ n → ∞ lim 1 0 n 1 0 2 n − 1 n → ∞ lim 1 0 n 1 0 n − 2 1 n → ∞ lim 1 0 n 1 0 n 1 0 − 2 1 n → ∞ lim 1 0 − 2 1 1 0 − 2 1 = 1 0 1 0 . 3 1 6 2