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

 

Logo

The OEIS is looking to hire part-time people to help edit core sequences, upload scanned documents, process citations, fix broken links, etc. - Neil Sloane, njasloane@gmail.com

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A010054 a(n) = 1 if n is a triangular number else 0. 1420
1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 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, 0, 0, 0, 0, 0, 0, 0 (list; table; graph; refs; listen; history; text; internal format)
OFFSET

0,1

COMMENTS

This is essentially the q-expansion of the Jacobi theta function theta_2(q). (In theta_2 one has to ignore the initial factor of 2*q^(1/4) and then replace q by q^(1/2). See also A005369.) - N. J. A. Sloane, Aug 03 2014

Ramanujan theta functions: f(q) (see A121373), phi(q) (A000122), psi(q) (A010054), chi(q) (A000700).

Ramanujan's theta function f(a, b) = Sum a^{n*(n+1)/2} * b^{n*(n-1)/2}, n=-inf..inf.

This sequence is the concatenation of the base-b digits in the sequence b^n, for any base b >= 2. - Davis Herring (herring(AT)lanl.gov), Nov 16 2004

Number of partitions of n into distinct parts such that the greatest part equals the number of all parts, see also A047993; a(n)=A117195(n,0) for n>0; a(n)=1-A117195(n,1) for n>1. - Reinhard Zumkeller, Mar 03 2006

Triangle T(n,k), 0<=k<=n, read by rows, given by A000007 DELTA A000004 where DELTA is the operator defined in A084938. - Philippe Deléham, Jan 03 2009

Convolved with A000041 = A022567, the convolution square of A000009. - Gary W. Adamson, Jun 11 2009

A008441(n) = SUM(a(k)*a(n-k): 0<=k<=n). - Reinhard Zumkeller, Nov 03 2009

Polcoeff inverse with alternate signs = A006950: (1, 1, 1, 2, 3, 4, 5, 7,...). - Gary W. Adamson, Mar 15 2010

This sequence is related to Ramanujan's two-variable theta functions because this sequence is also the characteristic function of generalized hexagonal numbers. - Omar E. Pol, Jun 08 2012

Number 3 of the 14 primitive eta-products which are holomorphic modular forms of weight 1/2 listed by D. Zagier on page 30 of "The 1-2-3 of Modular Forms". - Michael Somos, May 04 2016

REFERENCES

J. H. Conway and N. J. A. Sloane, "Sphere Packings, Lattices and Groups", Springer-Verlag, p. 103.

J. Tannery and J. Molk, Eléments de la Théorie des Fonctions Elliptiques, Vol. 2, Gauthier-Villars, Paris, 1902; Chelsea, NY, 1972, see p. 27.

E. T. Whittaker and G. N. Watson, A Course of Modern Analysis, Cambridge Univ. Press, 4th ed., 1963, p. 464.

LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 0..10000

S. Cooper and M. D. Hirschhorn, Results of Hurwitz type for three squares. Discrete Math. 274 (2004), no. 1-3, 9-24. See psi(q).

M. D. Hirschhorn, J. A. Sellers, A Congruence Modulo 3 for Partitions into Distinct Non-Multiples of Four, Article 14.9.6, Journal of Integer Sequences, Vol. 17 (2014).

K. Ono, S. Robins and P. T. Wahl, On the representation of integers as sums of triangular numbers, Aequationes mathematicae, August 1995, Volume 50, Issue 1-2, pp 73-94, Proposition 1.

M. Somos, Introduction to Ramanujan theta functions>

Eric Weisstein's World of Mathematics, Ramanujan Theta Functions

Index entries for characteristic functions

FORMULA

Expansion of f(x, x^3) in powers of x where f(, ) is Ramanujan's general theta function.

Expansion of q^(-1) * (phi(q) - phi(q^4)) / 2 in powers of q^8. - Michael Somos, Jul 01 2014

Expansion of q^(-1/8) * eta(q^2)^2 / eta(q) in powers of q. - Michael Somos, Apr 13 2005

Euler transform of period 2 sequence [ 1, -1, ...]. - Michael Somos, Mar 24 2003

Given g.f. A(x), then B(q) = q * A(q^8) satisfies 0 = f(B(q), B(q^2), B(q^3), B(q^6)) where f(u1, u2, u3, u6) = u1*u6^3 + u2*u3^3 - u1*u2^2*u6. - Michael Somos, Apr 13 2005

a(n) = b(8*n + 1) where b() is multiplicative with b(2^e) = 0^e, b(p^e) = (1 + (-1)^e) / 2 if p>2. - Michael Somos, Jun 06 2005

a(n) = A005369(2*n). - Michael Somos, Apr 29 2003

G.f.: theta_2(sqrt(q)) / (2 * q^(1/8)).

G.f.: 1 / (1 - x / (1 + x / (1 + x^1 / (1 - x / (1 + x / (1 + x^2 / (1 - x / (1 + x / (1 + x^3 / ...))))))))). - Michael Somos, May 11 2012

G.f.: Product_{k>0} (1-x^(2*k))/(1-x^(2*k-1)). - Vladeta Jovovic, May 02 2002

a(0)=1; for n>0, a(n) = A002024(n+1)-A002024(n). - Benoit Cloitre, Jan 05 2004

G.f.: sum(j=0, oo, product(k=0, j, x^j)). - Jon Perry, Mar 30 2004

a(n) = floor((1-cos(Pi*sqrt(8*n+1)))/2). - Carl R. White, Mar 18 2006

