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
1 answer

Checking recurrence relation

Is there a way to check my recurrence relation, so I can confirm I did it correctly? $a_k = -4a_{k-1} -4a_{k-2}$ with $a_0 = 0$ $a_1= -1$ My answer: $a_n = 0(-2)^n - ½n(-2)^n$
1
vote
2 answers

Solving a recurrence equation that yields polynomials

I am trying to solve the following recurrence equation: $$ T(n) = kT(n - 1) + nd $$ I have expanded the first 4 values ($n = 1$ was given): $$\begin{align} T(1) & = 1 \\ T(2) & = kT(2-1) + 2d = k + 2d \\ T(3) & = kT(3-1) + 3d = k(k + 2d) + 3d = k^2…
User
  • 11
1
vote
1 answer

Solving recurrences for Big-Theta bound

So I am working on my assignment and have gotten stuck. For previous questions I was able to use Master Theorem to get $\Theta$, but can't use the theorem for this question.. I know to get $\Theta$ I need to prove $O$ and $\Omega$, but I am not sure…
user112747
  • 29
  • 1
  • 5
1
vote
1 answer

Advanced Recurrence Relations

I have to find a close form of the following Recurrence Relations. $P_{t+1} = P_t - \frac{p}{t}P_t$ With $P_{i+1}=\frac{p}{i}$, for some $i < t$. I tried the unfolding method on Knuth, but it leads to me nowhere. This is not a homework problem, but…
max
  • 281
1
vote
2 answers

Recurrence relation $T(n) = T(n/2) + n\log(n)$

So I've been working on this recurrence equation and I'm stumped at the end. $T(n) = T(n/2) + n\log(n);\: T(1) = 1;\: n = 2^k$ and $\log $ is base $2$. $T(2^k) = T(2^{k-1}) + 2^k \log(2^k)$ $T(2^k) = T(2^{k-1}) + (2^k) k$ $T(2^{k-1}) = T(2^{k-2})…
1
vote
2 answers

Help solving a recursion function T(n) = T(n-2) +3

I have the following recursion function: $T(1) = 0$ $T(n) = T(n-2) + 3$ where n is odd integers I know the closed form of this is: $T(n) = \frac{3n-3}{2}$ but this was purly by guessing. Is it possible to show how you can derive the close form?
Krimson
  • 591
1
vote
0 answers

Solving Recurrence Relations (Nonlinear?)

I'm not sure the term, but how do you solve a recurrence relation with a multiplicative factor in the index, so as opposed to $a_n=a_{n-1}+a_{n-2}$ we have something like $a_n=a_{\frac{n}{2}}$. I know that it's easy to guess solutions often, but is…
user82004
1
vote
3 answers

recurrence relation of a finite sequence

Suppose I have a sequence of vectors $v_1,v_2,\ldots,v_n$ and for $k=1,2,\ldots,n-2$ $$v_{k+2}=av_{k+1}+bv_k, \quad a,b\in \mathbb R.$$ Can I deduce that $v_{k}=Ax_1^k+Bx_2^k, k=1,2,\ldots,n$ in which $x_1,x_2$ are roots of the characteristic…
user
  • 1,391
1
vote
0 answers

Is there a way to express a closed form for a partial derivative of this recurrence relation?

Here's the relation: if $n\ge j:$ then $$ \sigma(n,j,d) = d \cdot\left( \log j-\sigma\left(\frac{n}{j}, 1+d, d \right)\right)+\sigma(n, j+d, d )$$ And here's the terminating condition if $n < j$ then $$ \sigma(n,j,d) = 0$$ Now, here's what I'm…
1
vote
3 answers

recurrence relation with doubling stepping size

I have the following recurrence $$f(2n) = 2f(n)+n$$ By taking $f(1) = 1$ and then calculating a few values we can see that it grows in $$O(n \log n)$$ However is there a more algebraic way to come to that conclusion?
hbogert
  • 125
  • 5
1
vote
3 answers

Homework - Resolve the recurrence relation

What's the closed formula of this recurrence relation? $$a_n = a_{n-1}+2a_{n-2}+2^n \text{ with } a_0=1, a_1=2 $$
hlapointe
  • 1,610
1
vote
0 answers

Possible to determine if a more 'compact' solution to a linear recurrence exists?

Given a linear a recurrence relation. It is possible to express a solution in terms of summations, products, and the coefficients which appear in the recurrence. For example, in the case of a single index, assuming $x_0$ constant: $ x_n =…
DAS
  • 732
1
vote
3 answers

Let $S_n$ be the number of binary strings of length = $n$ which do not contain the sub-string $010$. Find a recurrence relation for $S_n$.

Let $S_n$ be the number of binary strings of length = $n$ which do not contain the sub-string $010$. Find a recurrence relation for $S_n$. edit: I tried for $n=4$. There are two positions in string, how to place $010$. []010 or 010[] ... so last…
1
vote
1 answer

non-homogenous recurrence relation, with split boundary conditions

I have non-homogenous recurrence relation: $x_{t+1}=\alpha x_t+\beta x_{t-1}+\gamma$ with the following boundary conditions: $x_2=\alpha x_1+\gamma$ $x_{T}=1/2x_{T-1} +1/2$ Anyone know how to solve this? Thanks, Rob
Rob
  • 421
1
vote
1 answer

Sequences defined as solutions to equations : $u_{n}=v_{n}^n$

For $n$ a positive integer at least equal to $2$, define the two following functions as follows : $$ \begin{align*} f_{n}(x) & = \pi/4 + \arctan(\sqrt[n]{x})-\arctan(1/x) \text{ for all nonzero }x, \\ g_{n}(x) & = x^{n+1} +x^n+x-1 \text{ for…
user20010