Squaring is Daring (1)

The following sequences go by the rule:

a n + 1 a_{n+1} = The sum of the squares of the individual digits of a n a_{n}

For example, 56 becomes 61, because 5 2 5^{2} + 6 2 6^{2} = 25 + 36 25 + 36 = 61.

The following is an example of a bad sequence, because it reaches the number 1, and stays there.

{28, 68, 100, 1, 1, 1…}

The following is an example of a good sequence, because it repeats and is non-terminating:

{30, 3, 9, 81, 65, 61, 37 , 58, 89, 145, 42, 20, 2, 4, 16, 37 …}

If I create all sequences from 51 to 60 (inclusive), how many will be "good"?

Super Challenge: Can you find the general set of starting numbers that will make a sequence "good"/"bad"?

Ultimate Challenge: Prove It!

9 10 6 7 0 3 8 4

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.

1 solution

Efren Medallo
Jun 9, 2015

The method I used is the crudest way. Forgive me.

Initially, we know that the sequence will only be bad if the sum of squares of the digits are 100 or 10. We know that every composite integer n n can be expressed as a sum of squares if every prime factor p 3 ( m o d 4 ) p \equiv 3 (mod 4) has an even multiplicity (or zero multiplicity, which just means that no such factor exists for that number). For both 100 and 10, it can be both expressed as a sum of two squares.

For 100 100 , the possible previous terms would be 68 68 or 86 86 . For 10 10 , the possible previous terms would be 13 13 or 31 31 .

Out of these four numbers, 31 31 and 86 86 have prime factors p 3 ( m o d 4 ) p \equiv 3 (mod 4) that have an odd multiplicity. Therefore these numbers can no longer be further expressed as a sum of squares. So, if these are the starting numbers of the sequence, your sequence will be bad.

Meanwhile, 13 13 and 68 68 can still be expressed as a sum of squares.

For 68 68 , the possible previous terms would be 82 82 or 28 28 . For 13 13 , the possible previous terms would be 23 23 or 32 32 .

Then we remove 28 28 and 23 23 , and again iterate on 82 82 and 32 32

For 82 82 , the possible previous terms would be 91 91 or 19 19 . For 32 32 , the possible previous term would just be 44 44 .

Then we remove all 91 91 , 44 44 and 19 19 , because they all have prime factors p 3 ( m o d 4 ) p \equiv 3 (mod 4) that have an odd multiplicity.

In summary, we have the following starting numbers that will surely give a bad sequence.

10 , 13 , 19 , 23 , 28 , 31 , 32 , 44 , 68 , 82 , 86 , 91 , 10, 13, 19, 23, 28, 31, 32, 44, 68, 82, 86, 91, and 100 100 .

Thus, we can conclude that from 51-60, all sequences are good.

UPDATE! I found out that these numbers which start bad sequences are called "happy numbers".

I actually think this is good. It is very thorough. Do you think you could expand it to 3 digit numbers? How many 3 digit starting numbers become good sequences?

Ashwin Padaki - 6 years ago

Log in to reply

For three digit numbers, it would mean just checking all of those "bad" starting numbers if they can be expressed as a sum of three squares. I purposefully did not include them in my solution because the problem was focused on how many from 51-60 start "good" sequences. :)

Efren Medallo - 6 years ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...