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.

A049852 Concatenate "n" and "nextprime(n)".

Original entry on oeis.org

12, 23, 35, 45, 57, 67, 711, 811, 911, 1011, 1113, 1213, 1317, 1417, 1517, 1617, 1719, 1819, 1923, 2023, 2123, 2223, 2329, 2429, 2529, 2629, 2729, 2829, 2931, 3031, 3137, 3237, 3337, 3437, 3537, 3637, 3741, 3841, 3941, 4041, 4143, 4243
Offset: 1

Views

Author

Keywords

Comments

From Petros Hadjicostas, Nov 20 2019: (Start)
Version 1 of the "next prime" function is A007918: smallest prime >= n. PARI/GP's nextprime() is version 1.
Maple's nextprime() is the version 2 that appears in A151800: smallest prime > n. We use version 2 here. (End)

Examples

			From _Petros Hadjicostas_, Nov 20 2019: (Start)
a(1) = 12 because nextprime(1) = 2.
a(2) = 23 because nextprime(2) = 3.
a(3) = 35 because nextprime(3) = 5.
a(4) = 45 because nextprime(4) = 5.
...
a(10) = 1011 because nextprime(10) = 11.
a(11) = 1113 because nextprime(11) = 13.
... (End)
		

Crossrefs

Cf. A007918 (version 1 of nextprime), A151800 (version 2 of nextprime).

Programs

  • Maple
    a:= n-> parse(cat(n, nextprime(n))):
    seq(a(n), n=1..50);  # Alois P. Heinz, Nov 20 2019
  • PARI
    a(n) = eval(concat(Str(n), Str(nextprime(n+1)))); \\ Michel Marcus, Jan 01 2017