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.

Showing 1-3 of 3 results.

A225235 Emirps whose internal digits are also an emirp.

Original entry on oeis.org

1979, 3319, 3371, 3373, 3719, 3733, 7177, 7717, 9133, 9173, 9791, 10177, 10711, 10739, 11071, 11497, 11579, 11677, 13477, 13591, 13597, 17011, 17393, 17519, 19531, 19913, 30139, 30319, 30971, 31139, 31799, 31991, 37619, 39371, 39419, 39839, 70313, 70373, 70717
Offset: 1

Views

Author

Keywords

Comments

This sequence (like the emirps) experiences large gaps when the most-significant-digit is {2,4,5,6,8}.

Examples

			7177 and 10177 are in the sequence because both are emirps, and both become the emirp 17 upon deletion of their first and last digits.
		

Crossrefs

Programs

  • R
    library(gmp); isemirp<-function(x) isprime(x) & (j=paste(rev(unlist(strsplit(as.character(x), split=""))), collapse=""))!=x & isprime(j);
    no0<-function(s){ while(substr(s,1,1)=="0" & nchar(s)>1) s=substr(s,2,nchar(s)); s};
    i=as.bigz(0); y=as.bigz(rep(0, 100)); len=0;
    while(len<100) if(isemirp((i=nextprime(i)))) if(isemirp(as.bigz(no0(substr(i,2,nchar(as.character(i))-1))))) y[(len=len+1)]=i;
    as.vector(y)

A214847 Primes that become emirps when their most-significant-digit is deleted.

Original entry on oeis.org

113, 131, 137, 173, 179, 197, 271, 313, 317, 331, 337, 373, 379, 397, 431, 479, 571, 613, 617, 631, 673, 773, 797, 937, 971, 997, 1013, 1031, 1097, 1709, 1733, 1907, 2017, 2113, 2179, 2311, 2347, 2389, 2953, 2971, 3037, 3079, 3167, 3347, 3359, 3389, 3701, 3709
Offset: 1

Views

Author

Keywords

Examples

			113 and 1013 are both in the sequence, because upon deletion they become 13, which is an emirp.
		

Crossrefs

Programs

  • R
    library(gmp); isemirp<-function(x) isprime(x) & (j=paste(rev(unlist(strsplit(as.character(x),split=""))),collapse=""))!=x & isprime(j);
    no0<-function(s){ while(substr(s,1,1)=="0" & nchar(s)>1) s=substr(s,2,nchar(s)); s}
    i=as.bigz(0); y=as.bigz(rep(0,100)); len=0;
    while(len<100)
    if(isemirp(as.bigz(no0(substr((i=nextprime(i)),2,200)))))
    y[(len=len+1)]=i

A225234 Primes whose internal digits are an emirp.

Original entry on oeis.org

1171, 1319, 1373, 1733, 1973, 1979, 2131, 2137, 2179, 2311, 2371, 2377, 2711, 2713, 2719, 2731, 2791, 2797, 2971, 3137, 3313, 3319, 3371, 3373, 3719, 3733, 3739, 3793, 3797, 4133, 4139, 4177, 4373, 4733, 4793, 4799, 4973, 5171, 5179, 5711, 5717, 5737, 5791
Offset: 1

Views

Author

Keywords

Comments

a(414) = 112019 is the first term with an internal even digit.

Examples

			Example: 1171 has the emirp 17 as its internal digits.
		

Crossrefs

Programs

  • R
    library(gmp); isemirp<-function(x) isprime(x) & (j=paste(rev(unlist(strsplit(as.character(x),split=""))),collapse=""))!=x & isprime(j);
    no0<-function(s){ while(substr(s,1,1)=="0" & nchar(s)>1) s=substr(s,2,nchar(s)); s}
    i=as.bigz(0); y=as.bigz(rep(0,100)); len=0;
    while(len<100) if(isemirp(as.bigz(no0(substr((i=nextprime(i)),2,nchar(as.character(i))-1))))) y[(len=len+1)]=i
Showing 1-3 of 3 results.