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

A050719 Inserting a digit '9' between adjacent digits of n makes a prime.

Original entry on oeis.org

11, 13, 17, 19, 23, 37, 41, 49, 53, 59, 61, 77, 91, 97, 131, 157, 167, 169, 173, 181, 191, 193, 197, 211, 227, 239, 259, 307, 311, 319, 323, 337, 349, 371, 379, 413, 419, 427, 431, 433, 449, 457, 467, 481, 491, 493, 499, 503, 517, 533, 539, 547, 563, 569, 571
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			181 becomes 1(9)8(9)1 which is prime 19891.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,1000],PrimeQ[FromDigits[Riffle[IntegerDigits[#],9]]]&] (* Harvey P. Dale, Oct 29 2014 *)

Extensions

Offset changed to 1 by Georg Fischer, Oct 15 2019

A050674 Inserting a digit '0' between adjacent digits of n makes a prime.

Original entry on oeis.org

11, 13, 17, 19, 37, 41, 49, 53, 59, 61, 67, 71, 79, 89, 97, 107, 109, 113, 131, 133, 151, 161, 167, 179, 193, 199, 211, 217, 221, 247, 257, 259, 277, 287, 289, 293, 313, 319, 323, 337, 343, 359, 373, 377, 383, 389, 409, 457, 469, 479, 481, 493, 511, 527, 553
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			373 becomes 3(0)7(0)3 which is prime 30703.
		

Crossrefs

Programs

  • Mathematica
    (* This program works in Mathematica 6.0 and later *)
    Select[Range[11, 1000,2], PrimeQ[FromDigits[Riffle[IntegerDigits[#], 0]]] &] (* T. D. Noe, Dec 22 2010 *)
    (* The following program has been tested in Mathematica 5.1 and it works *)
    Reap[c = 0; d = 0; Do[If[MemberQ[{1, 3, 7, 9}, Mod[n, 10]], id = IntegerDigits[n]; Do[id[[k]] = {id[[k]], d}, {k, Length[id] - 1}]; If[PrimeQ[FromDigits[Flatten[id]]], Sow[n]; c++; If[c > 999, Break[]]]], {n, 11, 20000}]][[2,1]] (* Zak Seidov, Dec 22 2010 *)

Extensions

Offset set to 1 by Georg Fischer, Oct 15 2019

A050711 Inserting a digit '1' between adjacent digits of n makes a prime.

Original entry on oeis.org

13, 21, 31, 33, 37, 49, 63, 67, 69, 79, 81, 91, 99, 113, 117, 119, 123, 131, 137, 141, 159, 167, 177, 179, 183, 201, 203, 207, 209, 221, 233, 237, 239, 249, 257, 261, 263, 267, 273, 287, 291, 303, 309, 329, 339, 351, 353, 357, 387, 401, 407, 413, 417, 423
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			303 becomes 3(1)0(1)3 which is prime 31013.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,500],PrimeQ[FromDigits[Riffle[IntegerDigits[#],1]]]&] (* Harvey P. Dale, Apr 25 2019 *)
  • PARI
    is(n) = if(gcd(10, n%10) > 1 || n < 10, return(0)); my(d = digits(n), v = vector(2*#d - 1, i, if(i % 2 == 1, d[i>>1 + 1], 1))); isprime(fromdigits(v)) \\ David A. Corneth, Oct 15 2019

Extensions

Offset set to 1 by Georg Fischer, Oct 15 2019

A050712 Inserting a digit '2' between adjacent digits of n makes a prime.

Original entry on oeis.org

17, 23, 27, 29, 41, 51, 53, 77, 81, 83, 87, 89, 99, 127, 133, 139, 141, 157, 171, 181, 183, 189, 193, 207, 213, 219, 229, 261, 271, 277, 291, 307, 309, 331, 333, 337, 343, 349, 361, 403, 421, 423, 427, 433, 477, 481, 489, 493, 499, 501, 507, 511, 517, 523
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			333 becomes 3(2)3(2)3 which is prime 32323.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,600],PrimeQ[FromDigits[Riffle[IntegerDigits[#],2]]]&] (* Harvey P. Dale, Sep 13 2014 *)

Extensions

Offset changed to 1 by Georg Fischer, Oct 15 2019

A050713 Inserting a digit '3' between adjacent digits of n makes a prime.

Original entry on oeis.org

11, 17, 19, 23, 29, 31, 37, 41, 43, 49, 61, 73, 79, 89, 97, 103, 107, 131, 137, 139, 157, 163, 181, 191, 193, 209, 211, 233, 239, 241, 251, 257, 259, 263, 281, 283, 307, 331, 353, 367, 379, 391, 397, 407, 413, 427, 431, 463, 493, 521, 523, 529, 547, 563, 569
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			407 becomes 4(3)0(3)7 which is prime 43037.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,600],PrimeQ[FromDigits[Riffle[IntegerDigits[#],3]]]&] (* Harvey P. Dale, Dec 23 2023 *)

A050714 Inserting a digit '4' between adjacent digits of n makes a prime.

Original entry on oeis.org

19, 21, 37, 39, 43, 49, 51, 57, 61, 63, 67, 73, 91, 97, 113, 119, 123, 129, 131, 137, 147, 149, 153, 159, 171, 177, 183, 197, 203, 209, 227, 243, 257, 279, 281, 287, 293, 311, 317, 353, 359, 369, 377, 381, 383, 387, 389, 399, 401, 429, 449, 453, 459, 461, 467
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			389 becomes 3(4)8(4)9 which is prime 34849.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,500],PrimeQ[FromDigits[Riffle[IntegerDigits[#],4]]]&] (* Harvey P. Dale, Nov 03 2024 *)

A050717 Inserting a digit '7' between adjacent digits of n makes a prime.

Original entry on oeis.org

13, 19, 21, 27, 33, 39, 49, 51, 57, 63, 67, 73, 87, 91, 97, 107, 137, 141, 147, 153, 159, 191, 197, 203, 207, 219, 221, 227, 249, 263, 273, 279, 311, 323, 327, 339, 351, 353, 359, 381, 389, 429, 477, 479, 497, 503, 507, 513, 519, 521, 533, 551, 569, 573, 593
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			E.g. 477 becomes 4(7)7(7)7 which is prime 47777.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10, 500], PrimeQ[FromDigits[Riffle[IntegerDigits[#], 7]]]&] (* Georg Fischer, Oct 15 2019 after Harvey P. Dale *)

Extensions

Offset changed to 1 by Georg Fischer, Oct 15 2019

A050715 Inserting a digit '5' between adjacent digits of n makes a prime.

Original entry on oeis.org

11, 17, 21, 27, 33, 39, 47, 57, 63, 69, 71, 77, 83, 87, 89, 93, 103, 129, 139, 141, 151, 159, 189, 199, 207, 213, 223, 237, 243, 247, 267, 279, 291, 301, 303, 309, 313, 319, 321, 327, 333, 373, 379, 381, 391, 403, 429, 453, 457, 469, 471, 477, 483, 493, 499
Offset: 1

Views

Author

Patrick De Geest, Aug 15 1999

Keywords

Examples

			373 becomes 3(5)7(5)3 which is prime 35753.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,500],PrimeQ[FromDigits[Riffle[IntegerDigits[#],5]]]&] (* Harvey P. Dale, Apr 07 2018 *)

Extensions

Offset changed to 1 by Georg Fischer, Oct 15 2019

A331116 Inserting a digit '1' between the first two adjacent digits of k, then inserting a digit '2' between the two following adjacent digits of k, ..., then inserting the integer '10' between the tenth and the eleventh digits of k, ... produces a prime number.

Original entry on oeis.org

13, 21, 31, 33, 37, 49, 63, 67, 69, 79, 81, 91, 99, 107, 131, 139, 143, 157, 161, 181, 187, 193, 197, 203, 211, 221, 227, 233, 251, 253, 259, 277, 281, 299, 311, 313, 323, 331, 337, 367, 371, 373, 377, 379, 403, 421, 427, 451, 461, 467, 479
Offset: 1

Views

Author

Bernard Schott, Jan 10 2020

Keywords

Comments

Inspired by the sequences A050711 to A050719, so the first 13 terms are the first 13 terms of A050711, then a(14) = 107 because 1(1)0(2)7 gives 11027 which is a prime.

Examples

			281 gives 2(1)8(2)1 = 21821 that is prime, hence 281 is a term.
1027 gives 1(1)0(2)2(3)7 = 1102237 that is prime, hence 1027 is another term.
		

Crossrefs

Programs

  • Mathematica
    seqQ[n_] := PrimeQ @ FromDigits @ Flatten @ IntegerDigits @ Riffle[(d = IntegerDigits[n]), Range[Length[d] - 1]]; Select[Range[10,480], seqQ] (* Amiram Eldar, Jan 10 2020 *)
  • Python
    from sympy import isprime
    def ok(n):
        if n < 10: return False
        s = str(n)
        shuffle = list(map(str, ((i+1)//2 for i in range(2*len(s)-1))))
        shuffle[0::2] = [s[i] for i in range(len(s))]
        return isprime(int("".join(shuffle)))
    print(list(filter(ok, range(480)))) # Michael S. Branicky, Jul 18 2021
Showing 1-9 of 9 results.