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.

Previous Showing 11-20 of 31 results. Next

A038613 Primes not containing the digit '5'.

Original entry on oeis.org

2, 3, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 263, 269, 271, 277, 281, 283, 293, 307, 311
Offset: 1

Views

Author

Vasiliy Danilov (danilovv(AT)usa.net), Jul 15 1998

Keywords

Comments

Subsequence of primes of A052413. - Michel Marcus, Feb 22 2015
Maynard proves that this sequence is infinite and in particular contains the expected number of elements up to x, on the order of x^(log 9/log 10)/log x. - Charles R Greathouse IV, Apr 08 2016

Examples

			From _M. F. Hasler_, Jan 14 2020: (Start)
After a(85) = 499, the next prime without digit 5 is a(86) = 601.
After a(3734) = 49999, the next term is a(3735) = 60013.
After a(27273) = 499979, the next term is 600011.
After a(206276) = 4999999, the next term is 6000011. (End)
		

Crossrefs

Intersection of A000040 (primes) and A052413 (numbers with no digit 5).
Primes having no digit d = 0..9 are A038618, A038603, A038604, A038611, A038612, this sequence, A038614, A038615, A038616, and A038617, respectively.

Programs

  • Magma
    [ p: p in PrimesUpTo(400) | not 5 in Intseq(p) ]; // Bruno Berselli, Aug 08 2011
    
  • Mathematica
    Select[Prime[Range[70]], DigitCount[#, 10, 5] == 0 &] (* Vincenzo Librandi, Aug 08 2011 *)
  • PARI
    lista(nn)=forprime(p=2, nn, if (!vecsearch(vecsort(digits(p),,8), 5), print1(p, ", "));); \\ Michel Marcus, Feb 22 2015
    
  • PARI
    (A038613_upto(n)=select( is_A052413, primes([1, n])))(350) \\ see A052413
    next_A038613(n)={until(isprime(n), n=next_A052413(nextprime(n+1)-1)); n}
    ( {A038613_vec(n, M=1)=M--;vector(n, i, M=next_A038613(M))} )(20, 1000) \\ Compute n terms >= M. See also the OEIS wiki page. - M. F. Hasler, Jan 14 2020

Formula

a(n) ≍ n^(log 10/log 9) log n. - Charles R Greathouse IV, Aug 03 2023

Extensions

Offset corrected by Arkadiusz Wesolowski, Aug 07 2011

A038616 Primes not containing the digit '8'.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 293, 307
Offset: 1

Views

Author

Vasiliy Danilov (danilovv(AT)usa.net), Jul 15 1998

Keywords

Comments

Subsequence of primes of A052421. - Michel Marcus, Feb 22 2015
Maynard proves that this sequence is infinite and in particular contains the expected number of elements up to x, on the order of x^(log 9/log 10)/log x. - Charles R Greathouse IV, Apr 08 2016

Crossrefs

Intersection of A000040 (primes) and A052421 (numbers with no 8).
Primes having no digit d = 0..9 are A038618, A038603, A038604, A038611, A038612, A038613, A038614, A038615, this sequence, and A038617, respectively.

Programs

  • Magma
    [ p: p in PrimesUpTo(400) | not 8 in Intseq(p) ]; // Bruno Berselli, Aug 08 2011
    
  • Mathematica
    Select[Prime[Range[70]], DigitCount[#, 10, 8] == 0 &] (* Harvey P. Dale, Jan 24 2011 *)
  • PARI
    lista(nn)=forprime(p=2, nn, if (!vecsearch(vecsort(digits(p),,8), 8), print1(p, ", "));); \\ Michel Marcus, Feb 22 2015
    
  • PARI
    next_A038616(n)=until((n=nextprime(n+1))==(n=next_A052421(n-1)), ); n \\ M. F. Hasler, Jan 14 2020

Formula

a(n) ~ n^(log 10/log 9) * log(n). - Charles R Greathouse IV, Aug 03 2023

Extensions

Offset corrected by Arkadiusz Wesolowski, Aug 07 2011

A208270 Primes containing a digit 1.

Original entry on oeis.org

11, 13, 17, 19, 31, 41, 61, 71, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 241, 251, 271, 281, 311, 313, 317, 331, 401, 419, 421, 431, 461, 491, 521, 541, 571, 601, 613, 617, 619, 631, 641, 661
Offset: 1

Views

Author

Jaroslav Krizek, Mar 04 2012

Keywords

Comments

Subsequence of A011531, A062634, A092911 and A092912.
Supersequence of A106101, A045707 and A030430.
Complement of A208271 with respect to A011531.

Crossrefs

Cf. A208271 (nonprimes containing a digit 1), A011531 (numbers containing a digit 1).
Complement of A038603 in A000040. - M. F. Hasler, Mar 05 2012

Programs

  • Magma
    [p: p in PrimesUpTo(400) | 1 in Intseq(p)]; // Vincenzo Librandi, Apr 29 2019
  • Mathematica
    Select[Prime[Range[124]], MemberQ[IntegerDigits[#], 1] &](* Jayanta Basu, Apr 01 2013 *)
    Select[Prime[Range[200]],DigitCount[#,10,1]>0&] (* Harvey P. Dale, Dec 15 2020 *)
  • PARI
    forprime(p=2,1e3,s=vecsort(eval(Vec(Str(p))),,8);if(s[1]==1||(s[1]==0&&s[2]==1),print1(p", "))) \\ Charles R Greathouse IV, Mar 04 2012
    
  • PARI
    is_A208270(n)=isprime(n)&setsearch(Set(Vec(Str(n))),1) \\ M. F. Hasler, Mar 05 2012
    

Formula

a(n) ~ n log n since the sequence contains almost all primes. - Charles R Greathouse IV, Mar 04 2012

A106116 Primes without {0, 1} as digits.

Original entry on oeis.org

2, 3, 5, 7, 23, 29, 37, 43, 47, 53, 59, 67, 73, 79, 83, 89, 97, 223, 227, 229, 233, 239, 257, 263, 269, 277, 283, 293, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 433, 439, 443, 449, 457, 463, 467, 479, 487, 499, 523, 547, 557, 563, 569, 577, 587, 593
Offset: 1

Views

Author

Zak Seidov, May 07 2005

Keywords

Crossrefs

Intersection of A038603 and A038618.

Programs

  • Mathematica
    Select[Prime[Range[100]], Min[IntegerDigits[ # ]]>1&]
  • PARI
    is(p)=vecsort(digits(p),,8)[1]>1 && isprime(p) \\ Charles R Greathouse IV, Jan 02 2013

Formula

a(n) >> n^k with k = log 10/log 8 = 1.107.... - Charles R Greathouse IV, Jan 02 2013

Extensions

Terms > 523 added by Jonathan Vos Post, Feb 10 2010

A076805 Triskaidekaphobic or 13-free primes: primes that do not contain the number 13.

Original entry on oeis.org

2, 3, 5, 7, 11, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 127, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307
Offset: 1

Views

Author

Cino Hilliard, Nov 18 2002

Keywords

Examples

			The PARI program will mask out a sequence containing k or mask in a sequence containing k. The program is limited to primes < 400000000.
The PARI program will generate the following for input as shown: kprimes(2,100,7,0) = 2 3 5 11 13 19 23 29 31 41 43 53 59 61 83 89; kprimes(2,1000,13,1) = 13 113 131 137 139 313 613; kprimes(300000,4000000,314159,1) = 314159 3314159 5314159
		

Crossrefs

A generalization of the examples A038603, A038615 etc. for k = 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 by Vasiliy Danilov.
Complement of A166573 with respect to A000040; cf. A011760

Programs

  • Haskell
    import Data.List (isInfixOf)
    a076805 n = a076805_list !! (n-1)
    a076805_list = filter (not . ("13" `isInfixOf`) . show) a000040_list
    -- Reinhard Zumkeller, Nov 09 2011
    
  • Mathematica
    Select[Prime[Range[90]],!MemberQ[Partition[IntegerDigits[#],2,1],{1,3}]&] (* Harvey P. Dale, Mar 25 2012 *)
    Select[Prime[Range[100]],SequenceCount[IntegerDigits[#],{1,3}]==0&] (* Harvey P. Dale, Aug 11 2023 *)
  • PARI
    /* k primes - kprimes.gp. Primes containing or not containing digit k=1,2,3...9,10,11... PARI does not have a good string manipulation capability. This program circumvents that by using the % modulo and floor operators. Also commented out is a log implementation which is slower than string apps. The program either masks out prime numbers k or masks them in.*/
    
  • PARI
    log10(z) = if(z>0,floor(log(z)/log(10))+1,1);\\integer function for log(z) base 10 + 1
    { kprimes(n1,n2,k,t) = \\n1,n2=range,k=mask,t=0 mask out t=1 mask in
    ct=0; pct=0; forprime(p=n1,n2,x=p; f=0;\\x=temp variable to diminish p
    ln = length(Str(p));\\get length of the prime p using strings
    lk = length(Str(k));\\get length of mask integer k using strings
    ln = log10(p);\\get length of the prime p using logs
    lk = log10(k);\\get length of mask integer k using strings
    r = 10^lk; \\set the remainder length = length of k
    for(j=1,ln-lk+1, \\permute through the digits
    d = x % r;\\get lk digits
    if(d==k,f=1; break);\\break for loop if match and set flag
    x = floor(x/10);\\diminish x for next test for k
    ); if(f==t,print1(p" "); ct+=1);\\if no k string of digits,print
    ); print(); print(ct); }
    
  • PARI
    hasNo13(n)=n=digits(n); for(i=2,#n, if(n[i]==3&&n[i-1]==1, return(0))); 1
    select(hasNo13, primes(10^4)) \\ Charles R Greathouse IV, Dec 02 2013
    
  • PARI
    is_A076805(n,t=13)=!until(t>n\=10,t==n%100&&return) \\ M. F. Hasler, Dec 02 2013

Formula

a(n) >> n^1.0044, where the exponent is log(r)/log(10) with r the larger root of x^2 - 10x + 1. [Charles R Greathouse IV, Nov 09 2011]
kfreep(n, k) = true if for primes p over the range n and integer k, p mod 10^(floor(log_10(k))+1) <> k for p = p/10 mod 10^(floor(log_10(k))+1) <> k over the range floor(log_10(k))+1. This is a mathematical definition of the recurrence. In practice it is convenient to use string operations. E.g., If Not Instr(Str(p), Str(k)) then true or k is not a substring of p so list p.

Extensions

Original PARI code restored by M. F. Hasler, Dec 02 2013

A132080 Numbers having in decimal representation no common digits with all their proper divisors.

Original entry on oeis.org

2, 3, 4, 5, 6, 7, 8, 9, 23, 27, 29, 34, 37, 38, 43, 46, 47, 49, 53, 54, 56, 57, 58, 59, 67, 68, 69, 73, 76, 78, 79, 83, 86, 87, 89, 97, 223, 227, 229, 233, 239, 247, 249, 257, 259, 263, 267, 269, 277, 283, 289, 293, 307, 323, 329, 334, 337, 347, 349, 353, 356, 358, 359
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 09 2007

Keywords

Comments

A038603 is a subsequence.

Examples

			Proper divisors of a(20)=54: {1, 2, 3, 6, 9, 18, 27}
with set of digits {1,2,3,6,7,8,9} containing neither 4 nor 5.
		

Crossrefs

Subsequence of A052383.

Programs

  • Haskell
    import Data.List (intersect)
    a132080 n = a132080_list !! (n-1)
    a132080_list = [x | x <- [2..], all null $
                        map (show x `intersect`) $ map show $ a027751_row x]
    -- Reinhard Zumkeller, Oct 06 2012
    
  • Mathematica
    Select[Range[2,359],ContainsNone[IntegerDigits[#],IntegerDigits/@Drop[Divisors[#],-1]//Flatten]&] (* James C. McMahon, Mar 03 2025 *)
  • PARI
    is(n)=my(D=Set(digits(n))); fordiv(n,d, if(#setintersect(D, Set(digits(d))), return(d==n&&n>1))) \\ Charles R Greathouse IV, Dec 01 2013

A224319 Primes without "1" as a digit that remain prime when any single digit is replaced with "1".

Original entry on oeis.org

37, 43, 47, 67, 73, 79, 337, 409, 439, 499, 607, 709, 3637, 3709, 4877, 6997, 7487, 9433, 76963, 334777
Offset: 1

Views

Author

Arkadiusz Wesolowski, Apr 03 2013

Keywords

Comments

No more terms < 10^13.

Crossrefs

Cf. A224320-A224322. Subsequence of A038603.

Programs

  • Mathematica
    lst = {}; n = 1; Do[If[PrimeQ[p], i = IntegerDigits[p]; If[FreeQ[i, n], t = 0; s = IntegerLength[p]; Do[If[PrimeQ@FromDigits@Insert[Drop[i, {d}], n, d], t++, Break[]], {d, s}]; If[t == s, AppendTo[lst, p]]]], {p, 334777}]; lst

A084368 Numbers k such that prime(k) does not contain the digit 1.

Original entry on oeis.org

1, 2, 3, 4, 9, 10, 12, 14, 15, 16, 17, 19, 21, 22, 23, 24, 25, 48, 49, 50, 51, 52, 55, 56, 57, 59, 61, 62, 63, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 80, 84, 85, 86, 87, 88, 90, 91, 92, 93, 95, 96, 97, 99, 101, 102, 103, 104, 106, 107, 108, 109, 111, 117, 118, 119, 120
Offset: 1

Views

Author

Zak Seidov, Jun 23 2003

Keywords

Examples

			99 is a term because prime(99) = 523 is unit-free.
		

Crossrefs

Programs

  • Mathematica
    Select[ Range[120], Count[ IntegerDigits[ Prime[ # ]], 1] == 0 & ]
    Select[Range[120],DigitCount[Prime[#],10,1]==0&] (* Harvey P. Dale, Jun 20 2023 *)

Extensions

Edited and extended by Robert G. Wilson v, Jun 24 2003

A104421 Numbers n such that n, prime(n), prime(n)+n, prime(n)-n and prime(n)*n all numbers without the digit 1.

Original entry on oeis.org

74, 75, 80, 86, 87, 95, 96, 350, 352, 354, 355, 357, 360, 364, 376, 536, 557, 564, 583, 584, 590, 592, 593, 594, 596, 599, 600, 623, 635, 639, 656, 659, 660, 665, 667, 674, 677, 678, 699, 700, 703, 706, 707, 724, 728, 734, 744, 750, 759, 762, 765, 766, 770
Offset: 1

Views

Author

Zak Seidov, Mar 07 2005

Keywords

Comments

The graph is of quasi-piecewise linear character.
Any other reasonable function(s) of p and m not having digit 1?
Subsequence of A084368: a(1) = 75 = A084368(36), a(100) = 2744 = A084368(898). - Zak Seidov, Dec 04 2013

Examples

			For n = 74, p = prime(74) = 373, p + n = 447, p - n = 299, p*n = 27602.
For n = 256709, p = prime(256709) = 3599737, p + n = 3856446, p - n = 3343028, p*n = 924084885533.
		

Crossrefs

Programs

  • Mathematica
    id[x_]:=IntegerDigits[x]; pr[i_]:=Prime[i]; ra=Range[3000]; A104421=Select[ra, Position[Union[id[ # ], id[pr[ # ]], id[pr[ # ]+# ], id[pr[ # ]-# ], id[pr[ # ]*# ]], 1]=={}&]
    prQ[n_]:=With[{p=Prime[n]},AllTrue[IntegerDigits/@{n,p,p+n,p-n,p*n},FreeQ[#,1]&]]; Select[Range[1000],prQ] (* Harvey P. Dale, Aug 29 2025 *)

A111488 Primes having only {0, 1, 3, 6} as digits.

Original entry on oeis.org

3, 11, 13, 31, 61, 101, 103, 113, 131, 163, 311, 313, 331, 601, 613, 631, 661, 1013, 1031, 1033, 1061, 1063, 1103, 1163, 1301, 1303, 1361, 1601, 1613, 1663, 3001, 3011, 3061, 3163, 3301, 3313, 3331, 3361, 3613, 3631, 6011, 6101, 6113, 6131, 6133, 6163
Offset: 1

Views

Author

Jonathan Vos Post, Nov 15 2005

Keywords

Comments

Includes all repunit primes (A004022). Conjecture: an infinite sequence. Note twin primes: (11, 13), (101, 103), (311, 313), (1031, 1033), (1061, 1063), (1301, 1303), (6131, 6133), (10301, 10303), (10331, 10333), (13001, 13003).
In other words, primes with digits in the set {0,1,3,6}. - M. F. Hasler, Jul 25 2015
The number of 1's in the representation must be either 1 or 2 (mod 3), because otherwise the number would be divisible by 3 (and therefore composite). The only exception is the 3 itself. This excludes basically members of A038603. - R. J. Mathar, Jul 25 2015

Crossrefs

Programs

  • Maple
    f:= proc(x) local L,p;
      L:= subs([3=6,2=3],convert(x,base,4));
      p:= add(L[i]*10^(i-1),i=1..nops(L));
      if isprime(p) then p fi
    end proc:
    map(f, [$1..4^4]); # Robert Israel, Dec 18 2018
  • Mathematica
    Select[Prime@ Range@ 1000, SubsetQ[{0, 1, 3, 6}, IntegerDigits@ #] &] (* Michael De Vlieger, Jul 25 2015 *)
  • PARI
    A111488={(n, show=0, L=[0,1,3,6])->my(t); for(d=1,1e9,u=vector(d, i, 10^(d-i))~; forvec(v=vector(d,i,[1+(i==1&&!L[1]), #L]), ispseudoprime(t=vector(d, i, L[v[i]])*u)||next; show&print1(t", "); n--||return(t)))} \\ M. F. Hasler, Jul 25 2015

Extensions

Corrected by Ray Chandler, Nov 19 2005
Name changed by Sean A. Irvine, Jul 21 2025
Previous Showing 11-20 of 31 results. Next