Peter wrote:
Let $\{u_{n}\}_{n \ge 0}$ be a sequence of positive integers defined by \[u_{0}= 1, \;u_{n+1}= au_{n}+b,\] where $a, b \in \mathbb{N}$. Prove that for any choice of $a$ and $b$, the sequence $\{u_{n}\}_{n \ge 0}$ contains infinitely many composite numbers.
We can easily find that
\[u_{n}=a^{n}+b\frac{a^{n}-1}{a-1}\]
for all $n\in{N_{0}}$.
Also it is obvious that in the case when $gcd(a;b)>1$ then all the members of the sequence would be composite numbers.
Let's discusse the case when $gcd(a;b)=1$.
\[u_{n}=a^{n}+b\frac{a^{n}-1}{a-1}=(a^{n}-a)+b\frac{a^{n}-a}{a-1}+(a+b)\]
Let's denote by $p$ any prime divisor of $a+b$.
We have that $(a;p)=1$=>
\[p^{m}|a^{\varphi(p^{m})+1}-a\]
Therefore there is a $m_{0}$ number ($m_{0}=\parallel a-1\parallel _{p}$) that for any $m>m_{0}$
\[p^{m}|u_{\varphi(p^{m})+1}\]
and of course $p^{m}<u_{\varphi(p^{m})+1}$. So the infinite set of numbers $u_{\varphi(p^{m})+1}$ ,where $m>m_{0}$, includes only composed numbers.