%I
%S 1,2,6,20,31,14,126,85,36,145,140,122,376,231,162,483,692,600,993,
%T 1188,1106,2440,1080,2814,2586,450,2696,3473,4254,4857,5918,2364,4760,
%U 4818,21192,13116,19284,14855,12158,31032,18174,15068,35700,56846,27367,33716,13736,16746,103292,8541
%N Index of first occurrence of 2n in A031883, or 0 if 2n never occurs in A031883 = first differences of lucky numbers A000959.
%F a(n) = min { k  A031883(k)=2n } = min { k  A000959(k+1)=A000959(k)+2n }.
%e a(1)=1 is the least index i such that A000959(i)+2*1 = A000959(i+1), since A000959(1) = 1 and A000959(2) = 3.
%e a(2)=2 is the least index i such that A000959(i)+2*2 = A000959(i+1), since A000959(2) = 3 and A000959(3) = 7.
%e a(3)=6 is the least index i such that A000959(i)+2*3 = A000959(i+1); indeed A000959(7)  A000959(6) = 21  15 is the earliest gap of 6 in A000959.
%o (PARI) a(n) = for( i=1,1e9, A031883[i]==2*n & return(i)) /* will issue an error if 2n is not found in A031883 */
%Y Cf. A038664 (analog for primes).
%K nonn
%O 1,2
%A _M. F. Hasler_, Oct 31 2010
%E a(20)a(50) from _Nathaniel Johnston_, Nov 15 2010
