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.

A269850 a(n) = number of integers k <= n for which prime(k+1)-prime(k) is a multiple of three.

This page as a plain text file.
%I A269850 #12 Mar 20 2016 12:54:51
%S A269850 0,0,0,0,0,0,0,0,1,1,2,2,2,2,3,4,4,5,5,5,6,6,7,7,7,7,7,7,7,7,7,8,8,8,
%T A269850 8,9,10,10,11,12,12,12,12,12,12,13,14,14,14,14,15,15,15,16,17,18,18,
%U A269850 19,19,19,19,19,19,19,19,19,20,20,20,20,21,21,22,23,23,24,24,24,24,24,24,24,24,25,25,26,26,26,26,26,27
%N A269850 a(n) = number of integers k <= n for which prime(k+1)-prime(k) is a multiple of three.
%C A269850 a(n) = number of terms of A270190 <= n, the least monotonic left inverse of A270190.
%C A269850 See comments at A269364.
%H A269850 Antti Karttunen, <a href="/A269850/b269850.txt">Table of n, a(n) for n = 1..10000</a>
%H A269850 Terence Tao, <a href="https://terrytao.wordpress.com/2016/03/14/biases-between-consecutive-primes/">Biases between consecutive primes</a>, blog entry March 14, 2016
%F A269850 Other identities. For all n >= 1:
%F A269850 a(A270190(n)) = n.
%t A269850 Table[Count[Select[Range@ 125, Divisible[Prime[# + 1] - Prime@ #, 3] &], k_ /; k <= n], {n, 91}] (* _Michael De Vlieger_, Mar 17 2016 *)
%o A269850 (Scheme, with _Antti Karttunen_'s IntSeq-library)
%o A269850 (define A269850 (LEFTINV-LEASTMONO 1 1 A270190))
%o A269850 (PARI) a(n) = sum(k=1, n, ((prime(k+1) - prime(k)) % 3) == 0); \\ _Michel Marcus_, Mar 18 2016
%Y A269850 Cf. A270190, A269849, A269364.
%K A269850 nonn
%O A269850 1,11
%A A269850 _Antti Karttunen_, Mar 16 2016