Wikipedia:Reference desk/Archives/Mathematics/2013 May 28

Mathematics desk
< May 27 << Apr | May | Jun >> May 29 >
Welcome to the Wikipedia Mathematics Reference Desk Archives
The page you are currently viewing is a transcluded archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


May 28 edit

A Number With All Digits Equal Can Never Be A Perfect Square edit

Why ? :-) I'm not just looking for a solution, but for the simplest possible solution... — 79.113.211.75 (talk) 07:26, 28 May 2013 (UTC)[reply]

hatting removed, OP said "Correct but undesired approach"

Suppose n is an integer such that all the digits of n2 are the same, and (obviously) are not all 0. Look at what the final digits of n can be. Examining the last two digits of all the squares from 1^2 to 99^2 shows that n must end in 12, 38, 62 or 88 - the squares of these numbers all end in 44. Now examine the last three digits of the squares of 3-digit numbers that end in 12, 38, 62 or 88. You will find that only four of these numbers have squares whose last 3 digits are the same. So there are only four possibilities for the last 3 digits of n. Next examine the last four digits of the squares of 4-digit numbers that end in any of these four 3-digit possibilities. You will find that none of these squares have their last 4 digits all the same. Since you have eliminated all the possibilities for the last 4 digits of n, you have shown that n does not exist. Gandalf61 (talk) 08:54, 28 May 2013 (UTC)[reply]
This was precisely the approach I was trying to avoid... :-) — 79.113.211.75 (talk) 11:52, 28 May 2013 (UTC)[reply]
Something like Gandalf61's solution is perhaps unavoidable, as the result depends on the number base used. For example, 11111 is a square in base 3. The result is true in base 2, where 11...1 = 2n - 1 is never a square (excluding the trivial cases) because odd squares are of the form 4k + 1. AndrewWTaylor (talk) 12:18, 28 May 2013 (UTC)[reply]
Indeed - I was just about to point out that the result is base dependent, but you beat me to it ! My example was 1111 and 4444 are both squares in base 7. Gandalf61 (talk) 12:32, 28 May 2013 (UTC)[reply]
I never said that it doesn't depend on the base... Since it's fairly obvious that 11 is a perfect square in all bases of the form b = n2 - 1. — 79.113.211.75 (talk) 13:52, 28 May 2013 (UTC)[reply]
A slight simplification (or variant) of Gandalf's proof: if n = 4...44 is a square (the only possibility) then so is n/4 = 1...11 - a contradiction, because no square ends in 11. AndrewWTaylor (talk) 16:09, 28 May 2013 (UTC)[reply]
Simplest solution besides 0 is 1. It is a square with all its digits equal ;-) Dmcq (talk) 09:48, 28 May 2013 (UTC)[reply]
0 and 1 do not have "digits", but "digit". :-) — 79.113.211.75 (talk) 11:52, 28 May 2013 (UTC)[reply]
Well you might like the argument that All horses are the same color whatever about the horses in the Emerald City in Oz. As to this problem what do you think is the first odd number base for which one can't find such a number? Dmcq (talk) 13:31, 28 May 2013 (UTC)[reply]
Probably 5. — 79.113.211.75 (talk) 14:10, 28 May 2013 (UTC)[reply]

End of hatting removed

Would it be easier to rephrase the question as there are no solutions to   with   and   ? Or would it only complicate things even further ? — 79.113.221.225 (talk) 17:54, 28 May 2013 (UTC)[reply]

How about 4? Or 9? Not to mention 1.—PaulTanenbaum (talk) 18:39, 28 May 2013 (UTC)[reply]
You can fairly easily rule out all d except 3 and 7. For both of these, it's easy to see that 111 divides 10^n-1. This suggests (since 111=3*37) that the modulus 37 might be important (or possibly 37^2). I don't really have anything concrete to say though. Sławomir Biały (talk) 01:09, 29 May 2013 (UTC) (Sorry about the formatting. I'm traveling and so on a mobile.)[reply]
d = 1 → (3k)2 + 1 = 10n → 9 k2 = 999...999 → k2 = 111...111 → k mod 10 = {1,9}
a) k = 10 m + 1 → k2 = 100 m2 + 20 m + 1 → The next-to-last digit has to be even. But 1 is not an even number. → Absurd.
b) k = 10 m + 9 = 10 p - 1, where p = m + 1 → k2 = 100 p2 - 20 p + 1 → The next-to-last digit has to be even. But 1 is not an even number. → Absurd.
d = 2 →  (3k)2 + 1 = 10n → 2|k2 → 4|k2 → 18 k02 = 999...999 → 2 k02 = 111...111 → Absurd, since the last digit has to be even, but 1 is not an even number.
d = 3 →  (3k)2 + 1 = 10n → 3 k2 = 999...999 → k2 = 333...333 → 3|k2 → 9|k2 → 9 k02 = 333...333 → k02 =   → 3|n → k02 = 037...037 → Absurd, since no perfect square ends in 7. Perfect squares can end only in 0,1,4,5,6,9.
d = 4 →  (3k)2 + 1 = 10n → 2|k → 9 k02 = 999...999 → k02 = 111...111 → Absurd, see the case d = 1.
d = 5 →  (3k)2 + 1 = 10n → 5|k2 → 25|k2 → 45 k02 = 999...999 → 5 k02 = 111...111 → Absurd, since the last digit has to be either 0 or 5, and 1 is neither.
d = 6 →  (3k)2 + 1 = 10n → 2|k2 → 4|k2 → 6 k02 = 999...999 → 2 k02 = 333...333 → Absurd, since the last digit has to be even, but 3 is not an even number.
d = 7 →  (3k)2 + 1 = 10n → 7|k2 → 49|k2 → 63 k02 = 999...999 → 7 k02 = 111...111 → Absurd, since it would imply a perfect square ending in 3, see the case d = 3.
d = 8 →  (3k)2 + 1 = 10n → 8|k2 → 16|k2 → 18 k02 = 999...999 → 2 k02 = 111...111 → Absurd, since the last digit has to be even, but 1 is not an even number.
d = 9 →  (3k)2 + 1 = 10n → k2 = 999...999 → 3|k → k02 = 111...111 → Absurd, see the case d = 1.
79.113.229.253 (talk) 14:43, 29 May 2013 (UTC)[reply]
  Resolved
