1,1

This sequence is consists of the prime numbers in A158923, in which A158923(m) is the sum of the previous term A158923(m-1) and the average prime gap log(A158923(m-1)) rounded to the nearest integer with A158923(1) = 2.

Table of n, a(n) for n=1..49.

(Python)

from sympy import isprime

from math import log

print(2)

a_last = p_last = m = 2

n = 1

while m >= 2:

a = a_last + int(log(a_last) + 0.5)

if isprime(a) == 1:

print(a)

n += 1

a_last = a

m += 1

Cf. A000040, A158923.

Sequence in context: A020616 A275272 A329954 * A067910 A171574 A280937

Adjacent sequences: A338393 A338394 A338395 * A338397 A338398 A338399

nonn

Ya-Ping Lu, Oct 23 2020

approved