A161710 a(n) = (-6*n^7 + 154*n^6 - 1533*n^5 + 7525*n^4 - 18879*n^3 + 22561*n^2 - 7302*n + 2520)/2520.
1, 2, 3, 4, 6, 8, 12, 24, 39, -2, -295, -1308, -3980, -9996, -22150, -44808, -84483, -150534, -256001, -418588, -661806, -1016288, -1521288, -2226376, -3193341, -4498314, -6234123, -8512892, -11468896, -15261684, -20079482, -26142888
Offset: 0
Examples
Differences of divisors of 24 to compute the coefficients of their interpolating polynomial, see formula: 1 ... 2 ... 3 ... 4 ... 6 ... 8 .. 12 .. 24 .. 1 ... 1 ... 1 ... 2 ... 2 ... 4 .. 12 ..... 0 ... 0 ... 1 ... 0 ... 2 ... 8 ........ 0 ... 1 .. -1 ... 2 ... 6 ........... 1 .. -2 ... 3 ... 4 ............. -3 ... 5 ... 1 ................. 8 .. -4 .................. -12.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..10000
- Reinhard Zumkeller, Enumerations of Divisors
- Index entries for linear recurrences with constant coefficients, signature (8,-28,56,-70,56,-28,8,-1).
Crossrefs
Programs
-
Magma
[(-6*n^7 + 154*n^6 - 1533*n^5 + 7525*n^4 - 18879*n^ 3 + 22561*n^2 - 7302*n + 2520)/2520: n in [0..40]]; // Vincenzo Librandi, Jul 17 2011
-
Mathematica
Table[(-6n^7+154n^6-1533n^5+7525n^4-18879n^3+22561n^2-7302n+2520)/2520,{n,0,40}] (* or *) LinearRecurrence[{8,-28,56,-70,56,-28,8,-1},{1,2,3,4,6,8,12,24},40] (* Harvey P. Dale, Jul 15 2012 *)
-
PARI
a(n)=(-6*n^7+154*n^6-1533*n^5+7525*n^4-18879*n^3+22561*n^2-7302*n+2520)/2520 \\ Charles R Greathouse IV, Sep 24 2015
-
Python
A161710_list, m = [1], [-12, 80, -223, 333, -281, 127, -23, 1] for _ in range(1,10**2): for i in range(7): m[i+1]+= m[i] A161710_list.append(m[-1]) # Chai Wah Wu, Nov 09 2014
Formula
a(n) = C(n,0) + C(n,1) + C(n,4) - 3*C(n,5) + 8*C(n,6) - 12*C(n,7).
G.f.: (1-6*x+15*x^2-20*x^3+16*x^4-12*x^5+18*x^6-24*x^7)/(1-x)^8. - Bruno Berselli, Jul 17 2011
a(0)=1, a(1)=2, a(2)=3, a(3)=4, a(4)=6, a(5)=8, a(6)=12, a(7)=24, a(n)=8*a(n-1)-28*a(n-2)+56*a(n-3)-70*a(n-4)+56*a(n-5)-28*a(n-6)+ 8*a(n-7)- a(n-8). - Harvey P. Dale, Jul 15 2012
Comments