### Happy Numbers

Take any whole number between 1 and 999, add the squares of the digits to get a new number. Make some conjectures about what happens in general.

### Zooming in on the Squares

Start with a large square, join the midpoints of its sides, you'll see four right angled triangles. Remove these triangles, a second square is left. Repeat the operation. What happens?

# Litov's Mean Value Theorem

##### Stage: 3 Challenge Level:

Start with two numbers, say 8 and 2. This is the start of a sequence of numbers.

The rule is that the next number in the sequence is the average of the last two numbers.

So the next number is $1/2$ of $(8 + 2$), which equals $5$,
so the sequence becomes $8, 2, 5$

The next number is $1/2$ of $(2 + 5)$, which equals $3.5$,
so the sequence becomes $8, 2, 5, 3.5$

Continue the sequence until you know what will happen when you continue this process indefinitely.

Choose two different starting numbers and repeat the process.

Continue exploring with different start numbers, trying to discover what the rule is for finding the limiting value.

Can you find a relationship between the two start numbers and the limiting value?

Can you explain why it works?

Now start with three numbers, say $4, 1, 10$.

The new rule is that the next number is the mean of the last three numbers.

So the next number is $1/3$ of $(4 + 1 + 10)$, which equals $5$,

so the sequence becomes $4, 1, 10, 5$

The next number is $1/3$ of $(1 + 10 + 5)$, which equals $16/3$,
so the sequence becomes $4, 1, 10, 5, 16/3$

Continue this sequence and find the limiting value as the process is continued indefinitely.

Can you find a rule for finding the limiting value in this case?

Can you find a relationship between the three start numbers and the limiting value?

Can you explain why it works?

General rule

Now explore what happens when you have $n$ start numbers and the rule for working out the next number changes to finding the average of the last $n$ numbers.

The NRICH Project aims to enrich the mathematical experiences of all learners. To support this aim, members of the NRICH team work in a wide range of capacities, including providing professional development for teachers wishing to embed rich mathematical tasks into everyday classroom practice. More information on many of our other activities can be found here.
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 19, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "github"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "english_confidence": 0.928607702255249, "perplexity_flag": "middle"}