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.
%I A247896 #28 Dec 23 2024 14:53:44 %S A247896 29,43,61,67,89,167,227,239,263,269,281,349,367,389,439,457,461,463, %T A247896 487,499,521,563,601,607,613,641,643,647,653,677,683,821,827,983,1063, %U A247896 1229,1277,1283,1289,1361,1367,1423,1427,1429,1447,1481,1483,1489,1549,1601 %N A247896 Primes that produce a different prime when one of its digits is added to it. %C A247896 From an idea of Eric Angelini (see seqfan link). %C A247896 Digit 0 is not considered because the new primes must be different from the starting numbers. Therefore, 101 is not part of the sequence, because the only prime that results from adding one of its digits is 101 + 0 = 101, which is the same number, while 601 is acceptable because 601 + 6 = 607, a prime. %H A247896 Paolo P. Lava, <a href="/A247896/b247896.txt">Table of n, a(n) for n = 1..1000</a> %H A247896 Eric Angelini, <a href="https://web.archive.org/web/*/http://list.seqfan.eu/oldermail/seqfan/2014-August/013432.html"> Primes adding one of their digit to themselves (+chains) </a> %e A247896 The number 29 is prime, and 29 + 2 = 31 is also prime. %e A247896 The same with 487, which produces 487 + 4 = 491, a prime. %p A247896 P:=proc(q) local a,b,k,n,ok; %p A247896 for n from 1 to q do a:=ithprime(n); ok:=0; %p A247896 for k from 1 to ilog10(a)+1 do %p A247896 b:=trunc((a mod 10^k)/10^(k-1)); if b>0 then %p A247896 if isprime(a+b) then ok:=1; break; fi; fi; od; %p A247896 if ok=1 then print(a); fi; od; end: P(10^6); %o A247896 (PARI) /* Description: Generates a vector containing this kind of terms between m^u1 and m^u2 for this definition applied by adding base B digits to the original number in decimal. Here (u1,m,B)=(1,3,10) by default. */ %o A247896 LstThem(u2,u1=1,m=3,B=10)={ %o A247896 my(L:list=List(),y); %o A247896 forprime(x=m^u1,m^u2, %o A247896 y=vecsort(digits(x,B),,8); %o A247896 if(sum(j=1,#y,y[j]&&isprime(x+y[j])), %o A247896 listput(L,x))); %o A247896 vector(#L,i,L[i])} \\ _R. J. Cano_, Sep 27 2014 %o A247896 (Haskell) %o A247896 a247896 n = a247896_list !! (n-1) %o A247896 a247896_list = filter f a000040_list where %o A247896 f p = any ((== 1) . a010051') $ %o A247896 map (+ p) $ filter (> 0) $ map (read . return) $ show p %o A247896 -- _Reinhard Zumkeller_, Sep 27 2014 %Y A247896 Cf. A047791, A048519. %Y A247896 Cf. A000040, A010051. %K A247896 nonn,easy,base %O A247896 1,1 %A A247896 _Paolo P. Lava_, Sep 26 2014