login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A203568 a(n) = A026837(n) - A026838(n). 2
0, 1, -1, 0, 0, 1, 0, -1, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

LINKS

Robert Israel, Table of n, a(n) for n = 0..10000

FORMULA

G.f.: Sum_{k in Z} sign(k) * x^(k * (3*k - 1) / 2).

G.f.: Sum_{k>0} x^(k * (3*k - 1) / 2) * (1 - x^k). - Michael Somos, Jul 12 2015

G.f.: x - x^2 * (1 + x) + x^3 * (1 + x) * (1 + x^2) - x^4 * (1 + x) * (1 + x^2) * (1 + x^3) + .... - Michael Somos, Jul 12 2015

G.f.: x / (1 + x) - x^3 / ((1 + x) * (1 + x^2)) + x^6 / ((1 + x) * (1 + x^2) * (1 + x^3)) - .... - Michael Somos, Jul 12 2015

G.f.: x / (1 + x^2) - x^2 / ((1 + x^2) * (1 + x^4)) + x^3 / ((1 + x^2 ) * (1 + x^4) * (1 + x^6)) - .... - Michael Somos, Jul 12 2015

a(n) = - A143062(n) unless n=0. - Michael Somos, Jul 12 2015

For k >= 1, a((3*k^2 - k)/2) = 1, a((3*k^2 + k)/2) = -1.  a(n) = 0 otherwise. - Robert Israel, Nov 24 2015

EXAMPLE

G.f. = x - x^2 + x^5 - x^7 + x^12 - x^15 + x^22 - x^26 + x^35 - x^40 + x^51 - ...

G.f. = q^25 - q^49 + q^121 - q^169 + q^289 - q^361 + q^529 - q^625 + ...

MAPLE

N:= 1000: # to get a(0) to a(N)

V:= Array(0..N):

for k from 1 to floor((sqrt(1+24*N)-1)/6) do V[(3*k^2-k)/2]:= 1 od:

for k from 1 to floor((sqrt(1+24*N)+1)/6) do V[(3*k^2+k)/2]:= -1 od:

convert(V, list); # Robert Israel, Nov 24 2015

MATHEMATICA

a[ n_] := Which[ n < 1, 0, SquaresR[ 1, 24 n + 1] == 2, -(-1)^Quotient[ Sqrt[24 n + 1], 3], True, 0]; (* Michael Somos, Jul 12 2015 *)

PROG

(PARI) {a(n) = if( n<1, 0, if( issquare( 24*n + 1, &n), - kronecker( -12, n)))};

CROSSREFS

Cf. A010815, A026837, A026838, A143062.

Sequence in context: A076182 A010058 A140591 * A079336 A057215 A029691

Adjacent sequences:  A203565 A203566 A203567 * A203569 A203570 A203571

KEYWORD

sign

AUTHOR

Michael Somos, Jan 03 2012

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 | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 19 06:03 EDT 2018. Contains 316336 sequences. (Running on oeis4.)