Sums of digits of Perfect Squares

In summary: P_n(x)=-k_n*x^n for some arbitrary n and x in the range -1 to 1, then you can show that P_n(x)=-k_0*x^0 for any n. This follows from the fact that, for any real number x, x^0+x^1+x^2+...=x^n. So, in other words, the absolute value of a perfect square is negative.In summary, the pattern of sums of the digits of perfect squares suggests that the square of a natural number is the sum of the digits of the number raised to an odd power and the sum of the digits of the number raised to an even power.
  • #1
tommy05
5
0
A little while ago I noticed a pattern in the sums of the digits of perfect squares that seems to suggest that:

For a natural number N, the digits of N^2 add up to either 1, 4, 7, or 9.

ex: 5^2 = 25, 2+5 = 7

In some cases, the summation must be iterated several times:

ex: 7^2 = 49, 4+9=13, 1+3 = 4
ex: 10^2 = 100, 1+0+0 = 1

If you make a list of the summations of the perfect square digits, the following patterns emerge:

Sums of digits (of the following numbers ^ 2) -
1 > 1, 8, 10, 17, 19...
4 > 2, 7, 11, 16, 20...
7 > 4, 5, 13, 14, 22, 23...
9 > 3, 6, 9, 12, 15...

(As an extension, this pattern seems to hold up for N ^ any even power...this might help in formulating a proof. )

Does anyone know if there exists a proof for this apparent pattern, or does anyone have any idea of how to formulate a proof for it?
 
Physics news on Phys.org
  • #2
as any even power is also a square, that part is implied by the first.

as for the first, well, i can prove it for about 1/3 of the natural numbers (those divisible by three)

i've got half an idea as to how to show the rest of it but it's late on the weekend right now...
 
  • #3
Just a first thought...

Now I'm interested, so I will work on it later, but just for starters, I would sum the digits of each N first, and see what that pattern revealed...
i.e.
one digit #'s sums, 1-9: 1,2,3,4,5,6,7,8,9,
the teens, 10-19:1,2,3,4,5,6,7,8,9,1,
20-29: 2,3,4,5,6,7,8,9,1,2,

99999: 9*5=45, 4+5=9
100000: =1

actually I could have laid that out much better, but you get the idea, 1-9 repeats.

Well, must run, happy thoughts

Rachel
 
  • #4
Oh yeah

And, it the sums work for N= 1-9
 
  • #5
If someone can do this faster than I am...

Break down your multiplication and/or addition algorithm and analyze, track each step.
If anyone is even there or cares
Okay, I'll stop :biggrin:

Rachel
 
  • #6
Sorry, but quickly...

Summing each N first-
cubes have sums: 1, 8, 9 repeating in order
^5: 1, 5, 9, 7, 2, 9, 4, 8, 9
which seems to break down, but this makes me think of Abel's proof about quintic equations...
anyway, this is the last such hasty post, I promise.

Rachel
 
  • #7
Well, this is not AS hasty...

Noticing that N^2 is the partial sum at N (that is at the nth term, starting at 1) of the constant sequence N,
<enclose subscripts>
i.e. 4^2 = 4<1> + 4<2> + 4<3> + 4<4>
and recalling how the sums of each N repeat: 1, 2, 3, ... 9, 1, 2, ...
you just show how the sum at 4444 is equal to the sum of the digits of the square... sorry for my poor explanation. I will seriously stop this time and complete my thoughts before posting again.

Rachel
 
  • #8
Last words :)

If someone is familiar with modulo computations, as I am not, it should just be a matter of finding the values of: 1, 22, 333, 4444, 55555, etc. modulo 9, or however you say it.
Not sure if this will suffice as a proof, but I really have to run this time- so much fun, though :) I will certainly check back later! You may have to go the sequence route for rigour...

Rachel
 
  • #9
Well, all of the multiples of 3 can be eliminated (as mentioned above) by noting that any multiple of 3 raised to an even power is a multiple of 9:

