|
|
A089129
|
|
Greatest common divisor of n^2 - 7 and n^2 + 7.
|
|
1
|
|
|
7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1, 2, 1, 2, 1, 14, 1, 2, 1, 2, 1, 2, 7, 2, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
a(n) is the product of the periodic sequences [1,2]*[7,1,1,1,1,1,1]. - Gary Detlefs, Apr 22 2011
|
|
LINKS
|
|
|
FORMULA
|
a(n) = gcd(n+7, 14).
a(n) = (6*(1-(n^6 mod 7))+1)*((n mod 2)+1). (End)
|
|
PROG
|
(PARI) g(n, k) = for(x=0, n, print1(gcd(x^k-7, x^k+7)", "))
|
|
CROSSREFS
|
|
|
KEYWORD
|
easy,nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|