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!)
A105368 Expansion of (1-x-x^3+x^4)/(1-x^5). 4
1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1, -1, 0, -1, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

COMMENTS

Period 5: repeat [1,-1,0,-1,1]. Partial sums are A105367.

Binomial transform of A105369. - R. J. Mathar, Jul 29 2010

LINKS

Table of n, a(n) for n=0..80.

Index entries for linear recurrences with constant coefficients, signature (-1,-1,-1,-1). - R. J. Mathar, Jul 29 2010

Michael Somos, Rational Function Multiplicative Coefficients

FORMULA

G.f.: (1-x)*(1-x^3)/(1-x^5).

a(n) = (1/2-sqrt(5)/10)*cos(4*Pi*n/5)-sqrt(1/2+sqrt(5)/10)*sin(4*Pi*n/5)+(1/2+sqrt(5)/10)*cos(2*Pi*n/5)-sqrt(1/2-sqrt(5)/10)*sin(2*Pi*n/5).

a(n) = (1/5)*{-2*[(n+1) mod 5]+[(n+2) mod 5]-[(n+3) mod 5]2*[(n+4) mod 5]}, with n>=0. - Paolo P. Lava, Jun 01 2007

From R. J. Mathar, Jul 29 2010: (Start)

a(n) = -a(n-1) -a(n-2) -a(n-3) -a(n-4), n>4.

G.f.: (1-x)*(1+x+x^2)/(1+x+x^2+x^3+x^4).

(End)

a(n) = -sign( (n+3) mod 5)*(-1)^floor(-2n/5-4/5). - Wesley Ivan Hurt, Apr 28 2015

a(n) = 2 - ( (n^2+n+1) mod 5 ). - Wesley Ivan Hurt, May 31 2015

Euler transform of length 5 sequence [ -1, 0, -1, 0, 1]. - Michael Somos, Jun 16 2015

a(n) = a(-1-n) for all n in Z. - Michael Somos, Jun 16 2015

a(n) = b(2*n + 1) where b() is multiplicative with b(2^e) = b(5^e) = 0^e, b(p^e) = 1 if p == 1, 9 (mod 10), b(p^e) = (-1)^e if p == 3, 7 (mod 10). - Michael Somos, Jun 16 2015

EXAMPLE

G.f. = 1 - x - x^3 + x^4 + x^5 - x^6 - x^8 + x^9 + x^10 - x^11 - x^13 + ...

G.f. = q - q^3 - q^7 + q^9 + q^11 - q^13 - q^17 + q^19 + q^21 - q^23 + ...

MAPLE

A105368:=n->2-(n^2+n-4 mod 5): seq(A105368(n), n=0..100);

MATHEMATICA

CoefficientList[Series[(1 - x - x^3 + x^4)/(1 - x^5), {x, 0, 100}], x] (* Vincenzo Librandi, Apr 29 2015 *)

a[ n_] := {-1, 0, -1, 1, 1}[[Mod[n, 5, 1]]]; (* Michael Somos, Jun 16 2015 *)

PROG

(Magma) &cat [[1, -1, 0, -1, 1]: n in [1..20]] /* or */ I:=[1, -1, 0, -1]; [n le 4 select I[n] else -Self(n-1)-Self(n-2)-Self(n-3)-Self(n-4): n in [1..100]]; // Vincenzo Librandi, Apr 29 2015

(PARI) {a(n) = [ 1, -1, 0, -1, 1][n%5 + 1]}; /* Michael Somos, Jun 16 2015 */

CROSSREFS

Sequence in context: A188031 A305387 A085241 * A138019 A179850 A267919

Adjacent sequences: A105365 A105366 A105367 * A105369 A105370 A105371

KEYWORD

sign,easy

AUTHOR

Paul Barry, Apr 01 2005

STATUS

approved

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 25 23:06 EDT 2023. Contains 361529 sequences. (Running on oeis4.)