login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Expansion of (1+x)^3/(1+x^3).
6

%I #40 Jan 01 2024 18:41:23

%S 1,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,

%T -3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,

%U -3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3,0,3,3,0,-3,-3

%N Expansion of (1+x)^3/(1+x^3).

%C Partial sums are A084104.

%H G. C. Greubel, <a href="/A084103/b084103.txt">Table of n, a(n) for n = 0..1000</a>

%H <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (1,-1).

%F G.f.: (1+x)^3/(1+x^3).

%F a(n) = Sum_{k=0..n} binomial(2n-k-1, k)(-1)^k*3(n-k). - _Paul Barry_, Jan 21 2005

%F a(0) = 1 and a(n) = 2*sqrt(3)*sin(n*Pi/3). - _N-E. Fahssi_, Mar 04 2010

%F Euler transform of length 6 sequence [3, -3, -1, 0, 0, 1]. - _Michael Somos_, Feb 13 2011

%F a(n) = -a(-n) = 3 * A128834(n) except a(0) = 1. - _Michael Somos_, Feb 13 2011

%F a(n) = 3*(n^2 mod 3)*(-1)^floor(n/3), n>0. - _Wesley Ivan Hurt_, May 15 2015

%F The periodic sequence b(n) = a(n+1) has the o.g.f. 3 + G(x) = 3 + 3x(1-x) / (1-x(1-x)) = 3 + 3 L(Cinv(x)) = 3 + 3 x - 3 x^3 - 3 x^4 + ... , where L(x) = x/(1-x) with inverse Linv(x) = x/(1+x) and Cinv(x) = x(1-x), the inverse of the o.g.f. for the shifted Catalan numbers of A000108, C(x) = (1-sqrt(1-4x))/2. Then Ginv(x) = C(Linv(x/3)) = [1 - sqrt[1-4x/(3+x)]]/2. Cf. A267633. - _Tom Copeland_, Jan 25 2016

%e 1 + 3*x + 3*x^2 - 3*x^4 - 3*x^5 + 3*x^7 + 3*x^8 - 3*x^10 - 3*x^11 + ...

%p 1, seq(op((-1)^i*[3, 3, 0]), i=0..20); # _Robert Israel_, May 17 2015

%t CoefficientList[Series[(1 + x)^3/(1 + x^3), {x, 0, 100}], x] (* _Vincenzo Librandi_, May 16 2015 *)

%t Join[{1}, LinearRecurrence[{1,-1}, {3,3}, 30]] (* _G. C. Greubel_, Jan 15 2018 *)

%o (PARI) {a(n) = (n==0) + [0, 3, 3, 0, -3, -3][n%6 + 1]} /* _Michael Somos_, Feb 13 2011 */

%o (PARI) {a(n) = (n==0) - 3 * (-1)^n * kronecker(-3, n)} /* _Michael Somos_, Feb 13 2011 */

%o (Magma) I:=[1,3,3]; [n le 3 select I[n] else Self(n-1)-Self(n-2): n in [1..100]]; // _Vincenzo Librandi_, May 16 2015

%Y Cf. A000108, A084104, A267633.

%K easy,sign

%O 0,2

%A _Paul Barry_, May 15 2003