Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

While I was investigating some specific types of prime numbers I have faced with the following infinite sequence :


I tried to find recursive formula using Maple and it's listtorec command, so up to $393$ I got the next output:

$ f(n+3) = ((-10604990407411886564453040+8614360900967683126093782*n$ $-1437788330056801496567841*n^2-20019334790519891406942*n^3$ $+10676199651161684501481*n^4)*f(n+1)$ $+(-1637719982644311036922320-2457276199701830407970234*n$ $-480059310080505210547097*n^2+383671472063948372228234*n^3$ $-33849767081583104776903*n^4)*f(n+2))$ $/(-936042047504931985146406*n -3812415630664251269364960$ $+337414858035611215686569*n^2+50641450188283496191324*n^3$ $-8211420729473965803551*n^4) $

but when I added $560$ to list Maple sent me message FAIL.

So, my question is : how can I find pattern for this sequence if it exists ?

share|cite|improve this question
You might noting that the recursive formula is much more complicated than the first 14 numbers in the sequence. This usually a clue that that the formula may not extend to higher terms. – Henry Sep 28 '11 at 8:43
I've always hated "problems" like this...any finite sequence is the beginning of uncountably many infinite sequences. – user5137 Sep 28 '11 at 14:32
up vote 6 down vote accepted

Try the Online Encyclopedia of Integer Sequences.

share|cite|improve this answer

You can look up integer sequences at OEIS:

So your sequence is "Numbers $n$ such that $6*10^n+1$ is prime". I assume you're looking for a formula, but if there was a closed-form expression for these numbers, we could find arbitrarily large prime numbers! The largest known prime has 12978189 digits and right now there is a 250,000 dollar prize to whoever finds a prime number with at least 1,000,000,000 digits (see So if you find a formula for these numbers, please tell me.

share|cite|improve this answer
+1 for "So if you find a formula for these numbers, please tell me" ;) – Quixotic Sep 28 '11 at 7:05
@spin,I am far away from discovering formula but one thing I know for sure...none of these numbers is divisible by $6$ – pedja Sep 28 '11 at 17:32

Almost certainly the first thing you should do is try OEIS

Doing so gives in your case gives that the sequence is numbers $n$ such that $6\times10^n+1$ is prime.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.