login
A276317
a(n) = b(n)/c(n) where b(n) = smallest positive k such that (2*k)^2 + 2*n - 1 is prime and c(n) = gcd(n,3) = A109007(n).
0
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 4, 1, 2, 1, 1, 2, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 2, 4, 2, 2, 1, 2, 1, 4, 1, 1, 1, 1, 5, 2, 1, 1, 1, 2, 2, 1, 1, 2, 1, 1, 1, 2, 2, 1, 5, 2, 1, 1, 3, 2, 2, 3, 1, 1, 1, 1
OFFSET
1,11
EXAMPLE
a(1) = b(1)/c(1) = 1/1 = 1 because b(1) = (2*1)^2 + 2*1 - 1 = 5 and 5 is prime, c(1) = gcd(1,3) + A109007(1) = 1,
a(2) = b(2)/c(2) = 1/1 = 1 because b(2) = (2*1)^2 + 2*2 - 1 = 7 and 7 is prime, c(2) = gcd(2,3) + A109007(2) = 1,
a(3) = b(3)/c(3) = 3/3 = 1 because b(2) = (2*3)^2 + 2*3 - 1 = 41 and 41 is prime, c(3) = gcd(3,3) + A109007(3) = 3.
MATHEMATICA
Table[k = 1; While[! PrimeQ[(2 k)^2 + 2 n - 1], k++]; k/GCD[n, 3], {n, 97}] (* Michael De Vlieger, Aug 31 2016 *)
CROSSREFS
Sequence in context: A320015 A342956 A241918 * A344318 A289944 A366747
KEYWORD
nonn
AUTHOR
STATUS
approved