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.

Showing 1-6 of 6 results.

A152734 5 times pentagonal numbers: 5*n*(3*n-1)/2.

Original entry on oeis.org

0, 5, 25, 60, 110, 175, 255, 350, 460, 585, 725, 880, 1050, 1235, 1435, 1650, 1880, 2125, 2385, 2660, 2950, 3255, 3575, 3910, 4260, 4625, 5005, 5400, 5810, 6235, 6675, 7130, 7600, 8085, 8585, 9100, 9630, 10175, 10735, 11310, 11900, 12505, 13125, 13760, 14410
Offset: 0

Views

Author

Omar E. Pol, Dec 11 2008

Keywords

Comments

a(n) can be represented as a figurate number using n concentric pentagons (see example). - Omar E. Pol, Aug 21 2011

Examples

			From _Omar E. Pol_, Aug 22 2011 (Start):
Illustration of initial terms as concentric pentagons (in a precise representation the pentagons should be strictly concentric):
.
.                                          o
.                                        o   o
.                                      o       o
.                o                   o     o     o
.              o   o               o     o   o     o
.            o       o           o     o       o     o
.  o       o     o     o       o     o     o     o     o
.o   o   o     o   o     o   o     o     o   o     o     o
. o o     o     o o     o     o     o     o o     o     o
.          o           o       o     o           o     o
.           o         o         o     o         o     o
.            o o o o o           o     o o o o o     o
.                                 o                 o
.                                  o               o
.                                   o o o o o o o o
.
.  5             25                        60
(End)
		

Crossrefs

Cf. sequences of the form n*(d*n+10-d)/2 indexed in A140090.

Programs

Formula

a(n) = 5*A000326(n).
a(n) = a(n-1)+15*n-10 (with a(0)=0). - Vincenzo Librandi, Nov 26 2010
G.f.: 5*x*(1+2*x)/(1-x)^3. a(n) = 4*A000217(n)+A051865(n). - Bruno Berselli, Feb 11 2011
E.g.f.: (5/2)*(3*x^2 + 2*x)*exp(x). - G. C. Greubel, Jul 17 2017
From Amiram Eldar, Feb 26 2022: (Start)
Sum_{n>=1} 1/a(n) = (9*log(3) - sqrt(3)*Pi)/15.
Sum_{n>=1} (-1)^(n+1)/a(n) = 2*(sqrt(3)*Pi- 6*log(2))/15. (End)

A194274 Concentric square numbers (see Comments lines for definition).

Original entry on oeis.org

0, 1, 4, 8, 12, 17, 24, 32, 40, 49, 60, 72, 84, 97, 112, 128, 144, 161, 180, 200, 220, 241, 264, 288, 312, 337, 364, 392, 420, 449, 480, 512, 544, 577, 612, 648, 684, 721, 760, 800, 840, 881, 924, 968, 1012, 1057, 1104, 1152, 1200, 1249, 1300, 1352, 1404
Offset: 0

Views

Author

Omar E. Pol, Aug 20 2011

Keywords

Comments

Cellular automaton on the first quadrant of the square grid. The sequence gives the number of cells "ON" in the structure after n-th stage. A098181 gives the first differences. For a definition without words see the illustration of initial terms in the example section. For other concentric polygonal numbers see A194273, A194275 and A032528.
Also, union of A046092 and A077221, the bisections of this sequence.
Also row sums of an infinite square array T(n,k) in which column k lists 4*k-1 zeros followed by the numbers A008574 (see example).

Examples

			Using the numbers A008574 we can write:
0, 1, 4, 8, 12, 16, 20, 24, 28, 32, 36, ...
0, 0, 0, 0, 0,  1,   4,  8, 12, 16, 20, ...
0, 0, 0, 0, 0,  0,   0,  0,  0,  1,  4, ...
And so on.
===========================================
The sums of the columns give this sequence:
0, 1, 4, 8, 12, 17, 24, 32, 40, 49, 60, ...
...
Illustration of initial terms:
.                                         o o o o o o
.                             o o o o o   o         o
.                   o o o o   o       o   o   o o   o
.           o o o   o     o   o   o   o   o   o o   o
.     o o   o   o   o     o   o       o   o         o
. o   o o   o o o   o o o o   o o o o o   o o o o o o
.
. 1    4      8        12         17           24
		

