# What is the pattern to this sequence?

$$0, 1, 3, 13, 51, 205$$

More specifically, $$(0,0)\quad(1,1)\quad (2,3)\quad (3,13) \quad(4,51)\quad (5,205)$$ I have tried using the interpolation feature in Grapher.app and Wolfram Alpha, but cannot seem to get what I'm looking for which is a quadratic function that hands me the numbers from the top part.

UPDATE/EDIT

For those of you interested, I encountered the above sequence after factoring $\frac{2}{5}$ from the sum $$\sum_{n=1}^\infty \frac{2^n}{2^{2n} + (-1)^{n+1}} = \frac{2}{5} +\frac{4}{15}+\frac{8}{65}+\frac{16}{255}+\frac{32}{1025} ...$$

$$=\frac{2}{5} * \left(1+ \frac{2}{3}+\frac{4}{13}+\frac{8}{51}+\frac{16}{205} ...\right)$$

The numerators in the brackets are powers of $2$, while the denominators were the ones in question.

Thanks for the help!

• Of course you cannot find a quadratic function for this sequence, because the sequence is non-quadratic. To confirm this, solve $y=ax^2+bx+c$ using any three points, and then note that the other two points are non-compliant. Out of curiosity, where did this problem come from and why is it necessary to attempt modeling the sequence with software? Commented Sep 2, 2013 at 12:34
• Interestingly, weegy was asked about the sequence 1/4,0,1,-3,13,-51,205 Commented Sep 2, 2013 at 16:52
• @user2307487 I'm trying to find a general pattern to a sequence. That's where I encountered the sequence in question. Commented Sep 2, 2013 at 17:50
• As a side note, any number could be a possible solution. See this answer of a similar question for an explanation. Commented Sep 2, 2013 at 20:11
• It is clear from your edition that the pattern is $a_n=\dfrac{2^{2n}+(-1)^{n+1}}{5}$. Is that answer acceptable? why? Commented Mar 12, 2016 at 20:18

In cases like this, it is recommended to try and visit the OEIS.

• Don't give up the math to the computers, train your brain power)
– rook
Commented Sep 2, 2013 at 11:16
• I believe that that pattern matches the one I posted because it also matches the next two terms: 819 and 3277. Thanks! Commented Sep 2, 2013 at 17:52
• @zerosofthezeta, great, and you're welcome! Commented Sep 2, 2013 at 22:26
• @AndreasCaranti... could you kindly help me providing hint /suggestion to this problem...math.stackexchange.com/questions/680613/….... Commented Mar 14, 2014 at 5:50

Of course, with such pattern recognition questions, you can let the next value be anything.

My suspicion is that $u_{n+1} = 4 u_{n} + (-1)^n$.

• @GTonyJacobs Indeed. OP decided to start with $u_0$. Commented Sep 2, 2013 at 8:49

Using the recurrence $a_n = 4a_{n-2} +3a_{n-1}$, which this sequence appears to satisfy, you can derive an explicit formula for $a_n$, namely:

$a_n = \frac{4^n - (-1)^n}{5}$

It's exponential - it grows too fast to be quadratic. You can find a quadratic function that passes through any three of those points, but it won't pass through the others at the same time.

• You can get the same formula for $a_n$ by solving the inhomogeneous recurrence $a_n = 4a_{n-1} - (-1)^n$. Commented Sep 2, 2013 at 8:45

There is no quadratic function for that sequence. One possible equation is: $a(n) = 3a(n-1) + 4a(n-2)$

This sequence represents:

• The inverse binomial transform of powers of 5.
• The number of walks of length n between any two distinct vertices of the complete graph $K_5$.
• The number of segments (sides) per iteration of the space-filling Peano-Hilbert curve.
• For n>=2, a(n) equals the permanent of the (n-1)X(n-1) tridiagonal matrix with 3's along the central diagonal, and 2's along the subdiagonal and the superdiagonal.

For a question like this we can come up with our own pattern. The next number can be anything we want. We can come up with a pattern for each answer.

a(n)=a(n-1)*4 then check the value of n position, if it is odd then add one,if it is even then substrata one

It is clear from the (edited) question that the pattern is $a_n=\dfrac{2^{2n}+(−1)^{n+1}}{5}$. Is that answer acceptable?