A099588 Coefficient of x^2 in (1+x)^n mod 1+x^4.
0, 0, 1, 3, 6, 10, 14, 14, 0, -48, -164, -396, -792, -1352, -1912, -1912, 0, 6528, 22288, 53808, 107616, 183712, 259808, 259808, 0, -887040, -3028544, -7311552, -14623104, -24963200, -35303296, -35303296, 0, 120532992, 411525376, 993510144, 1987020288, 3392055808, 4797091328, 4797091328
Offset: 0
References
- A. Erdelyi, Higher Transcendental Functions, McGraw-Hill, 1955, Vol. 3, Chapter XVIII.
Links
- G. C. Greubel, Table of n, a(n) for n = 0..1000
- Vladimir Shevelev, Combinatorial identities generated by difference analogs of hyperbolic and trigonometric functions of order n, arXiv:1706.01454 [math.CO], 2017.
- Vladimir Shevelev, Coefficient of x^k in ((x+1)^n modulo x^N+1), seqfan, Thu Jul 20 2017.
- G. Tollisen and T. Lengyel, A congruential identity and the 2-adic order of lacunary sums of binomial coefficients, Integers 4 (2004), #A4.
- Index entries for linear recurrences with constant coefficients, signature (4,-6,4,-2).
Programs
-
Maple
f:= rectoproc({rec, a(0)=0,a(1)=0,a(2)=1,a(3)=3},a(n),remember): map(f, [$0..100]); # Robert Israel, Jun 30 2017
-
Mathematica
RecurrenceTable[{a[n]==4*a[n-1] - 6*a[n-2] + 4*a[n-3] - 2*a[n-4], a[1]=0, a[2]=1, a[3]=3, a[4]=6}, a, {n, 1, 200}] (* G. C. Greubel, Nov 10 2015 *) Table[Sum[(-1)^k*Binomial[n, 4 k + 2], {k, 0, n}], {n, 0, 36}] (* Michael De Vlieger, Jun 30 2017 *) a[n_] := n*(n-1)/2 HypergeometricPFQ[{(2-n)/4, (3-n)/4, (4-n)/4, (5-n)/4}, {3/4, 5/4, 3/2}, -1]; Array[a, 40, 0] (* Jean-François Alcover, Jul 20 2017, from Vladimir Shevelev's first formula *)
-
PARI
x='x+O('x^55); concat([0, 0], Vec(-x^2*(x-1)/(2*x^4-4*x^3+6*x^2-4*x+1))) \\ Altug Alkan, Nov 11 2015
-
PARI
a(n) = sum(t=0, (n-2)\4, (-1)^t*binomial(n,4*t+2)); \\ Michel Marcus, Jun 30 2017
-
PARI
a(n)=polcoeff(lift(Mod(1+x,1+x^4)^n),2); \\ Joerg Arndt, Feb 22 2018
Formula
G.f.: -x^2*(x-1) / (2*x^4-4*x^3+6*x^2-4*x+1). - Colin Barker, Jul 15 2013
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - 2*a(n-4). - G. C. Greubel, Nov 10 2015
a(n) = (1/2)*((2+sqrt(2))^(n/2) * sin(n*Pi/8) - (2-sqrt(2))^(n/2)*sin(3*n*Pi/8)). - G. C. Greubel, Nov 10 2015
From Vladimir Shevelev, Jul 04 2017 (Start)
a(n) = Sum_{k>=0}(-1)^k*binomial(n,4*k+2);
a(n) = round((2+sqrt(2))^(n/2)*cos(Pi*(n-4)/8)/2), where round(x) is the integer nearest to x;
Extensions
a(0)=0 added by N. J. A. Sloane, Jul 04 2017
a(673) in b-file corrected by Andrew Howroyd, Feb 21 2018
Comments