The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A257170 Expansion of (1 + x) * (1 + x^3) / (1 + x^4) in powers of x. 2
 1, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1, 0, 1, 0, 1, 0, -1, 0, -1 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,1 LINKS G. C. Greubel, Table of n, a(n) for n = 0..2500 FORMULA Euler transform of length 8 sequence [1, -1, 1, -1, 0, -1, 0, 1]. a(n) is multiplicative with a(2^e) = 0^e, a(p^e) = 1 if p == 1 or 3 (mod 8), a(p^e) = (-1)^e otherwise and a(0) = 1. a(n) = -a(-n) for all n in Z unless n = 0. a(n+4) = -a(n) unless n = 0 or n = -4. a(2*n) = 0 unless n = 0. a(n) = A188510(n) unless n = 0. a(n+1) - a(n) = (-1)^n if n>0. G.f.: (1 + x) * (1 + x^3) / (1 + x^4) = 1 + (x + x^3) / (1 + x^4). G.f.: (1 - x^2) * (1 - x^4) * (1 - x^6) / ((1 - x) * (1 - x^3) * (1 - x^8)). G.f.: 1 / (1 - x / (1 + x / (1 + x / (1 - x / (1 + 2*x / (1 - 2*x / (1 - x / (2 + x)))))))). EXAMPLE G.f. = 1 + x + x^3 - x^5 - x^7 + x^9 + x^11 - x^13 - x^15 + x^17 + x^19 + ... MATHEMATICA a[ n_] := If[ EvenQ[ n], Boole[n == 0], (-1)^Quotient[ n, 4]]; a[ n_] := If[ n == 0, 1, Sign[ n] SeriesCoefficient[ (1 + x) * (1 + x^3) / (1 + x^4), {x, 0, Abs @ n}]]; CoefficientList[Series[(1+x)*(1+x^3)/(1+x^4), {x, 0, 60}], x] (* G. C. Greubel, Aug 02 2018 *) PROG (PARI) {a(n) = if( n%2 == 0, n==0, (-1)^(n\4))}; (PARI) {a(n) = if( n==0, 1, sign(n) * polcoeff( (1 + x) * (1 + x^3) / (1 + x^4), + x* O(x^abs(n)), abs(n)))}; (PARI) x='x+O('x^60); Vec((1+x)*(1+x^3)/(1+x^4)) \\ G. C. Greubel, Aug 02 2018 (MAGMA) m:=60; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((1+x)*(1+x^3)/(1+x^4))); // G. C. Greubel, Aug 02 2018 CROSSREFS Cf. A188510. Sequence in context: A322860 A178225 A264739 * A073097 A117569 A135528 Adjacent sequences:  A257167 A257168 A257169 * A257171 A257172 A257173 KEYWORD sign,mult,easy AUTHOR Michael Somos, Apr 17 2015 STATUS approved

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

Last modified September 29 21:59 EDT 2020. Contains 337432 sequences. (Running on oeis4.)