Crossrefs

Programs

  • Magma
    [n le 2 select n-1 else (n-1)^2 - Self(n-2): n in [1..61]]; // G. C. Greubel, Jan 31 2024
    
  • Mathematica
    Table[Floor[3*n/4] + Floor[(n*(n + 2) + 1)/2] - Floor[(3*n + 1)/4], {n, 0, 52}] (* Arkadiusz Wesolowski, Nov 08 2011 *)
    RecurrenceTable[{a[0]==0,a[1]==1,a[n]==n^2-a[n-2]},a,{n,60}] (* or *) LinearRecurrence[{3,-4,4,-3,1},{0,1,4,8,12},60] (* Harvey P. Dale, Sep 11 2013 *)
  • Python
    prpr = 0
    prev = 1
    for n in range(2,777):
        print(str(prpr), end=", ")
        curr = n*n - prpr
        prpr = prev
        prev = curr
    # Alex Ratushnyak, Aug 03 2012
    
  • Python
    def A194274(n): return (3*n>>2)+(n*(n+2)+1>>1)-(3*n+1>>2) # Chai Wah Wu, Jul 15 2023
    
  • SageMath
    def A194274(n): return n if n<2 else n^2 - A194274(n-2)
    [A194274(n) for n in range(41)] # G. C. Greubel, Jan 31 2024

Formula

a(n) = n^2 - a(n-2), with a(0)=0, a(1)=1. - Alex Ratushnyak, Aug 03 2012
From R. J. Mathar, Aug 22 2011: (Start)
G.f.: x*(1 + x)/((1 + x^2)*(1 - x)^3).
a(n) = (A005563(n) - A056594(n-1))/2. (End)
a(n) = a(-n-2) = (2*n*(n+2) + (1-(-1)^n)*i^(n+1))/4, where i=sqrt(-1). - Bruno Berselli, Sep 22 2011
a(n) = floor(3*n/4) + floor((n*(n+2)+1)/2) - floor((3*n+1)/4). - Arkadiusz Wesolowski, Nov 08 2011
a(n) = 3*a(n-1) - 4*a(n-2) + 4*a(n-3) - 3*a(n-4) + a(n-5), with a(0)=0, a(1)=1, a(2)=4, a(3)=8, a(4)=12. - Harvey P. Dale, Sep 11 2013
E.g.f.: (exp(x)*x*(3 + x) - sin(x))/2. - Stefano Spezia, Feb 26 2023

A281026 a(n) = floor(3*n*(n+1)/4).

Original entry on oeis.org

0, 1, 4, 9, 15, 22, 31, 42, 54, 67, 82, 99, 117, 136, 157, 180, 204, 229, 256, 285, 315, 346, 379, 414, 450, 487, 526, 567, 609, 652, 697, 744, 792, 841, 892, 945, 999, 1054, 1111, 1170, 1230, 1291, 1354, 1419, 1485, 1552, 1621, 1692, 1764, 1837, 1912, 1989, 2067, 2146
Offset: 0

Views

Author

Bruno Berselli, Jan 13 2017

Keywords

Crossrefs

Subsequence of A214068.
Partial sums of A047273.
Cf. A011865, A045943, A274757 (subsequence).
Cf. sequences with formula floor(k*n*(n+1)/4): A011848 (k=1), A000217 (k=2), this sequence (k=3), A002378 (k=4).
Cf. sequences with formula floor(k*n*(n+1)/(k+1)): A000217 (k=1), A143978 (k=2), this sequence (k=3), A281151 (k=4), A194275 (k=5).

