cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A014255 Expansion of (1+2*x+3*x^2)/((1-x)*(1-x^2)^2).

Original entry on oeis.org

1, 3, 8, 12, 21, 27, 40, 48, 65, 75, 96, 108, 133, 147, 176, 192, 225, 243, 280, 300, 341, 363, 408, 432, 481, 507, 560, 588, 645, 675, 736, 768, 833, 867, 936, 972, 1045, 1083, 1160, 1200, 1281, 1323, 1408, 1452, 1541, 1587, 1680, 1728, 1825, 1875, 1976, 2028
Offset: 0

Views

Author

Keywords

Comments

A002620(n+1) is the n-th partial arithmetic mean. - Michael Somos, Feb 14 2004
The smallest integer greater than a(n-1) such that the n-th partial arithmetic mean is an integer is a(n) if n is odd or a(n)-(n+1) if n is even. - Michael Somos, Feb 14 2004
Beginning with 1, the smallest integer greater than the previous term such that no three consecutive terms are in arithmetic progression and the n-th partial arithmetic mean is an integer. - Amarnath Murthy, Feb 05 2004
The maximum possible number of black cells in a solution to an (n+1) X (n+1) nurikabe grid. - Tanya Khovanova, Feb 24 2009
Let M = an infinite lower triangular matrix with alternate columns composed of (1,1,1,...) and (1,2,2,2,...); and Q = the diagonalized variant of (1,2,3,...). Then Q*M = a triangle with row sums = A014255. - Gary W. Adamson, May 14 2010
Number of pairs (x,y) with x and y in {0,...,n} having the same parity and x+y < n. - Clark Kimberling, Jul 02 2012
Form an array with m(0,0)=0 and m(i,j)=|i^2 - j^2|. One-half the difference between the sum of the terms in antidiagonal(n) and those in antidiagonal(n-1)=a(n). - J. M. Bergot, Jul 10 2013
For n > 0, a(n-1) is the sum of the largest parts in the partitions of 2n into two odd parts. - Wesley Ivan Hurt, Dec 19 2017
Sum of the odd numbers in the interval [m, 2*m] with m > 0. Example: for m = 5, the sum of the odd numbers in [5, 10] is 5 + 7 + 9 = 21, therefore 21 is a term of this sequence. - Bruno Berselli, Oct 25 2018

Examples

			From _Gary W. Adamson_, May 14 2010: (Start)
The first few rows of the generating triangle are
  1;
  1,  2;
  1,  4,  3;
  1,  4,  3,  4;
  1,  4,  3,  8,  5;
  1,  4,  3,  8,  5,  6;
  1,  4,  3,  8,  5, 12,  7;
  1,  4,  3,  8,  5, 12,  7,  8;
  1,  4,  3,  8,  5, 12,  7, 16,  9;
  1,  4,  3,  8,  5, 12,  7, 16,  9, 10;
  ...
Row sums  are 1, 3, 8, 12, 21, 27, 40, ... (End)
G.f. = 1 + 3*x + 8*x^2 + 12*x^3 + 21*x^4 + 27*x^5 + 40*x^6 + 48*x^7 + ...
		

Programs

  • GAP
    List([0..55], n-> (6*n^2+14*n+7 +(-1)^n*(2*n+1))/8); # G. C. Greubel, Jun 18 2019
  • Magma
    [(6*n^2+14*n+7 +(-1)^n*(2*n+1))/8: n in [0..55]]; // G. C. Greubel, Jun 18 2019
    
  • Mathematica
    Array[(# + 1)^2 - Floor[(# + 1)/2]^2 &, 52, 0] (* or *)
    CoefficientList[Series[(1+2x+3x^2)/((1-x)(1-x^2)^2), {x, 0, 51}], x] (* Michael De Vlieger, Dec 20 2017 *)
  • PARI
    vector(55, n, n--; (6*n^2+14*n+7 +(-1)^n*(2*n+1))/8) \\ G. C. Greubel, Jun 18 2019
    
  • Sage
    [(6*n^2+14*n+7 +(-1)^n*(2*n+1))/8 for n in (0..55)] # G. C. Greubel, Jun 18 2019
    

Formula

G.f.: (1+2*x+3*x^2)/((1-x)*(1-x^2)^2).
a(n) = (n+1)^2 - floor((n+1)/2)^2. - Franklin T. Adams-Watters, May 26 2006
a(n) = (6*n^2 + 14*n + 7 + (-1)^n*(2*n + 1))/8. - R. J. Mathar, Mar 22 2011
a(n) = (k+1)*(3*k+1) if n = 2*k, 3*(k+1)^2 if n = 2*k+1. - Michael Somos, Feb 27 2014
E.g.f.: ((4+9*x+3*x^2)*cosh(x) + (3+11*x+3*x^2)*sinh(x))/4. - G. C. Greubel, Jun 18 2019