%I #12 Jun 21 2014 16:20:04
%S 1,2,4,8,10,16,18,20,26,32,34,36,40,50,52,58,64,68,72,74,80,82,90,98,
%T 100,104,106,116,122,128,130,136,144,146,148,160,162,164,170,178,180,
%U 194,196,200,202,208,212,218,226,232,234,242,244,250,256,260,272,274
%N Sizes of possible gaps around a Gaussian prime: 1 and the even numbers in A001481.
%C For a given Gaussian prime u, the size of its gap is the minimum of norm(u-v) as v varies over all other Gaussian primes, where norm(a+b*i)=a^2+b^2. Only the small Gaussian primes 1+i and 2+i (and their associates and reflections) have gaps of diameter 1.
%H Vincenzo Librandi, <a href="/A128106/b128106.txt">Table of n, a(n) for n = 1..10000</a>
%t q=12; imax=2*q^2; lst=Select[Union[Flatten[Table[2*x^2+2*y^2, {x,0,q}, {y,0,x}]]], #<=imax&]; Join[{1},Drop[lst,1]] (* _Vladimir Joseph Stephan Orlovsky_, Apr 20 2011 *)
%o (Sage)
%o def A128106_list(max):
%o R = []; s = 1; sq = 1
%o for n in (0..max//2):
%o if n == s:
%o sq += 1;
%o s = sq*sq;
%o for k in range(sq):
%o if is_square(n-k*k):
%o R.append(2*n)
%o break
%o R[0] = 1
%o return R
%o A128106_list(274) # _Peter Luschny_, Jun 20 2014
%Y Cf. A128107, A128108, A128109.
%K nonn
%O 1,2
%A _T. D. Noe_, Feb 15 2007
|