Programs

  • Magma
    [3*n*(n+1) div 4: n in [0..60]];
  • Maple
    A281026:=n->floor(3*n*(n+1)/4): seq(A281026(n), n=0..100); # Wesley Ivan Hurt, Jan 13 2017
  • Mathematica
    Table[Floor[3 n (n + 1)/4], {n, 0, 60}]
    LinearRecurrence[{3,-4,4,-3,1},{0,1,4,9,15},60] (* Harvey P. Dale, Jun 04 2023 *)
  • Maxima
    makelist(floor(3*n*(n+1)/4), n, 0, 60);
    
  • PARI
    vector(60, n, n--; floor(3*n*(n+1)/4))
    
  • Python
    [int(3*n*(n+1)/4) for n in range(60)]
    
  • Sage
    [floor(3*n*(n+1)/4) for n in range(60)]
    

Formula

O.g.f.: x*(1 + x + x^2)/((1 + x^2)*(1 - x)^3).
E.g.f.: -(1 - 6*x - 3*x^2)*exp(x)/4 - (1 + i)*(i - exp(2*i*x))*exp(-i*x)/8, where i=sqrt(-1).
a(n) = a(-n-1) = 3*a(n-1) - 4*a(n-2) + 4*a(n-3) - 3*a(n-4) + a(n-5) = a(n-4) + 6*n - 9.
a(n) = 3*n*(n+1)/4 + (i^(n*(n+1)) - 1)/4. Therefore:
a(4*k+r) = 12*k^2 + 3*(2*r+1)*k + r^2, where 0 <= r <= 3.
a(n) = n^2 - floor((n-1)*(n-2)/4).
a(n) = A011865(3*n+2).

A194273 Concentric triangular numbers (see Comments lines for definition).

Original entry on oeis.org

0, 1, 3, 6, 9, 12, 15, 19, 24, 30, 36, 42, 48, 55, 63, 72, 81, 90, 99, 109, 120, 132, 144, 156, 168, 181, 195, 210, 225, 240, 255, 271, 288, 306, 324, 342, 360, 379, 399, 420, 441, 462, 483, 505, 528, 552, 576, 600, 624, 649, 675, 702, 729, 756, 783, 811
Offset: 0

Views

Author

Omar E. Pol, Aug 20 2011

Keywords

Comments

This can be interpreted as a cellular automaton on the infinite hexagonal net. The sequence gives the number of cells "ON" in the structure after n-th stage. A194272 gives the first differences. For a definition without words see the illustration of initial terms in the example section. For other concentric polygonal numbers see A194274, A194275 and A032528.
Also, row sums of an infinite square array T(n,k) in which column k lists 6*k-1 zeros followed by the numbers A008486 (see example).

Examples

			Using the numbers A008486 we can write:
0, 1, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 36,...
0, 0, 0, 0, 0,  0,  0,  1,  3,  6,  9, 12, 15, 18,...
0, 0, 0, 0, 0,  0,  0,  0,  0,  0,  0,  0,  0,  1,...
And so on.
=========================================================
The sums of the columns give this sequence:
0, 1, 3, 6, 9, 12, 15, 19, 24, 30, 36, 42, 48, 55,...
...
Illustration of initial terms:
.                                              o
.                                 o           o o
.                      o         o o         o   o
.             o       o o       o   o       o     o
.      o     o o     o   o     o     o     o       o
. o   o o   o o o   o o o o   o o o o o   o o o o o o
.
. 1    3      6        9          12           15
.
.                                           o
.                        o                 o o
.       o               o o               o   o
.      o o             o   o             o     o
.     o   o           o     o           o   o   o
.    o     o         o   o   o         o   o o   o
.   o   o   o       o   o o   o       o   o o o   o
.  o         o     o           o     o             o
. o o o o o o o   o o o o o o o o   o o o o o o o o o
.
.       19               24                 30
		

Crossrefs

Formula

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

A330451 a(n) = a(n-3) + 20*n - 30 for n > 2, with a(0)=0, a(1)=3, a(2)=13.

Original entry on oeis.org

0, 3, 13, 30, 53, 83, 120, 163, 213, 270, 333, 403, 480, 563, 653, 750, 853, 963, 1080, 1203, 1333, 1470, 1613, 1763, 1920, 2083, 2253, 2430, 2613, 2803, 3000, 3203, 3413, 3630, 3853, 4083, 4320, 4563, 4813, 5070
Offset: 0