(3Q)^N = 3^N * Q^N = 9^(N/2) * Q^N, and since N is even, N/2 must be an integer.

The digits of any multiple of 9, then, add up to 9.

Another way of analyzing this, which I'm going to look at when I have more time, is resolving the base Q into its prime factors, and try to see how that influences the sum of the digits of Q^2. Obviously, when 3 is a factor of Q, the sum is 9...

I'll keep looking into this :)
 
  • #10
Rachel, it is very unclear what you are doing. Please take more time to explain.
 
  • #11
Actually it does come out quite easily, I'm ashamed I didn't see it immediately.

Suppose k=k_nk_{n-1}...k_0 is the writing of k in base ten expansion. ie k = sum k_i10^i, as i runs from 0 to n. Let S be the sum of the digits of k, then S==k mod(9)

further if k is a perfect square this implies S is a quadratic residue mod(9), that is S is one of 1,4,7,9. Moreover we see that k=1,4,9,16 show that all of these possibilities must occur.
 
  • #12
Cheers :)

Matt,
Well, that was greek to me, but I'm glad you know what you mean, err... something...
And, yes, I apologize for the public brainstorm, emphasis on Storm- I'm an independent student and rarely ever get to play with others ;) That and too much coffee.
I was just now trying to clean up my argument, and it looks like if you define, for a and b in N, a^b as the partial sum of the first a^(b-1) terms of the series whose every term is a, (oh precious symbols, I miss them ;) then you can extend the argument to all b. I haven't written this out yet to check it, but the reasoning seems sound. (famous last words, right hehehe...) The modular sequence, whatever it's properly called, certainly doesn't change. Only the number of terms of a to be summed, and thus the values for which you need to prove congruence. And this should follow a general rule. (?I think!)
Anyway, glad you have your answer.
Happy thoughts
Rachel
 
  • #13
Honestly, your reasoning doesn't seem related to the question asked.
 
  • #14
Addendum

If your aim is only to sum the digits of a number, or several numbers, then their place value (ones, tens, millions) is irrelevant, yes? Since you define place value as the product of the digit and the appropriate power of ten, which is just the digit followed by zeros.
abcd = a*10^3 + b*10^2 + c*10^1 + d*10^0

Start with the sequence
(1, 10, 100, ...) = 10^(r-1) with r_1 = 1. <S>

Then, to find the sum of the digits of a^b,
Multiply [the partial sum of <S> at a^(b-1)] by a.
Now locate this value in your modal sequence and... presto! (?I think!)

Let me know if this helps, as I have so much reading to do, I won't be able to study modal arithmetic any time soon.

BTW, the expansion of the products of the partial sum times a looks interesting... I think it might rob me of some sleep tonight ;)

Happy thoughts
Rachel
 
  • #15
You see this line:

"Start with the sequence
(1, 10, 100, ...) = 10^(r-1) with r_1 = 1. <S>"

and this line


"Then, to find the sum of the digits of a^b,
Multiply [the partial sum of <S> at a^(b-1)] by a.
Now locate this value in your modal sequence and... presto! (?I think!)"

now there's absolutely no link between them as far as I can see.

not least because, for some reason, you want to examine 4444, and the sum there is, er, 12, ie 3, which contradicts the proof of the observation offered. Although what modal sequence is, or its value is a little hazy
 
Last edited:
  • #16
Matt, would it be too much to ask you to expand your modular arithmetic operation or explain it so someone who isn't too familiar with modular arithmetic can understand it? I'm only in first-year calculus right now, so I haven't been exposed to modular arithmetic and residues...(perhaps I'll read up on that along with all the books on my list for the Zeta Function!)

thanks :)
 
Last edited:
  • #17
Write n^2 as [tex]\sum_{i=0}^{n}k_i10^i[/tex] then the sum of digits of n^2 has remainder on divisios by 9 the same as the sum of k_i does. But this sum must be a "qaudratic residue", meaning it is, well congruent to a square after division by 9, and the only such residues are 1,2,4,9. I don't know that I can explain it more clearly than that in this forum. Look it up on the web somewhere (legendre symbols, quadratic maths adn so forth)
 
  • #18
