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.

A335732 Emirps whose concatenation of adjacent digit differences either form an emirp that also has this characteristic or form a single-digit prime, and whose emirp also has this characteristic.

This page as a plain text file.
%I A335732 #28 Jan 15 2023 19:49:47
%S A335732 13,31,79,97,347,709,743,769,907,967,1847,7481
%N A335732 Emirps whose concatenation of adjacent digit differences either form an emirp that also has this characteristic or form a single-digit prime, and whose emirp also has this characteristic.
%e A335732 7481 is in the list as the concatenation of adjacent digit differences forms an emirp (i.e., |7-4|=3; |4-8|=4; |8-1|=7; which form 347, which is an emirp as 743 is also prime). Furthermore, for 347, |3-4|=1; |4-7|=3; forms 13, which is an emirp as 31 is also prime. Finally, |1-3| = 2, which is prime. This characteristic is also true for the emirp of 7481 which is 1847 (i.e., 1847 forms 743 which forms 31 which finally forms 2).
%o A335732 (Python)
%o A335732 from sympy.ntheory import isprime as isp
%o A335732 i = []
%o A335732 for a in range(10,1000000):
%o A335732     if isp(a):
%o A335732         b = str(a)
%o A335732         d=[]
%o A335732         for c in range(0,len(b)-1):
%o A335732             ee = abs(int(b[c])-int(b[c+1]))
%o A335732             d.append(str(ee))
%o A335732         f = ''.join(d)
%o A335732         g = b[::-1]
%o A335732         if isp(int(f)) and isp(int(g)):
%o A335732             if len(b)<3:
%o A335732                 i.append(b)
%o A335732             else:
%o A335732                 if f in i:
%o A335732                     i.append(b)
%o A335732 print(','.join(i))
%Y A335732 A subset of A006567.
%K A335732 base,nonn,fini,full,less
%O A335732 1,1
%A A335732 _Ray G. Opao_, Jun 20 2020