Views

Author

Paul Curtz, Mar 01 2020

Keywords

Comments

Main N-S vertical in the pentagonal spiral for A002264:
16
16 10 10
16 9 5 5 10
15 9 4 1 2 5 11
15 9 4 1 0 0 2 6 11
15 8 4 1 0 2 6 11
14 8 3 3 3 6 12
14 8 7 7 7 12
14 13 13 13 12
The main S-N vertical is A194275.

Crossrefs

Cf. A049347.

Programs

  • Mathematica
    Table[2/9(-1+15n^2+Cos[2n*Pi/3]),{n,0,39}] (* Stefano Spezia, Mar 02 2020 *)
  • PARI
    concat(0, Vec(x*(1 + x)*(3 + 4*x + 3*x^2) / ((1 - x)^3*(1 + x + x^2)) + O(x^40))) \\ Colin Barker, Mar 02 2020
    
  • Python
    def A330451(n): return 10*n**2//3 # Chai Wah Wu, Aug 12 2025

Formula

G.f.: x*(1 + x)*(3 + 4*x + 3*x^2) / ((1 - x)^3*(1 + x + x^2)). - Colin Barker, Mar 02 2020
a(n) = a(-n) = 2*a(n-1) - a(n-2) + a(n-3) - 2*a(n-4) + a(n-5).
a(n) = (2/9)*(-1 + 15*n^2 + cos(2*n*Pi/3)). - Stefano Spezia, Mar 02 2020
a(3*n) = 30*n^2.
a(n) = floor(10*n^2/3). - Chai Wah Wu, Aug 12 2025

A281151 a(n) = floor(4*n*(n+1)/5).

Original entry on oeis.org

0, 1, 4, 9, 16, 24, 33, 44, 57, 72, 88, 105, 124, 145, 168, 192, 217, 244, 273, 304, 336, 369, 404, 441, 480, 520, 561, 604, 649, 696, 744, 793, 844, 897, 952, 1008, 1065, 1124, 1185, 1248, 1312, 1377, 1444, 1513, 1584, 1656, 1729, 1804, 1881, 1960, 2040, 2121, 2204, 2289
Offset: 0

Views

Author

Bruno Berselli, Jan 16 2017

Keywords

Crossrefs

Subsequence of A047462.
Partial sums of A047486.
Cf. A184005: n^2 - floor((n-2)^2/4).
Cf. sequences with formula floor(k*n*(n+1)/(k+1)): A000217 (k=1), A143978 (k=2), A281026 (k=3), this sequence (k=4), A194275 (k=5).

Programs

  • Magma
    [4*n*(n+1) div 5: n in [0..60]];
  • Mathematica
    Table[Floor[4 n (n + 1)/5], {n, 0, 60}]
  • Maxima
    makelist(floor(4*n*(n+1)/5), n, 0, 60);
    
  • PARI
    vector(60, n, n--; floor(4*n*(n+1)/5))
    
  • Python
    [int(4*n*(n+1)/5) for n in range(60)]
    
  • Sage
    [floor(4*n*(n+1)/5) for n in range(60)]
    

Formula

O.g.f.: x*(1 + x^2)*(1 + x)^2/((1 - x)^3*(1 + x + x^2 + x^3 + x^4)).
a(n) = a(-n-1) = 2*a(n-1) - a(n-2) + a(n-5) - 2*a(n-6) + a(n-7) = a(n-5) + 8*(n-2).
a(5*k+r) = 20*k^2 + 4*(2*r+1)*k + r^2, where 0 <= r <= 4. Example: for r=3, a(5*k+3) = (2*k+1)*(10*k+9), which gives: 9, 57, 145, 273, 441, 649 etc. Also, a(n) belongs to A047462, in fact: for r = 0 or 4, a(n) == 0 (mod 8); for r = 1 or 3, a(n) == 1 (mod 8); for r = 2, a(n) == 4 (mod 8).
a(n) = a(-n) + A047462(n).
a(n) = n^2 - floor((n-2)^2/5).
Showing 1-6 of 6 results.