login
Riesel problem in base 5: a(n) is the smallest k >= 0 such that (2*n)*5^k - 1 is prime, or -1 if no such k exists.
1

%I #7 Jun 18 2021 12:27:40

%S 4,0,0,0,3,0,0,1,0,0,1,0,4,1,0,0,163,1,0,1,0,0,1,0,2,5,0,2,7,0,0,5,5,

%T 0,1,0,0,1,1,0,1,0,2058,1,0,26,5,1,0,1,0,0,3,0,0,3,0,32,17,1,2,1,3,0,

%U 3,0,8,21,0,0,1,1,4,1,0,0,1,4,0,7,1,0,1,0

%N Riesel problem in base 5: a(n) is the smallest k >= 0 such that (2*n)*5^k - 1 is prime, or -1 if no such k exists.

%C a(346802/2) = a(173401) = -1 (see A273987).

%H Joe O, <a href="https://www.mersenneforum.org/showpost.php?p=233495&amp;postcount=1">Project Description</a>, Mersenne forum.

%H Reggie, <a href="https://www.primegrid.com/forum_thread.php?id=5087">Welcome to the Sierpinski/Riesel Base 5 Project</a>, PrimeGrid forum.

%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Riesel_number">Riesel number</a>

%e For n = 5: 10*5^k - 1 is composite for k = 0, 1, 2 and prime for k = 3. Since 3 is the smallest such k, a(5) = 3.

%o (PARI) a(n) = for(k=0, oo, if(ispseudoprime((2*n)*5^k-1), return(k)))

%Y Cf. A040081 (base 2), A343914 (base 3), A250205 (base 6).

%Y Cf. A273987.

%K sign

%O 1,1

%A _Felix Fröhlich_, Jun 18 2021