OFFSET
1,2
COMMENTS
Except for 1+I, 1-I, -1+I, and -1-I, all Gaussian primes are an odd taxicab distance from the origin. Primes on the x- and y-axis are counted only once. That is, although p and p*I are Gaussian primes (for primes p in A002145), we count only p as being a first-quadrant Gaussian prime.
LINKS
T. D. Noe, Table of n, a(n) for n = 1..10000
MATHEMATICA
Table[cnt = 0; Do[If[PrimeQ[n - i + I*i, GaussianIntegers -> True], cnt++], {i, 0, n}]; Do[If[PrimeQ[i - n + I*i, GaussianIntegers -> True], cnt++], {i, n - 1, 0, -1}]; Do[If[PrimeQ[i - n - I*i, GaussianIntegers -> True], cnt++], {i, 1, n}]; Do[If[PrimeQ[n - i - I*i, GaussianIntegers -> True], cnt++], {i, n - 1, 1, -1}]; cnt, {n, 1, 200, 2}]/4
CROSSREFS
KEYWORD
nonn
AUTHOR
T. D. Noe, May 03 2013
STATUS
approved