[go: up one dir, main page]

login
A087985
a(n) = prime(x) is the smallest prime such that 1+n*prime(x) is divisible by prime(x+1), or 0 if no such prime exists.
2
2, 0, 3, 2, 23, 19, 2, 3, 47, 2, 5, 43, 2, 7, 83, 2, 0, 3, 2, 11, 79, 2, 3, 0, 2, 0, 103, 2, 17, 13, 2, 5, 3, 2, 0, 7, 2, 3, 5, 2, 0, 163, 2, 257, 263, 2, 7, 3, 2, 0, 0, 2, 3, 0, 2, 61, 223, 2, 11, 5, 2, 47, 3, 2, 41, 73, 2, 3, 7, 2, 317, 11, 2, 5, 19, 2, 0, 3, 2, 7, 5, 2, 3, 829, 2, 17, 0, 2, 67, 0
OFFSET
1,1
COMMENTS
Two unsolved problems:
1. Given arbitrary n, does there exist an m such that 1 + n*prime(x) = m*prime(x+1) is solvable? For several n (e.g., n = 17, 24, 26, 35, 41, 50, 51, 54, 87) a search up to x=10000000 did not provide a prime(x) solution.
2. If a solution exists, then the number of solutions is believed to be finite. E.g., at n=2122, 8 solutions were found after an extensive search {prime(x)} = {2, 19, 23, 37, 89, 433, 4241, 7621}.
FORMULA
a(n) = Min{prime(x); (1 + n*prime(x)) mod prime(x+1) = 0}; a(n) = p; 1 + n*p = m*q where {p, q} are smallest consecutive primes satisfying relation belonging to n.
EXAMPLE
n=1: 1 + 1*p = q is satisfied by the consecutive prime pair {2,3}; a(1)=2.
n=2: 1 + 2*p = m*q, no solution.
n=6: 1 + 6*p = m*q is satisfied first by {p,q} = {19,23} because 6*19 + 1 = 115 = 5*23.
It is provable that there are arbitrarily large n to which (a finite number of) solutions exist.
MATHEMATICA
{k=0, nu=0; sq={}}; Table[Print[{n-1, Min[Prime[sq]]}]; nu=0; sq={}; Do[s=Mod[n*Prime[x]+1, Prime[x+1]]; If[Equal[s, 0], nu=nu+1; sq=Append[sq, n]], {x, 1, 10000000}], {n, 1, 257}]
PROG
(PARI) a(n) = local(i, c, p, q); i = 1; c = 0; q = 2; while (1, p = q; q = prime(i + 1); if (!((1 + n*p)%q), return(p)); if ((i + n*p)/q > n - 1/10, c++; if (c == 8, return(0)), c = 0); i++); \\ David Wasserman, Jun 17 2005
CROSSREFS
Cf. A087986.
Sequence in context: A079451 A219187 A049799 * A200927 A372820 A372819
KEYWORD
nonn
AUTHOR
Labos Elemer, Oct 06 2003
EXTENSIONS
More terms from David Wasserman, Jun 17 2005
STATUS
approved