OFFSET
1,2
LINKS
Eric Weisstein's World of Mathematics, Brocard's Conjecture.
MAPLE
A050216 := proc(n)
option remember ;
local p, pn ;
if n = 0 then
2;
else
p := ithprime(n) ;
pn := nextprime(p) ;
numtheory[pi](pn^2)-numtheory[pi](p^2) ;
end if;
end proc:
A380136 := proc(n)
option remember ;
if n = 1 then
1;
else
for a from procname(n-1)+1 do
return a ;
end if;
end do:
end if;
end proc:
seq(A380136(n), n=1..30) ; # R. J. Mathar, Jan 27 2025
CROSSREFS
KEYWORD
nonn
AUTHOR
Eric W. Weisstein, Jan 13 2025
STATUS
approved
