login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A345007 a(0) = 1; a(3*n) = a(n) - a(n-1), a(3*n+1) = a(3*n+2) = -a(n). 1

%I #5 Jun 05 2021 16:44:51

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

%T -2,1,1,3,-2,-2,0,-2,-2,1,-3,-3,-4,1,1,0,1,1,1,0,0,-1,1,1,0,1,1,0,1,1,

%U 1,0,0,0,0,0,1,-1,-1,-2,1,1,0,1,1,1,0,0,-1,1,1,0,1,1,-1,2,2,3,-1,-1,0,-1,-1,2,-3,-3,-5,2,2

%N a(0) = 1; a(3*n) = a(n) - a(n-1), a(3*n+1) = a(3*n+2) = -a(n).

%F G.f. A(x) satisfies: A(x) = (1 - x - x^2 - x^3) * A(x^3).

%F G.f.: Product_{k>=0} (1 - x^(3^k) - x^(2*3^k) - x^(3^(k+1))).

%t a[0] = 1; a[n_] := Switch[Mod[n, 3], 0, a[n/3] - a[(n - 3)/3], 1, -a[(n - 1)/3], 2, -a[(n - 2)/3]]; Table[a[n], {n, 0, 95}]

%t nmax = 95; A[_] = 1; Do[A[x_] = (1 - x - x^2 - x^3) A[x^3] + O[x]^(nmax + 1) // Normal, nmax + 1]; CoefficientList[A[x], x]

%t nmax = 95; CoefficientList[Series[Product[(1 - x^(3^k) - x^(2 3^k) - x^(3^(k + 1))), {k, 0, Floor[Log[3, nmax]] + 1}], {x, 0, nmax}], x]

%Y Cf. A054390, A177219, A309048, A345006.

%K sign

%O 0,4

%A _Ilya Gutkovskiy_, Jun 05 2021

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 29 09:32 EDT 2024. Contains 371268 sequences. (Running on oeis4.)