|
|
A249859
|
|
Least common multiple of n + 2 and n - 2.
|
|
4
|
|
|
3, 0, 5, 6, 21, 8, 45, 30, 77, 24, 117, 70, 165, 48, 221, 126, 285, 80, 357, 198, 437, 120, 525, 286, 621, 168, 725, 390, 837, 224, 957, 510, 1085, 288, 1221, 646, 1365, 360, 1517, 798, 1677, 440, 1845, 966, 2021, 528, 2205, 1150, 2397, 624, 2597, 1350, 2805
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
The recurrence for the general case lcm(n+k, n-k) is a(n) = 3*a(n-2*k) - 3*a(n-4*k) + a(n-6*k) for n > 6*k.
|
|
LINKS
|
Index entries for linear recurrences with constant coefficients, signature (0,0,0,3,0,0,0,-3,0,0,0,1).
|
|
FORMULA
|
a(n) = lcm(n - 2, n + 2).
a(n) = 3*a(n-4) - 3*a(n-8) + a(n-12) for n > 12.
G.f.: x*(-6*x^12 - 2*x^11 - 3*x^10 + 23*x^8 + 12*x^7 + 30*x^6 + 8*x^5 + 12*x^4 + 6*x^3 + 5*x^2 + 3) / (-x^12 + 3*x^8 - 3*x^4 + 1).
For n >= 2, a(n) = (n^2 - 4)/b(n), where b(n), n >= 1, is the periodic sequence [1, 4, 1, 2, 1, 4, 1, 2, ...] of period 4. a(n) is thus a quasi-polynomial in n.
For n >= 3, a(n) = (n + 2)*A060819(n-2). (End)
|
|
EXAMPLE
|
a(8) = 30 because lcm(8 + 2, 8 - 2) = lcm(6, 10) = 30.
|
|
MAPLE
|
|
|
MATHEMATICA
|
CoefficientList[Series[(-6 x^12 - 2 x^11 - 3 x^10 + 23 x^8 + 12 x^7 + 30 x^6 + 8 x^5 + 12 x^4 + 6 x^3 + 5 x^2 + 3) / (-x^12 + 3 x^8 - 3 x^4 + 1), {x, 0, 40}], x] (* Vincenzo Librandi, Nov 10 2014 *)
LinearRecurrence[{0, 0, 0, 3, 0, 0, 0, -3, 0, 0, 0, 1}, {3, 0, 5, 6, 21, 8, 45, 30, 77, 24, 117, 70, 165}, 60] (* Harvey P. Dale, Jul 11 2017 *)
|
|
PROG
|
(PARI) a(n) = lcm(n+2, n-2)
(PARI) Vec(x*(-6*x^12 -2*x^11 -3*x^10 +23*x^8 +12*x^7 +30*x^6 +8*x^5 +12*x^4 +6*x^3 +5*x^2 +3) / (-x^12 +3*x^8 -3*x^4 +1) + O(x^100))
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|