login
Lengths of runs of 1's in A039702.
7

%I #9 Sep 21 2012 18:25:08

%S 1,2,1,2,1,1,1,3,2,1,1,1,1,1,2,2,1,1,1,2,1,2,1,2,1,4,1,1,3,2,1,1,1,1,

%T 1,1,2,1,1,3,2,1,4,2,1,1,2,2,3,1,1,3,1,1,1,1,1,2,2,1,1,1,4,1,2,1,1,2,

%U 1,1,2,1,2,1,1,2,2,2,2,1,2,3,2,2,1,1,2,1,2,2,1,2,1,2,1,1,1,2,1,2,2,2,3,3,3

%N Lengths of runs of 1's in A039702.

%C Number of primes congruent to 1 mod 4 in sequence before interruption by a prime 3 mod 4.

%D Enoch Haga, Exploring prime numbers on your PC and the Internet with directions to prime number sites on the Internet, 2001, pages 30-31. ISBN 1-885794-17-7.

%H T. D. Noe, <a href="/A091318/b091318.txt">Table of n, a(n) for n = 1..10000</a>

%F Count primes congruent to 1 mod 4 in sequence before interruption by a prime divided by 4 with remainder 3.

%e a(8)=3 because this is the sequence of primes congruent to 1 mod 4: 89, 97, 101. The next prime is 103, a prime 3 mod 4.

%t t = Length /@ Split[Table[Mod[Prime[n], 4], {n, 2, 400}]]; Most[Transpose[Partition[t, 2]][[2]]] (* _T. D. Noe_, Sep 21 2012 *)

%Y Cf. A002144, A002145, A039702, A091267, A091237.

%K easy,nonn

%O 1,2

%A _Enoch Haga_, Feb 22 2004