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 A305885 #30 Jul 10 2018 21:16:27 %S A305885 14,16,32,34,35,38,74,76,91,92,95,98,118,119,133,176,194,316,398,712, %T A305885 715,731,736,772,775,778,779,793,794,914,935,973,1118,1195,1312,1336, %U A305885 1774,1937,3112,3199,3337,3379,3394,3772,3992,7132,7198,7318,7376,7771,7912 %N A305885 Zeroless composite numbers which become and remain prime under a complete cyclic shift of digits. %C A305885 Numbers with a zero digit have been excluded as cycling through these numbers would generate leading zeros, which become problematic throughout the cycle. %C A305885 3999131, 7919777, 37177739 and 391331191 are in this sequence, see the link. - _Eric Chen_, Jun 14 2018 %C A305885 The sequence contains all composites without the digit zero that can be obtained by cyclically permuting the digits of the terms of A270083. - _Felix Fröhlich_, Jul 10 2018 %H A305885 Robert Israel, <a href="/A305885/b305885.txt">Table of n, a(n) for n = 1..121</a> (first 56 terms from Philip Mizzi) %H A305885 World of numbers, <a href="http://www.worldofnumbers.com/circular.htm">Circular prime</a> %F A305885 { A052382 } intersection { A068653 }. %F A305885 { A068653 } minus { A011540 }. %e A305885 N_0 = 1118 (composite); %e A305885 N_1 = 1181 (prime); %e A305885 N_2 = 1811 (prime); %e A305885 N_3 = 8111 (prime); %e A305885 N_4 = N_0 = 1118 (composite). %p A305885 Q[1]:= [seq([i],i=1..9)]: %p A305885 for d from 2 to 7 do Q[d]:= map(t -> seq([i,op(t)],i=1..9),Q[d-1]) od: %p A305885 Res:= NULL: count:= 0: %p A305885 for d from 2 to 7 do %p A305885 for q in Q[d] do P[q]:= isprime(add(q[i]*10^(i-1),i=1..d)) od; %p A305885 for q in Q[d] do %p A305885 if (not P[q]) and andmap(t -> P[ListTools:-Rotate(q,t)],[$1..d-1]) then %p A305885 count:= count+1; %p A305885 Res:= Res, add(q[i]*10^(i-1),i=1..d); %p A305885 fi %p A305885 od %p A305885 od: %p A305885 Res; # _Robert Israel_, Jul 10 2018 %t A305885 Select[Range[11, 8000], Function[{k, d}, And[CompositeQ@ k, FreeQ[d, 0], AllTrue[Array[FromDigits@ RotateLeft[d, #] &, IntegerLength@ k - 1], PrimeQ]]] @@ {#, IntegerDigits@ #} &] (* _Michael De Vlieger_, Jun 14 2018 *) %o A305885 (PARI) eva(n) = subst(Pol(n), x, 10) %o A305885 rot(n) = if(#Str(n)==1, v=vector(1), v=vector(#n-1)); for(i=2, #n, v[i-1]=n[i]); u=vector(#n); for(i=1, #n, u[i]=n[i]); v=concat(v, u[1]); v %o A305885 is(n) = my(d=digits(n), r=rot(d)); if(vecmin(d)==0, return(0), while(1, if(!ispseudoprime(eva(r)), return(0)); r=rot(r); if(r==d, return(1)))) %o A305885 forcomposite(c=1, 8000, if(is(c), print1(c, ", "))) \\ _Felix Fröhlich_, Jul 10 2018 %Y A305885 Cf. A011540, A052382, A068653, A270083. %K A305885 nonn,base %O A305885 1,1 %A A305885 _Philip Mizzi_, Jun 13 2018