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.

A129870 Difference between the (10^n)-th and the (10^n-1)-th prime.

This page as a plain text file.
%I A129870 #23 Sep 19 2018 04:04:54
%S A129870 6,18,12,6,20,6,2,4,12,12,20,12,22,26,30,6,72,152,72,24,30,96,124,50
%N A129870 Difference between the (10^n)-th and the (10^n-1)-th prime.
%C A129870 It is interesting that the number 2 occurs deep into the sequence indicating a twin prime pair. It is reasonable to ask if this will ever occur again. Similarly, the analogous sequence A074383, "Difference between (1+10^n)-th and (10^n)-th primes" has 2 occurring shallow into the sequence. It is reasonable to ask if the number 2 will ever occur again in that sequence. The link provides an excellent algorithm, primex(n), that I developed to find the n-th prime using Gram's approximation of Riemann's approximation R(x) for Pi(x). Primex(n) will give about n/2 exact digits for prime(n). For A006988 (18), primex(18) is 44211790234127235469.62904554...This is only as good as R (x) but nevertheless is superior to the exact formulas out there from a practical stand point. If we apply the code gpx(n) = for(x=1,n,y=nextprime(primex(10^x))-nextprime (primex(10^x-1));print1(floor(y)",")), we will get the erratic concoction 2,0,8,14,22,28,26,0,72,18,22,0,0,0,0,0,32,0,80,78,60,0 as an analytical counterpart of the sequence given.
%H A129870 C. Hilliard, <a href="http://groups.msn.com/NthprimeAlgorithms/nthprimeapproximation.msnw">Nth prime approx</a> [broken link].
%F A129870 a(n) = A006988(n)-A151799(A006988(n))
%e A129870 The (10^18)-th prime or A006988(18) = 44211790234832169331.
%e A129870 Using PARI, precprime(A006988(18)-1) = 44211790234832169179.
%e A129870 The difference is a(18) = 152.
%Y A129870 Cf. A006988, A074383.
%K A129870 nonn,more
%O A129870 1,1
%A A129870 _Cino Hilliard_, Jun 04 2007
%E A129870 a(19) from _Max Alekseyev_, May 13 2009
%E A129870 a(20) from _Max Alekseyev_, May 30 2013
%E A129870 a(21),a(22) from _Max Alekseyev_, Dec 04 2014
%E A129870 a(23)-a(24) from _Chai Wah Wu_ using terms in A006988, Sep 18 2018