a(n) = round(sqrt(2n+1))-round(sqrt(2n)). - Hieronymus Fischer, Aug 06 2007

a(n) = ceiling(2*sqrt(2n+1))-floor(2*sqrt(2n))-1. - Hieronymus Fischer, Aug 06 2007

a(n) = f(n,0) with f(x,y) = if x>0 then f(x-y,y+1) else 0^(-x). - Reinhard Zumkeller, Sep 27 2008

a(n) = A035214(n) - 1.

From Mikael Aaltonen, Jan 22 2015: (Start)

Since the characteristic function of s-gonal numbers is given by floor(sqrt(2n/(s-2)+((s-4)/(2s-4))^2)+(s-4)/(2s-4)) - floor(sqrt(2(n-1)/(s-2)+((s-4)/(2s-4))^2)+(s-4)/(2s-4)), by setting s = 3 we get the following: For n > 0, a(n) = floor(sqrt(2*n+1/4)-1/2)- floor(sqrt(2*(n-1)+1/4)-1/2).

(End)

a(n) = (-1)^n * A106459(n). - Michael Somos, May 04 2016

G.f. is a period 1 Fourier series which satisfies f(-1 / (16 t)) = 2^(-1/2) (t/i)^(1/2) g(t) where q = exp(2 Pi i t) and g() is the g.f. for A002448. - Michael Somos, May 05 2016

G.f.: Sum_{n >= 0} x^(n*(n+1)/2) = Prod_{n >= 1} (1 - x^n)*(1 + x^n)^2 = Product_{n >= 1} (1 - x^(2*n))*(1 + x^n) = Product_{n >= 1} (1 - x^(2*n))/(1 - x^(2*n-1)). From the sum and product representations of theta_2(0, sqrt(q))/(2*q^(1/8))) function. The last product, given by Vladeta Jovovic above, is obtained from the second to last one by an Euler identity, proved via f(x) := Product_{n >= 1} (1 - x^(2*n-1))*Product_{n >= 1} (1 + x^n) = f(x^2), by moving the odd indexed factors of the second product to the first product. This leads to f(x) = f(0) = 1. - Wolfdieter Lang, Jul 05 2016

a(0) = 1, a(n) = (1/n)*Sum_{k=1..n} A002129(k)*a(n-k) for n > 0. - Seiichi Manyama, Apr 08 2017

EXAMPLE

G.f. = 1 + x + x^3 + x^6 + x^10 + x^15 + x^21 + x^28 + x^36 + x^45 + x^55 + x^66 + ...

G.f. for B(q) = q * A(q^8): q + q^9 + q^25 + q^49 + q^81 + q^121 + q^169 + q^225 + q^289 + q^361 + ...

From Philippe Deléham, Jan 04 2008: (Start)

As a triangle this begins:

.1;

.1, 0;

.1, 0, 0;

.1, 0, 0, 0;

.1, 0, 0, 0, 0;

.1, 0, 0, 0, 0, 0;

...  (End)

MATHEMATICA

a[ n_] := SquaresR[ 1, 8 n + 1] / 2; (* Michael Somos, Nov 15 2011 *)

a[ n_] := If[ n < 0, 0, SeriesCoefficient[ (Series[ EllipticTheta[ 3, Log[y] / (2 I), x^2], {x, 0, n + Floor @ Sqrt[n]}] // Normal // TrigToExp) /. {y -> x}, {x, 0, n}]]; (* Michael Somos, Nov 15 2011 *)

Table[If[IntegerQ[(Sqrt[8n+1]-1)/2], 1, 0], {n, 0, 110}] (* Harvey P. Dale, Oct 29 2012 *)

a[ n_] := SeriesCoefficient[ EllipticTheta[ 2, 0, q^(1/2)] / (2 q^(1/8)), {q, 0, n}]; (* Michael Somos, Jul 01 2014 *)

PROG

(PARI) {a(n) = my(A); if( n<0, 0, A = x * O(x^n); polcoeff( eta(x^2 + A)^2 / eta(x + A), n))}; /* Michael Somos, Mar 14 2011 */

(PARI) {a(n) = issquare( 8*n + 1)}; /* Michael Somos, Apr 27 2000 */

(PARI) a(n) = ispolygonal(n, 3); \\ Michel Marcus, Jan 22 2015

(Haskell)

a010054 = a010052 . (+ 1) . (* 8)

a010054_list = concatMap (\x -> 1 : replicate x 0) [0..]

-- Reinhard Zumkeller, Feb 12 2012, Oct 22 2011, Apr 02 2011

(MAGMA) Basis( ModularForms( Gamma0(16), 1/2), 362) [2] ; /* Michael Somos, Jun 10 2014 */

CROSSREFS

Cf. A000217, A002448, A005369, A023531, A035214, A022567, A052343, A006950, A106459, A127648.

Number of ways of writing n as a sum of k triangular numbers, for k=1,...: A010054, A008441, A008443, A008438, A008439, A008440, A226252, A007331, A226253, A226254, A226255, A014787, A014809.

Cf. A106507 (reciprocal series).

Sequence in context: A106459 A143433 A143434 A197870 A033806 A033802 A033800

Adjacent sequences:  A010051 A010052 A010053 * A010055 A010056 A010057

KEYWORD

nonn,tabl,easy

AUTHOR

N. J. A. Sloane

EXTENSIONS

Additional comments from Michael Somos, Apr 27 2000

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 May 30 06:51 EDT 2017. Contains 287302 sequences.