cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A247965 a(n) is the smallest number k such that m*k^2+1 is prime for all m = 1 to n.

This page as a plain text file.
%I A247965 #17 Nov 11 2014 14:40:58
%S A247965 1,1,6,3240,113730,30473520,3776600100,16341921960,3332396388090
%N A247965 a(n) is the smallest number k such that m*k^2+1 is prime for all m = 1 to n.
%C A247965 Conjecture : the sequence is infinite.
%C A247965 a(10) > 15466500000000. a(11) > 107669100000000. - _Hiroaki Yamanouchi_, Oct 01 2014
%e A247965 a(3)=6 because 6^2+1 = 37, 2*6^2+1 = 73 and 3*6^2+1 = 109 are prime numbers.
%e A247965 The resulting primes begin like this:
%e A247965 2;
%e A247965 2, 3;
%e A247965 37, 73, 109;
%e A247965 10497601, 20995201, 31492801, 41990401;
%e A247965 ... - _Michel Marcus_, Sep 29 2014
%p A247965 for n from 1 to 6 do:
%p A247965   ii:=0:
%p A247965    for k from 1 to 10^10 while(ii=0) do:
%p A247965      ind:=0:
%p A247965        for m from 1 to n do:
%p A247965          p:=m*k^2+1:
%p A247965           if type(p,prime) then
%p A247965            ind:=ind+1:
%p A247965            fi:
%p A247965         od:
%p A247965        if ind=n then
%p A247965         ii:=1:printf ( "%d %d \n",n,k):
%p A247965        fi:
%p A247965     od:
%p A247965   od:
%o A247965 (PARI)
%o A247965 a(n)=k=1;while(k,c=0;for(i=1,n,if(!ispseudoprime(i*k^2+1),c++;break));if(!c,return(k));if(c,k++))
%o A247965 n=1;while(n<10,print1(a(n),", ");n++) \\ _Derek Orr_, Sep 28 2014
%Y A247965 Cf. A002496, A090698, A002648, A137530, A090687, A201602, A090685, A156226.
%K A247965 nonn,hard,more
%O A247965 1,3
%A A247965 _Michel Lagneau_, Sep 28 2014
%E A247965 a(7)-a(9) from _Hiroaki Yamanouchi_, Oct 01 2014