To clarify

Matt,

I'll try again, and try not to just repeat what I said earlier. It may be that my reasoning is faulty, as I certainly haven't done a thorough analysis. That said, I don't think this is complete garbage.

Consider N^2 and N^2m, that is, all even powers as a special case of a more general rule which applies to all powers p in N.

The sum of the digits of all perfect cubes equals either 1, 8, or 9.
1
8
2+7 = 9
6+4 = 1 + 0 = 1
1+2+5 = 8
2+1+6 = 9
etc.
Which suggests a pattern similar to the squares.
However, the first nine sums of the fifth power do not themselves suggest any pattern, at least not to me.

BUT their pattern will still repeat every 9 numbers because the sums of the digits of each n in N repeats every 9 numbers.

I have computed the first 20 values for n^5:
1 =1
32 =5
243 =9
1024 =7
3125 =2
7776 =9
16807 =4
32768 =8
59049 =9
100000 =1
161051 =5
248832 =9
371293 =7
537824 =2
759375 =9
1048576 =4
1419857 =8
1889568 =9
2476099 =1
3200000 =5

I'll stop there and see if you follow.

Rachel
 
  • #19
Oh, I see what you're getting at, but as a general proof has been offered (and it is correct) I think you ought to look at it and try and understand it.

The sums of the digits of the p#th power of some integer are p'th roots mod (9), that's all.
 
  • #20
Matt,

Sorry, I wasn't attempting to give a complete proof (I am coming up with this rather on the fly). I was just trying to give you the most important results.

There is a proof of what I outlined in my last post already, you mean?

Do they use this to find the sum of the digits of any natural a^b? Because that is what I think I can do.

Rachel
 
  • #21
Oooops

Nevermind my last question, I somehow missed the answer in your last post.
 
  • #22
Sorry, can't let this go.
4+4+4+4=16 which is 7, as it should be.
 
  • #23
I don't understand the relevance of the post above...
 
  • #24
Ok, I found a link explaining quadratic residues: http://mathworld.wolfram.com/QuadraticResidue.html

However, in its list of quadratic residues (mod n), it says that the quadratic residues (mod 9) are: 1, 4, 7...so 9 is NOT a residue, and hence this doesn't seem to be able to be applied to squares such as 6^2=36
 
  • #25
tommy, 9=0 mod(9) so the list is of the non-zero quadratic residues.

honesrosewater, yes, got that one wrong, but adding up n n's doesn't seem to ge to very far in itself. But I see what you're getting at, but I dont' see how that is going to offer a proof.
 
  • #26
Hindsight

Matt,
Yes, nevermind. There are several ways to get there, and the way I was taking yesterday was neither the easiest nor most direct. Besides it depended on my being able to define a sequence I didn't yet know how to define.
Oh well, live and learn. I'll think twice about posting an incomplete thought.
Sorry for the runaround.
Rachel
P.S. I see I once said modal instead of modular. Slip of the tongue.
 

FAQ: Sums of digits of Perfect Squares

What is a perfect square?

A perfect square is a number that can be expressed as the product of two equal integers.

What is the sum of digits of a perfect square?

The sum of digits of a perfect square is the sum of all the individual digits that make up the number.

Are there any patterns in the sums of digits of perfect squares?

Yes, there are some patterns in the sums of digits of perfect squares. For example, the sum of digits of all perfect squares with an odd number of digits is always a multiple of 9.

How can sums of digits of perfect squares be useful in mathematics?

Sums of digits of perfect squares can be useful in various mathematical concepts, such as number theory, algebra, and geometry. They can also help in finding relationships between numbers and identifying patterns.

Is there a formula to calculate the sum of digits of a perfect square?

Yes, there is a formula to calculate the sum of digits of a perfect square. It is (n * (n + 1) * (2n + 1)) / 6, where n is the number of digits in the perfect square.

Back
Top