I had thought about this sequence (where each positive integer $n$ shows up $n$ times) the other day and think I have a closed form solution. First of all we know that the last time that $k$ shows up in the sequence is at $a_{\frac{k(k+1)}{2}}$. We want to see if $a_n$ is one of these last occurrences. So we solve $\frac{k(k+1)}{2} = n$ for $k$. If $k$ is an integer then we know $a_n = k$ but if $k$ is not an integer then $a_n$ must be $\left \lceil k \right \rceil$ since the last occurrence of $\left \lfloor k \right \rfloor$ occurred before $n$. Therefore the value of $a_n$ is: $\left \lceil \frac{\sqrt{8n+1} -1}{2}\right \rceil$ Is this correct? Is there anything interesting about this sequence other that that the sum of it values and the sum of its reciprocals both diverge? Thanks.
Closed form solution to $\{a_n\}_{n=1}^{\infty} = 1,2,2,3,3,3,...$
3
$\begingroup$
analysis
-
1It can also be defined recursively by $a_1=1,\quad a_n=1+a_{n-a_{n-1}}$ – 2012-11-29
1 Answers
1
Your reasoning and result looks good. For more details and interesting properties on this sequence, have a look at the OEIS database. Note, that they also give the closed form expression assuming $n \ge 0$ (as against your $n \ge 1$) as follows:
$\left \lfloor \frac{\sqrt{8n+1} + 1}{2}\right \rfloor, n\ge 0$
For your definition ($n$ starts from 1), they also provide another closed for expression as:
$\left \lfloor \frac{1}{2} + \sqrt{2n}\right \rfloor$
You can look up the database for other properties and references for this sequence.
-
0No problem! My reaction was the same when someone introduced me to OEIS, so glad I could do the same :) – 2012-11-29