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.

A251860 Numbers n = concat(s,t) such that n = prime(s) + prime(t).

This page as a plain text file.
%I A251860 #16 May 26 2015 19:42:24
%S A251860 254,64581,64582,64611,64612,64626,64676,64698,64706,64711,64712,
%T A251860 64724,2159962,3232398,1998135468,11520892878,17788754556
%N A251860 Numbers n = concat(s,t) such that n = prime(s) + prime(t).
%C A251860 If we consider the product instead of the sum, n = concat(s,t) = prime(s) * prime(t), then the first terms are 14 and 2127. In fact:
%C A251860 14 = concat(1,4) and prime(1) * prime(4) = 2 * 7 = 14.
%C A251860 2127 = concat(2,127) and prime(2) * prime(127) = 3 * 709  = 2127.
%C A251860 a(18) > 8*10^10. - _Giovanni Resta_, May 26 2015
%F A251860 n = concat(s,t) = A000040(s) + A000040(t).
%e A251860 254 = concat(2,54) and prime(2) + prime(54) = 3 + 251 = 254.
%e A251860 64581 = concat(6458,1) and prime(6458) + prime(1) = 64579 + 2 = 64581.
%e A251860 64582 = concat(6458,2) and prime(6458) + prime(2) = 64579 + 3 = 64582. Etc.
%p A251860 with(numtheory):P:=proc(q) local s,t,k,n;
%p A251860 for n from 1 to q do for k from 1 to ilog10(n) do s:=n mod 10^k; t:=trunc(n/10^k); if s*t>0 then if ithprime(s)+ithprime(t)=n
%p A251860 then print(n); break; fi; fi; od; od; end: P(10^6);
%p A251860 # program from _R. J. Mathar_, Jan 22 2015:
%p A251860 isA251860 := proc(n)
%p A251860     local ti,i1,i2;
%p A251860     if n >= 10 then
%p A251860         for ti from 1 to A055642(n)-1 do
%p A251860             i1 := modp(n,10^ti) ;
%p A251860             i2 := floor(n/10^ti) ;
%p A251860             if i1 > 0 and i2 > 0 then
%p A251860                 if ithprime(i1)+ithprime(i2) = n then
%p A251860                     return true;
%p A251860                 end if;
%p A251860             end if;
%p A251860         end do:
%p A251860         false;
%p A251860     else
%p A251860         false;
%p A251860     end if;
%p A251860 end proc:
%p A251860 for n from 1 do
%p A251860     if isA251860(n) then
%p A251860         print(n);
%p A251860     end if;
%p A251860 end do:
%o A251860 (PARI) isok(n) = {my(nb = #Str(n)); for (k=1, nb-1, s = n\10^k; t = n % 10^k; if (s && t && prime(s)+ prime(t) == n, return (1));); return (0);} \\ _Michel Marcus_, Dec 10 2014
%Y A251860 Cf. A000040, A249766.
%K A251860 nonn,base,more
%O A251860 1,1
%A A251860 _Paolo P. Lava_, Dec 10 2014
%E A251860 a(13)-a(17) from _Giovanni Resta_, May 26 2015