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-7 of 7 results.

A057876 Primes p with the following property: let d_1, d_2, ... be the distinct digits occurring in the decimal expansion of p. Then for each d_i, dropping all the digits d_i from p produces a prime number. Leading 0's are not allowed.

Original entry on oeis.org

23, 37, 53, 73, 113, 131, 137, 151, 173, 179, 197, 211, 311, 317, 431, 617, 719, 1531, 1831, 1997, 2113, 2131, 2237, 2273, 2297, 2311, 2797, 3137, 3371, 4337, 4373, 4733, 4919, 6173, 7297, 7331, 7573, 7873, 8191, 8311, 8831, 8837, 12239, 16673, 19531
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Examples

			1531 gives primes 53, 131 and 151 after dropping digits 1, 5 and 3.
A larger example 1210778071 gives primes 12177871, 2077807, 110778071, 1210801 and 121077071 after dropping digits 0, 1, 2, 7 and 8.
		

Crossrefs

Programs

  • Maple
    filter:= proc(n) local L,d,Lp;
      if not isprime(n) then return false fi;
      L:= convert(n,base,10);
      for d in convert(L,set) do
        Lp:= subs(d=NULL,L);
        if Lp=[] or Lp[-1] = 0 then return false fi;
        if not isprime(add(Lp[i]*10^(i-1),i=1..nops(Lp))) then return false fi;
      od;
      true
    end proc:
    select(filter, [seq(i,i=13..20000,2)]); # Robert Israel, Jul 13 2018

Extensions

Name edited by Robert Israel, Jul 13 2018

A057877 a(n) = smallest n-digit prime in A057876.

Original entry on oeis.org

23, 113, 1531, 12239, 111317, 1111219, 11119291, 111111197, 1111113173, 11111133017, 111111189919, 1111111411337, 11111111161177, 111111111263311, 1111111111149119, 11111111111179913, 111111111111118771, 1111111111111751371, 11111111111111111131, 111111111111113129773, 1111111111111111337111
Offset: 2

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Examples

			1531 gives primes 53, 131 and 151 after dropping digits 1, 5 and 3.
		

Crossrefs

Programs

  • Maple
    filter:= proc(n) local L,d,Lp;
      if not isprime(n) then return false fi;
      L:= convert(n,base,10);
      for d in convert(L,set) do
        Lp:= subs(d=NULL,L);
        if Lp=[] or Lp[-1] = 0 then return false fi;
        if not isprime(add(Lp[i]*10^(i-1),i=1..nops(Lp))) then return false fi;
      od;
      true
    end proc:
    Res:= NULL:
    for t from 1 to 21 do
      for x from (10^(t+1)-1)/9 by 2 do
        if filter(x) then Res:= Res, x; break fi
      od
    od:
    Res; # Robert Israel, Jul 13 2018
  • Mathematica
    Do[k = (10^n - 1)/9; While[d = IntegerDigits[k]; !PrimeQ[k] || !PrimeQ[ FromDigits[ DeleteCases[d, 0]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 1]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 2]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 3]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 4]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 5]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 6]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 7]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 8]]] || !PrimeQ[ FromDigits[ DeleteCases[d, 9]]], k++ ]; Print[k], {n, 2, 19}]

Extensions

Extended by Robert G. Wilson v, Dec 17 2002
More terms from Robert Israel, Jul 13 2018

A057880 Primes with 4 distinct digits that remain prime (no leading zeros allowed) after deleting all occurrences of its digits d.

Original entry on oeis.org

6173, 12239, 16673, 19531, 19973, 21613, 22397, 22937, 34613, 36137, 47933, 51193, 54493, 56519, 56531, 56591, 69491, 69497, 72937, 76873, 93497, 96419, 96479, 96497, 98837, 112939, 118213, 131779, 143419, 144497, 159319, 163337
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Crossrefs

