<?xml version="1.0" encoding="UTF-8" ?>
  <resource>
  <id>315</id>
  <path>/www/nrich/html/content/00/05/15plus4/</path>
  <resourceTypeID>1</resourceTypeID>
  <last_published>2011-02-01T00:00:01</last_published>
  <indexXML>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;mdoxml version=&quot;1.0&quot;&gt;&lt;br&gt;&lt;/br&gt;
Find the sum, $f(n)$, of the first $n$ terms of the sequence: \begin{equation*} 0, 1, 1, 2, 2, 3, 3, \dots , p, p, p +1, p + 1, \dots \end{equation*}&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Go on to prove that $f(a + b) - f(a - b) = ab$, where $a$ and $b$ are positive integers and $a &amp;amp;gt; b$.&lt;br&gt;&lt;/br&gt;&lt;/mdoxml&gt;</indexXML>
  <solutionXML>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;mdoxml version=&quot;1.0&quot;&gt;&lt;br&gt;&lt;/br&gt;
Vassil from Lawnswood School, Leeds, Michael from Madras College St
Andrews and Koopa Koo from Boston College all solved this problem,
well done all of you. &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Here is Vassil's solution: &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Let $f(n)$ denote the sum of the first $n$ terms of the sequence
$$0, 1, 1, 2, 2, 3, 3,\ldots , p, p, p+1, p+1,\ldots.$$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
First I tried with several numbers. Let $n=15$. Then $f(15)=2
\times (1+2+3+4+5+6+7)=7 \times 8$&lt;br&gt;&lt;/br&gt;
where the sequence is: 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7,
7.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Let $n=14$. Then $f(14)=2 \times (1+2+3+4+5+6+7)-7=7 \times 7$
&lt;br&gt;&lt;/br&gt;
where the sequence is: $0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6,
7$.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Let $n=17$. Then $f(17)=2 \times (1+2+3+4+5+6+7+8)=8 \times
9$&lt;br&gt;&lt;/br&gt;
where the sequence is: $0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7,
7, 8, 8$.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Let $n=16$. Then $f(16)=2 \times (1+2+3+4+5+6+7+8)-8=8 \times
8$&lt;br&gt;&lt;/br&gt;
where the sequence is: $0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7,
7, 8$.&lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
I noticed that the formula for $f(n)$ depends on whether $n$ is odd
or even. &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
${\bf Case}$ ${\bf I}$ - $n$ is odd, i.e. $n=2k+1$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Then $$\eqalign { f(n) = 2(1+2+...+k)\cr = 2k(k+1)/2 \cr = {\left(n
- 1\over 2\right)}{\left(n+1\over 2\right)}.}$$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
${\bf Case}$ ${\bf II}$ - $n$ is even, i.e. $n=2k$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
$$\eqalign { f(n) = 2(1+2+...+k) - k \cr = k^2 + k - k \cr = k^2
\cr = \left({n\over 2}\right)^2.}$$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Now we have to calculate $f(a+b)-f(a-b)$. &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
There are two cases. In the first case, when one of $a$ and $b$ is
even and the other is odd, then $(a+b)$ and $(a-b)$ are both odd.
Otherwise $(a+b)$ and $(a-b)$ are both even. &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;
Case I $(a+b)$ and $(a-b)$ both odd. $$\eqalign{ f(a + b) - f(a -
b) = {(a + b)^2 - 1\over 4} - {(a - b)^2 - 1\over 4} \cr = ab.}$$
Case II $(a+b)$ and $(a-b)$ both even. $$\eqalign{ f(a + b) - f(a -
b) = {(a + b)^2\over 4} - {(a - b)^2\over 4} \cr = ab.}$$ &lt;br&gt;&lt;/br&gt;
&lt;br&gt;&lt;/br&gt;&lt;/mdoxml&gt;</solutionXML>
  <noteXML/>
  <clueXML>&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;mdoxml version=&quot;1.0&quot;&gt;&lt;br&gt;&lt;/br&gt;
&lt;p&gt;Investigate special cases for small $n$ first.&lt;/p&gt;
&lt;p&gt;Can you spot patterns in the sums for $n=3$, $4$, $5$, $6$, $7 \dots$?&lt;/p&gt;&lt;/mdoxml&gt;</clueXML>
  <canonXML/>
  <end_user_role>2</end_user_role>
  <difficulty>3</difficulty>
  <keystage1>0</keystage1>
  <keystage2>0</keystage2>
  <keystage3>0</keystage3>
  <keystage4>0</keystage4>
  <keystage4plus>1</keystage4plus>
  <title>Summats Clear</title>
  <description>Find the sum, f(n), of the first n terms of the sequence: 0, 1, 1,
2, 2, 3, 3........p, p, p +1, p + 1,..... Prove that f(a + b) - f(a
- b) = ab.</description>
  <spec_group>Advanced Algebra
    <specifier>Summation of series</specifier>
  </spec_group>
  <spec_group>Using, Applying and Reasoning about Mathematics
    <specifier>Making and proving conjectures</specifier>
  </spec_group>
  <spec_group>Numbers and the Number System
    <specifier>Odd and even numbers</specifier>
  </spec_group>
  <spec_group>Sequences, Functions and Graphs
    <specifier>Arithmetic sequence</specifier>
  </spec_group>
  <spec_group>Collections
    <specifier>epsilons</specifier>
  </spec_group>
  <spec_group>sfh10
    <specifier>Stage 5 - Reviewed 2012</specifier>
  </spec_group>
</resource>