login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A333115 a(n) is the least prime p such that A001222(p+n) = A001222(p-n) = n. 0

%I #22 Sep 26 2020 10:42:10

%S 23,47,1621,373,2352631,9241,18235603,21968759,27575049743,2794997,

%T 32503712890637,304321037,390917388671861,277829661054961,

%U 14392115869140641,442395934703

%N a(n) is the least prime p such that A001222(p+n) = A001222(p-n) = n.

%C a(10) <= 311346179693.

%C a(11) = 2794997.

%C a(18) > 7*10^12, a(19) = 1040573169683. - _Giovanni Resta_, Mar 08 2020

%e a(3) = 47 is prime; 47-3 = 44 = 2^2*11 and 47+3 = 50 = 2*5^2 both have 3 prime divisors with multiplicity.

%p f:= proc(n) local k;

%p for k from n+1+(n mod 2) by 2 to 3*10^6+1 do

%p if isprime(k) and numtheory:-bigomega(k-n)=n and

%p numtheory:-bigomega(k+n)=n then return k

%p fi od;

%p FAIL

%p end proc:

%p map(f, [$2..7]);

%t Table[SelectFirst[Prime@ Range@ 2000000, PrimeOmega[#-n] == n && PrimeOmega[#+n] == n &], {n, 2, 8}] (* _Robert Price_, Sep 16 2020 *)

%o (PARI) a(n) = forprime(p=n+1, oo, if(bigomega(p-n)==n && bigomega(p+n)==n, return(p))); \\ _Jinyuan Wang_, Mar 08 2020

%Y Cf. A001222.

%K nonn,more

%O 2,1

%A _J. M. Bergot_ and _Robert Israel_, Mar 07 2020

%E a(8)-a(9) from _Jinyuan Wang_, Mar 08 2020

%E a(10)-a(17) from _Giovanni Resta_, Mar 08 2020

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 28 04:13 EDT 2024. Contains 371235 sequences. (Running on oeis4.)