Programs

  • Maple
    filter:= proc(L) local d,Lp,i;
          if L[-1]=0 then return false fi;
          if not isprime(add(L[i]*10^(i-1),i=1..nops(L))) then return false fi;
          for d in convert(L,set) do
            Lp:= remove(`=`,L,d);
            if Lp[-1] = 0 or not isprime(add(Lp[i]*10^(i-1),i=1..nops(Lp))) then return false fi;
          od;
          true
    end proc:
    getCands:= proc(n, m) option remember;
       if m = 1 then return [seq([d$n], d=0..9)] fi;
       if n < m then return [] fi;
       [seq(seq([i,op(L)],i= {$0..9} minus convert(L,set)),L = procname(n-1,m-1)),
        seq(seq([i,op(L)],i=convert(L,set)),L = procname(n-1,m))]
    end proc:
    [seq(op(sort(map(t->add(t[i]*10^(i-1),i=1..nops(t)),select(filter,getCands(d,4))))),d=4..6)]; # Robert Israel, Jan 19 2017
  • Mathematica
    p4dQ[n_]:=Module[{idn=IntegerDigits[n]},Count[idn,0]==0 && Count[ DigitCount[ n],0]==6&&AllTrue[FromDigits/@Table[DeleteCases[idn,k],{k,Union[idn]}],PrimeQ]]; Select[Prime[Range[ 15000]],p4dQ] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Sep 30 2017 *)

Extensions

Offset changed by Robert Israel, Jan 19 2017

A057882 Primes with 6 distinct digits that remain prime (no leading zeros allowed) after deleting all occurrences of its digits d.

Original entry on oeis.org

5600239, 21066319, 42209639, 63019679, 82190131, 95422517, 113420491, 114248737, 130194791, 132863191, 135160339, 137697019, 145136591, 145611439, 146414839, 153160517, 159136291, 181680713, 186601339, 186609331, 190714133
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Crossrefs

Extensions

Offset changed by Andrew Howroyd, Aug 14 2024

A057878 Primes with 2 distinct digits that remain prime (no leading zeros allowed) after deleting all occurrences of its digits d.

Original entry on oeis.org

23, 37, 53, 73, 113, 131, 151, 211, 311, 11111111111111111131, 11111111111111117111, 11111111111131111111, 11111111131111111111, 111111111111111111111113, 111111111111111112111111, 111111111111111121111111, 111111111112111111111111, 111111115111111111111111
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Comments

Digits 0, 4, 6, 8, and 9 can never occur; digits 2, 3, 5, 7 can occur at most once in a term; every other digit is a 1. - Sean A. Irvine, Jul 11 2022

Crossrefs

Extensions

More terms from Sean A. Irvine, Jul 11 2022

A057879 Primes with 3 distinct digits that remain prime (no leading zeros allowed) after deleting all occurrences of any one of its distinct digits.

Original entry on oeis.org

137, 173, 179, 197, 317, 431, 617, 719, 1531, 1831, 1997, 2113, 2131, 2237, 2273, 2297, 2311, 2797, 3137, 3371, 4337, 4373, 4733, 4919, 7297, 7331, 7573, 7873, 8191, 8311, 8831, 8837, 33413, 33713, 34313, 37313, 41117, 41999, 44417, 49199, 73331
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Comments

Numbers in A057876 with exactly 3 distinct digits.

Crossrefs

Intersection of A057876 and A235155.

Extensions

Offset changed by Andrew Howroyd, Aug 14 2024

A057881 Primes with 5 distinct digits that remain prime (no leading zeros allowed) after deleting all occurrences of its digits d.

Original entry on oeis.org

37019, 159013, 198013, 210139, 223697, 226397, 236297, 1305593, 1388693, 1393697, 1900937, 1912831, 2370673, 2796337, 2882093, 2930773, 3200191, 3202139, 3346199, 3442693, 3463199, 3463619, 3746399, 3769133, 4234039
Offset: 1

Views

Author

Patrick De Geest, Oct 15 2000

Keywords

Comments

Numbers in A057876 with exactly 5 distinct digits.

Crossrefs

Intersection of A057876 and A235157.

Extensions

Offset changed by Andrew Howroyd, Aug 14 2024
Showing 1-7 of 7 results.