Where did the 3 of the 3k in the numerator come from? Sorry yes that's reasonable. Dmcq (talk) 15:12, 29 May 2013 (UTC)[reply]
Where do the k0 come from?Naraht (talk) 17:42, 29 May 2013 (UTC)[reply]
If x|k then k = x ko. — 79.113.242.37 (talk) 18:02, 29 May 2013 (UTC)[reply]
Ah, good. There's an easier argument for most of the other cases besides d=3,7. You can rule out 4, 8, and 9, just by dividing k by 2 or 3. d=1, 5 are impossible because 11...1and 55...5 are 3 mod 4. Similarly with 2, 6. Sławomir Biały (talk) 17:51, 29 May 2013 (UTC)[reply]

Is there anything that can be said about the bases where there exists a rep-digit which is a perfect square? Right now we've got 11111 base 3, 1111 base 7, 4444 base 7, and in general 11 base (n^2 -1). Are there bases other than 7 and n^2 -1?Naraht (talk) 19:22, 28 May 2013 (UTC)[reply]

A computer search finds lots of other bases where the repdigit has 2, 3 or 4 digits. For more than 4 digits I have only found 11111 base 3. PrimeHunter (talk) 23:25, 28 May 2013 (UTC)[reply]
I don't think 111 can be a square in any base. The next square after b2 = 100b will be (b + 1)2 = 121b, and 100 < 111 < 121 (... treat base 2 separately ...), so 111 cannot be a square. Gandalf61 (talk) 10:30, 29 May 2013 (UTC)[reply]
Elaborating on that: a string of m+1 1's cannot be an mth power in any base, and there can be only finitely many bases for which a string m+1 k's can be an mth power if k < m. To see this, let t(m, k, b) be a string of m k's in base b. Then if t(m+1,1,b) is an mth power, (b+1) ** m <= t(m+1, 1, b) = b ** m + t(m, 1, b). (b+1) ** m - b ** m = m(b ** (m-1)) + poly(deg = m-2)>(b ** m - 1) / (b - 1) = t(m, 1, b), hence t(m+1, 1, b) is not an mth power. For the case of all digits being k; t(m+1, k, b) = k * t(m+1, 1, b); looking at the prior inequality, for large enough b, the m-1 degree term dominates, hence t(m+1, k, b) cannot be an mth power unless b is small enough.Phoenixia1177 (talk) 16:27, 29 May 2013 (UTC)[reply]
21 21 21 21 is a square base 41, you can get more 4 digit ones like that using Pells equation for   when   is the digit. Dmcq (talk) 11:41, 29 May 2013 (UTC)[reply]
Right, 111 cannot be a square. Many other digits can produce 3-digit squares. Below are (base, digit) pairs for all 3-digit repdigit squares where the base is below 10000 and the digit is square-free (other solutions can be generated from the listed by multiplying the digit by a square).
(18, 7), (22, 3), (30, 19), (68, 13), (146, 127), (292, 237), (313, 3), (423, 97), (439, 201), (499, 21), (521, 283), (581, 247), (653, 7), (699, 109), (710, 19), (787, 453), (1047, 457), (1353, 763), (1425, 1099), (1660, 741), (1714, 471), (2060, 1141), (2174, 571), (2198, 907), (2272, 57), (2819, 61), (3019, 1101), (3130, 1839), (3445, 1119), (3789, 3199), (4366, 3), (4526, 67), (4611, 13), (4620, 2269), (4624, 1209), (4701, 7), (4788, 2437), (4972, 1533), (5261, 3343), (5421, 367), (5656, 417), (6057, 547), (6106, 4503), (6158, 1963), (6205, 111), (6895, 1929), (6927, 2713), (7163, 4837), (7527, 217), (7627, 2037), (7733, 2623), (9317, 1423), (9353, 523)
The corresponding (base, digit) list for 4-digit squares is far shorter:
(7, 1), (41, 21), (99, 58), (239, 30), (1393, 697), (2943, 943), (8119, 1015)
There are no 5-digit solutions for bases below 10000. PrimeHunter (talk) 23:15, 29 May 2013 (UTC)[reply]
Probably because 111b =   = b2 + b + 1 is inbetween two consecutive squares: b2 and (b + 1)2 = b2 + 2 b + 1.— 79.113.242.37 (talk) 23:28, 29 May 2013 (UTC)[reply]