Questions tagged [recurrence-relations]

Questions regarding functions defined recursively, such as the Fibonacci sequence.

A recurrence relation is an equation that recursively defines a sequence or multidimensional array of values: once one or more initial terms are given, each further term of the sequence or array is defined as a function of the preceding terms.

Simple examples include the geometric sequence $a_{n}=r a_{n-1}$, which has the closed-form $a_{n}=r^n a_0$, the aforementioned Fibonacci sequence with initial conditions $f_0=0,f_1=1$ and recurrence $f_{n+2}=f_{n+1}+f_n$, and series: the sequence $S_n =\sum_{k=1}^{n} a_k$ can be written as $S_n= S_{n-1}+a_n$.

The term order is often used to describe the number of prior terms used to calculate the next one; for instance, the Fibonacci sequence is of order 2.

See the Wikipedia page for more information.

8985 questions
1
vote
3 answers

solution of recurrence relation

I need help in solving recurrence relation: $$x_{n+1} = \exp (-x_n) + 2; x_1 = 1$$ I suppose that I should, assuming the limit exists, solve: $a=e^{-a} + 2$. But how?
fishka
  • 11
1
vote
1 answer

First order linear recurrence relation

I would like to solve the following first order non-homogenous recurrence relation $$ \left(n^2+n-1\right) y_{n+1}-(n-2)\,n\,y_n=\frac{1}{256} \left(25 n^3+150 n^2-173 n+32\right)\,. $$ It is a simple exercise to solve the associated homogenous…
user12588
  • 399
1
vote
1 answer

How to solve the recurrence $T(n) = T\left(\lceil\frac{n}{\sqrt{2}}\rceil+1\right) + 1$?

How to solve the recurrence $T(n) = T\left(\lceil\frac{n}{\sqrt{2}}\rceil+1\right) + 1,\ T(n) = 1$ for $n \leq 8$? Ignoring the ceil and using the Master Theorem I have $$a = 1,\ b = \sqrt{2},\ log_b(a) = log_\sqrt{2}(1) = 0,\ w(n) = 1$$ So we are…
1
vote
4 answers

Non-homogenous recurrence relation

I need to solve the recurrence relation $A(n)=2A(n-2)+ 2^{n-2}$. I tried writing out equations up to the $A(2)$ and multiplying by powers of two and adding all the equations together then all the terms cancelled but after that I couldn't find the…
1
vote
1 answer

Find the $n^{th}$ term of the sequence $\{a_n\}$ such that $\forall n \in \mathbb{N},\frac{a_1+a_2+\cdots+a_n}{n}=n+\frac{1}{n}$.

Here's my attempt. Let $S_n=\sum_{i=1}^n a_i$. So, $S_{n+1}=\sum_{j=1}^{n+1} a_j$. Subtracting them will evantually give $a_{n+1}=2n+1=2(n+1)-1\implies a_n=2n-1$. But the thing is if we put $n=3$, it will give LHS to be equal to $3$ but RHS to be…
Unknown
  • 159
1
vote
2 answers

solving linear non homogeneous recursive relation.

I'm having trouble solving this relation: $a_n = a_{n-1} + 2^{n-1} - 1$ as a part of my university assignment. My intention was to start with finding the $a_{n}^{h}$, and for that I've tried finding a characteristic equation for the homogeneous part…
1
vote
1 answer

Particular solution to difference equation

Given $$x_{n+2}-2x_{n+1}+x_n=1,\text{ }x_0=3,\text{ }x_1=6$$ I found the comp solution to be $x_{nc}=3+3n$. When approaching the particular solution I tried $x_{np}=a$ and $x_{np}=an+b$ but in both cases, when I substitute them into the original…
Nicojwn
  • 103
1
vote
1 answer

Solution to the recursive relation $l_{n}=b_{n-1}+\sum_{k=0}^n l_n a_n b_{n-k} $

I have the following recursive equation $$l_{n}=b_{n-1}+\sum_{k=0}^n l_k a_k b_{n-k},\ n\geq 1$$ where $b_n=1/n!,\ a_n=S_n(-1)$ where $S_n(x)=\sum_{k=0}^n \frac{x^k}{k!}\ \forall x\in \mathbb{R}$ and $l_0=0$. How to solve this? I proceeded a little…
1
vote
1 answer

Is this recurrence relation well defined?

I encountered the following recurrence relation in a problem from the Kangaroo Competition: $$ a_1=1~;~ a_{n+m}=a_n+a_m+n \cdot m ~ (n+m>1) $$ The following values are directly found: $$a_2=a_1+a_1+1 \cdot 1 = 3\\ a_3=a_1+a_2+1 \cdot 2=6\\…
user665967
1
vote
1 answer

Solving the recurrence $a_n=4a_{n-1}+3$

How would I solve this recurrence relation? $$a_n=4a_{n-1}+3$$
jem do
  • 185
1
vote
1 answer

Solve the following recurrances. (Linear with constant coefficients)

I have the two following exercises that I have a very hard time solving. (1) $a_n=3a_{n−1}+ 3^n,a_0= 1$ (2) $a_n= 2a_{n−1}+ 4a_{n−2}−8a_{n−3}+ 1,a_0=a_1=a_2=0$ Both are non-homogeneous with constant coefficients and the general solution should then…
1
vote
2 answers

Understanding Solution to Basic Recurrence Relation

I think I'm not seeing the woods for the trees. In the recurrence relation below, how does this part We know that T(0) = 1, so, we assume n - k = 0 Thus, k = n work please? I.e. why can we assume n - k = 0? The recurrence relation for T(n) is given…
1
vote
2 answers

Solve non-homogeneous linear recurrence

I have the following recurrence $$a_n - 3a_{n-2} + 2a_{n-3} = 9 (-2)^n$$ with initial conditions $a_0 = 0, a_1 = 1, a_2 = 26$. I wish to find an explicit formula for $a_n$. The characteristic polynomial for this recurrence is given by $\lambda(x) =…
cdk
  • 321
1
vote
1 answer

How to approach a simple recurrence problem?

Let $f(n)$ be the number of subsets of $[n]$ that do not contain two consecutive integers. For example, for $n = 4$ we have the subsets $\emptyset$, $\{1\}$, $\{2\}$, $\{3\}$, $\{4\}$, $\{1, 3\}$, $\{1, 4\}$, $\{2, 4\}$, so $f(4) = 8$. The solution:…
1
vote
0 answers

Intuition behind solution of recurrence relations using z transforms or characteristic polynomials

Consider, for instance, the gambler ruins problem: https://www1.cmc.edu/pages/faculty/Bhunter/GamblersRuin.pdf Let $p_k$ be the probability of achieving the maximum $N$ dollars when we have initially $k$ dollars. The recurrence for $p_k$ is given…
Daniel S.
  • 823