0

I have tried to substitute $n$ with $n - 1$ to get $$(n - 1)a_{n - 1} = 2(n - 2) + na_{n - 2}$$ and then combine the two equations to get $$n(a_n - 2a_{n - 1} + a_{n - 2})=2$$ but this didn't lead me anywhere.

I heard there is a method to solve such non-homogenous equations by finding a solution to the homogeneous equation and finding a particular solution to the non-homogeneous one. I know how to solve the homogenous equation, but I don't know how to find a particular solution or don't know this method in detail.

If anyone can help solve this recurrence or recommend a good explanatory source where I can learn how to solve such recurrences, help would be appreciated.

Anas A. Ibrahim
  • 1,884
  • 7
  • 15

1 Answers1

2

Write the recurrence as: $$ na_n-(n+1)a_{n-1}=2(n-1)\ . $$ Now multiply through by $\ \frac{1}{n(n+1)}\ $, \begin{align} \frac{a_n}{(n+1)}-\frac{a_{n-1}}{n}&=\frac{2(n-1)}{n(n+1)}\\ &=\frac{-2}{n}+\frac{4}{n+1}\ , \end{align} and sum both sides of this identity from $\ n=1\ $ to $\ m\ $ to get \begin{align} \frac{a_m}{m+1}&=-2\sum_{n=1}^m\frac{1}{n}+4\sum_{n=2}^{m+1}\frac{1}{n}\\ &=-4+\frac{4}{m+1}+2\sum_{n=1}^{m}\frac{1}{n}\ . \end{align} Finally, multiply this equation through by $\ m+1\ $ to get $$ a_m=-4m+2(m+1)\sum_{n=1}^{m}\frac{1}{n}\ . $$ I doubt if there's any simpler formula for the general term of the recurrence, since none is known for the $\ n^\text{th}\ $ harmonic number, $\ H_n=\sum_\limits{k=1}^{n}\frac{1}{k}\ $.

lonza leggiera
  • 28,646
  • 2
  • 12
  • 33