login
A344860
Numbers k such that A306920(k) contains the digit 0 and A306920(k+1) is not A306920(k) with a digit 0 removed.
1
192, 238, 250, 293, 312, 346, 382, 432, 436, 446, 465, 510, 544, 554, 560, 571, 578, 583, 593, 607, 609, 631, 658, 671, 727, 729, 771, 780, 803, 812, 825, 844, 845, 848, 860, 866, 877, 883, 894, 917, 945, 962, 967, 974, 991, 1000, 1004, 1031, 1042, 1052, 1061
OFFSET
1,1
EXAMPLE
A306920(192) = 1021, containing the digit 0, A306920(193) = 1039 and 1039 cannot be obtained by removing a 0 digit from 1021, so 192 is a term of the sequence.
PROG
(PARI) eva(n) = subst(Pol(n), x, 10)
insert(n, len, pos) = my(d=digits(n), v=[], w=[]); for(y=1, pos, v=concat(v, d[y])); v=concat(v, vector(len)); for(z=pos+1, #d, v=concat(v, d[z])); eva(v)
a306920(n) = forprime(p=10, , for(k=1, #digits(p)-1, my(zins=insert(p, n, k)); if(ispseudoprime(zins), return(p))))
remove_zeros(n) = my(v=[], w=[], d=digits(n)); for(x=1, #d, if(d[x]==0, for(y=1, x-1, w=concat(w, d[y])); for(z=x+1, #d, w=concat(w, d[z]))); if(#w > 0, v=concat(v, [eva(w)])); w=[]); vecsort(v, , 8)
is(n) = my(x=a306920(n), y=a306920(n+1), rz=remove_zeros(x)); if(#setintersect([0], vecsort(digits(x)))==0, return(0)); for(k=1, #rz, if(y==rz[k], return(0))); 1
CROSSREFS
Sequence in context: A190892 A039667 A273890 * A045077 A234135 A030632
KEYWORD
nonn,base
AUTHOR
Felix Fröhlich, May 31 2021
STATUS
approved