[Math] How to identify the pattern of a sequence

sequences-and-series

Are there some particular methods for identifying the following types of number series?

  • $6, 10, 19, 44, 93, \cdots$ (Difference being prime no's square starting from 2)

  • $1, -2, 15, 52, -512, \cdots $ ( $^*2-4,\ ^*-6+3,\ ^*4-8,\ ^*-10+5$, and so on)

  • $4, -2, -7, 25, 95,\cdots$ ( $^*-1+2,\ ^*2-3,\ ^*-3+4,\ ^*4-5$, and so on)

I mean they do not follow the arithmetic or geometric series nor do their common difference seem to follow any AM-GM pattern. So, is there any generalized mathematical theorems on these types of number series? Or we have to do it on a trial & error basis using intuition?

Best Answer

As other users have said, usually people goes to OEIS to find the sequence. What not everybody knows is that OEIS has a feature to send the sequence by email called "Superseeker" and, as OEIS says: "This program will accept a sequence of integers and try very hard to find an explanation."

Fortunately, there is a "Superseeker" help page, that explains what methodologies are used to "try very hard to find" the sequence. I think it is very sophisticated and accurate, so here is an excerpt of the ways it tries to identify a pattern (all credits to OEIS, written here only for the purpose of answering OP's question and because OEIS is IMHO an authoritative reference in regards to integer sequences and pattern recognition):

  1. Test if $a(n)$ is a polynomial in $n$ [$a(n)$ denotes the $n^{th}$ term]. In other words, are the differences of some order constant?

  2. Test if the differences of some order are periodic. (Suppose the $k^{th}$ order differences are $d(1), ...,d(n)$. They are said to be periodic if there is a number $p$, the period, with $1 \le p \le n-2$, such that $d(i) = d(j)$ whenever $i = j \pmod{p}$.

  3. Test if any row of the difference table of some depth is essentially constant. This detects such sequences as $4^n - n^4$. (Let the usual difference table be $a(0), a(1), a(2), \cdots $, $b(0), b(1), \cdots$, $c(0), c(1), \cdots , /cdots $. This is the difference table of depth $1$. The table of depth $2$ has as top row $a(0), b(0), c(0), \cdots $ and so on.

  4. For a $2$-valued sequence, compute the six characteristic sequences associated with the sequence and look them up in the OEIS.(Suppose the sequence takes only the values $X$ and $Y$. The six characteristic sequences, all equivalent to the original, are: replace $X,Y$ by $1,2$; by $2,1$; the positions of the $X's$, of the $Y's$; the run lengths; and the derivative, i.e. the positions where the sequence changes.

  5. Form the generating functions (g.f.) for the sequence for each of the following $6$ types: ogf ordinary generating function, egf exponential generating function, revogf reversion of ordinary generating function, revegf reversion of exponential generating function, lgdogf logarithmic derivative of ordinary generating function, lgdegf logarithmic derivative of exponential generating function, and attempt to represent them as rational functions, hypergeometric series, or the solution to a linear differential equation with polynomial coefficients.

  6. Look for a linear recurrence with polynomial coefficients for the coefficients of the above $6$ types of g.f.'s.

  7. Look for a polynomial equation in $y$ and $x$ for the g.f. y(x) of each of the above $6$ types.

  8. Apply the transformations listed below to the sequence and look up the result in the OEIS. Stop when $50$ matches have been found. (Note: there is a very long list of transformations in the help page).

  9. Test if the sequence is a Beatty sequence. (A Beatty sequence is one in which the $n^{th}$ term is $[nz]$, where $z$ is irrational. The complementary sequence is $[ny]$, where $\frac{1}{x} + \frac{1}{y} = 1$. Refs: N. J. A. Sloane, Handbook of Integer Sequences, $1973$, p. $29$; R. Honsberger, Ingenuity in Mathematics, $1970$, p. $93$. If this is a Beatty sequence the value given for $z$ will produce the given terms, but this value of $z$ is very far from being unique.)

The list continues with transformations and other types of possible recurrences. It provides as well a long list of mathematical packages very useful for pattern recognition.

Related Question