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.

A244282 Consider a prime number p with m decimal digits. The sequence lists the primes p such that the prefix of length m-1 and the suffix of length m-1 are both prime numbers.

Original entry on oeis.org

23, 37, 53, 73, 113, 131, 137, 173, 179, 197, 311, 313, 317, 373, 379, 419, 431, 479, 613, 617, 619, 673, 719, 797, 971, 1013, 1019, 1031, 1097, 1277, 1373, 1499, 1571, 1733, 1811, 1997, 2113, 2239, 2293, 2719, 3079, 3137, 3313, 3373, 3491, 3499, 3593, 3673, 3677, 3733
Offset: 1

Views

Author

Michel Lagneau, Jun 25 2014

Keywords

Comments

Let x(0)x(1)... x(q-1)x(q) denote the decimal expansion of a prime p. The sequence lists the primes p such that the prefix x(0)x(1)... x(q-1) and the suffix x(1)... x(q-1)x(q) are primes.
Superset of A051362; a(n) first differs from A051362 when n=12.

Examples

			The prime number 179 is in the sequence because 17 and 79 are primes.
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    for m from 1 to 200 do:
          n:=ithprime(m):x:=convert(n, base, 10):n1:=nops(x):
          s1:=sum('x[i]*10^(i-1) ', 'i'=1..n1-1):
          s2:=(n-irem(n,10))/10:
          if type(s1,prime)=true and type(s2,prime)=true
          then
            printf(`%d, `, n):
            else
          fi:
    od:
  • Mathematica
    Select[Prime[Range[1000]], (id = IntegerDigits[#]; PrimeQ[FromDigits[Take[id, {1, -2}]]] && PrimeQ[FromDigits[Take[id, {2, -1}]]]) &] (* César Eliud Lozada, Mar 31 2024 *)
    Select[Prime[Range[600]],With[{idp=IntegerDigits[#]},AllTrue[FromDigits/@{Rest[idp],Most[idp]},PrimeQ]]&] (* Harvey P. Dale, Feb 06 2025 *)

Extensions

Inserted missing term a(49) and corrected a(50) by Paolo P. Lava, Dec 04 2017