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

A177275 Primes which are a concatenation of some permutation of the first 5 primes.

Original entry on oeis.org

112573, 115237, 115327, 211573, 235117, 257311, 327511, 352711, 357211, 372511, 511237, 511327, 511723, 521137, 521173, 572311, 711523, 725113, 735211, 751123
Offset: 1

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), May 06 2010

Keywords

Comments

There are 20 terms in the sequence. Each is a 6-digit prime with sum of digits equal to 19 = A051351(5).
For each of the 20 entries we define the index i via prime(i) = a(n), which yields the following 20 pairs of (i, A007953(i)):
(10668,21), (10892,20), (10901,11), (18940,22), (20845,19) HP,
(22622,14), (28208,20), (30192,15), (30538,19) HP, (31709,20),
(42386,23), (42392,20), (42426,18), (43145,17), (43149,21),
(47000,11), (57421,19) HP, (58426,25), (59175,27), (60315,15)
Where prime(i) is in A033548, this is marked as "HP" for "Honaker Prime".

Examples

			a(1) = 11//2//5//7//3 = 112573 = prime(10668).
a(5) = 2//3//5//11//7 = 235117 = prime(20845).
a(20) = 7//5//11//2//3 = 751123 = prime(60315).
		

Crossrefs

Programs

  • Maple
    catL := proc(L) local a,i,dgs ; a := op(1,L) ; for i from 2 to nops(L) do dgs := max(1, 1+ilog10(op(i,L))) ; a := a*10^dgs+op(i,L) ; end do: a ; end proc:
    A177275 := proc() local pL,a,c ; pL := [seq(ithprime(c),c=1..5)] ; a := {} ; for c in combinat[permute](pL) do p := catL(c) ; if isprime(p) then a := a union {p} ; end if; end do: print(sort(a)) ; end proc:
    A177275() ; # R. J. Mathar, May 09 2010

Extensions

Added keyword:base,full. Removed the variable p. - R. J. Mathar and Zak Seidov, May 09 2010

A347612 Semiprimes formed from single-digits primes only, each used at most once.

Original entry on oeis.org

25, 35, 57, 235, 237, 253, 327, 527, 537, 573, 723, 753, 2537, 2573, 2735, 5327, 5723, 7235
Offset: 1

Views

Author

Harvey P. Dale, Sep 08 2021

Keywords

Examples

			527 is a semiprime and its non-repeating digits are primes.
		

Crossrefs

Programs

  • Mathematica
    Select[FromDigits/@Flatten[Permutations/@Subsets[ {2,3,5,7}],1],PrimeOmega[ #] == 2&]//Union

A362678 Primes whose digits are prime and in nondecreasing order.

Original entry on oeis.org

2, 3, 5, 7, 23, 37, 223, 227, 233, 257, 277, 337, 557, 577, 2237, 2333, 2357, 2377, 2557, 2777, 3557, 5557, 22277, 22777, 23333, 23357, 23557, 25577, 33377, 33577, 222337, 222557, 223337, 223577, 233357, 233557, 233777, 235577, 333337, 335557, 355777
Offset: 1

Views

Author

James C. McMahon, Jul 03 2023

Keywords

Comments

Intersection of A009994 and A019546.
The subsequence for primes whose digits are prime and in strictly increasing order has just eight terms: 2 3 5 7 23 37 257 2357 (see A177061).

Crossrefs

Programs

  • Maple
    M:= 7: # for terms with <+ M digits
    R:= NULL:
    for d from 1 to M do
      S:= NULL:
      for x2 from 0 to d do
        for x3 from 0 to d-x2 do
          for x5 from 0 to d-x2-x3 do
            x7:= d-x2-x3-x5;
            x:= parse(cat(2$x2,3$x3,5$x5,7$x7));
            if isprime(x) then S:= S,x fi;
        od od od;
        R:= R, op(sort([S]));
    od:
    R;  # Robert Israel, Jul 04 2023
  • Mathematica
    Select[Prime[Range[31000]], AllTrue[d = IntegerDigits[#], PrimeQ] && LessEqual @@ d &] (* Amiram Eldar, Jul 07 2023 *)
  • PARI
    isok(p) = if (isprime(p), my(d=digits(p)); (d == vecsort(d)) && (#select(isprime, d) == #d)); \\ Michel Marcus, Jul 07 2023
  • Python
    from sympy import isprime
    from itertools import count, combinations_with_replacement as cwr, islice
    def agen(): yield from (filter(isprime, (int("".join(c)) for d in count(1) for c in cwr("2357",d))))
    print(list(islice(agen(), 50))) # Michael S. Branicky, Jul 05 2023
    

A364831 Primes whose digits are prime and in nonincreasing order.

Original entry on oeis.org

2, 3, 5, 7, 53, 73, 733, 773, 5333, 7333, 7753, 55333, 75533, 75553, 77773, 733333, 755333, 775553, 7553333, 7555333, 7775533, 7777753, 55555333, 55555553, 77755553, 555553333, 755555533, 773333333, 777555553, 777773333, 777775333, 777775553, 777777773
Offset: 1

Views

Author

James C. McMahon, Aug 09 2023

Keywords

Comments

Intersection of A028867 and A019546.
The subsequence for primes whose digits are prime and in strictly decreasing order has just six terms: 2 3 5 7 53 73 (see A177061).

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[3100000]], AllTrue[d = IntegerDigits[#], PrimeQ] && GreaterEqual @@ d &]
  • Python
    from itertools import count, islice, chain, combinations_with_replacement
    from sympy import isprime
    def A364831_gen(): # generator of terms
        yield 2
        yield from chain.from_iterable((sorted(s for d in combinations_with_replacement('753',l) if isprime(s:=int(''.join(d)))) for l in count(1)))
    A364831_list = list(islice(A364831_gen(),30)) # Chai Wah Wu, Sep 10 2023
Showing 1-4 of 4 results.