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.

A166869 a(n) = n * A056219(n+1).

Original entry on oeis.org

2, 4, 12, 20, 30, 54, 91, 120, 171, 250, 374, 504, 663, 854, 1170, 1568, 2074, 2628, 3325, 4180, 5313, 6754, 8602, 10656, 13100, 16042, 19683, 24024, 29464, 36000, 43834, 52768, 63228, 75582, 90510, 107856, 128575, 153178, 182208, 215400
Offset: 1

Views

Author

Roger L. Bagula, Oct 22 2009

Keywords

Crossrefs

Programs

  • Magma
    max:=50;
    R:=PowerSeriesRing(Integers(), max); b:= Coefficients(R!( (&+[x^Binomial(n+1,2)*(&*[x + 1/(1-x^j): j in [1..n]]): n in [1..Floor(Sqrt(9+8*max)/2)]]) ));
    [(n-1)*b[n]: n in [2..max-1]]; // G. C. Greubel, Nov 29 2019
    
  • Maple
    N:= 100; b:= seq(coeff(series(add(x^((1/2)*n*(n+1))*mul(x +1/(1-x^k), k=1..n), n = 1..floor((1/2)*sqrt(9+8*N))), x, N+2), x, j), j = 1..N+1); seq(n*b[n+1], n=1..N); # G. C. Greubel, Nov 29 2019
  • Mathematica
    max:= 100; b:= CoefficientList[Series[Sum[x^(n*(n+1)/2)*Product[(x +1/(1-x^k)), {k, n}], {n, Floor[Sqrt[9 +8*(max+5)]/2]}], {x, 0, max+5}], x]; Table[n*b[[n + 2]], {n, max}] (* G. C. Greubel, Nov 29 2019 *)
  • Sage
    max=50;
    def A056219_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( sum(x^binomial(n+1,2)*product((x + 1/(1-x^j)) for j in (1..n)) for n in (1..floor(sqrt(9+8*max)/2))) ).list()
    b=A056219_list(max);
    [(n-1)*b[n] for n in (2..max)] # G. C. Greubel, Nov 29 2019

A166870 a(n) = n*(n-1)*A056219(n+1).

Original entry on oeis.org

4, 24, 60, 120, 270, 546, 840, 1368, 2250, 3740, 5544, 7956, 11102, 16380, 23520, 33184, 44676, 59850, 79420, 106260, 141834, 189244, 245088, 314400, 401050, 511758, 648648, 824992, 1044000, 1315020, 1635808, 2023296, 2494206, 3077340
Offset: 2

Views

Author

Roger L. Bagula, Oct 22 2009

Keywords

Crossrefs

Programs

  • Magma
    max:=50;
    R:=PowerSeriesRing(Integers(), max); b:= Coefficients(R!( (&+[x^Binomial(n+1,2)*(&*[x + 1/(1-x^j): j in [1..n]]): n in [1..Floor(Sqrt(9+8*max)/2)]]) ));
    [(n-1)*(n-2)*b[n]: n in [3..max-1]]; // G. C. Greubel, Nov 29 2019
    
  • Maple
    N:= 100; b:= seq(coeff(series(add(x^((1/2)*n*(n+1))*mul(x +1/(1-x^k), k=1..n), n = 1..floor((1/2)*sqrt(9+8*N))), x, N+2), x, j), j = 1..N+1); seq(n*(n-1)*b[n+1], n=2..N); # G. C. Greubel, Nov 29 2019
  • Mathematica
    max:= 100; b:= CoefficientList[Series[Sum[x^(n*(n+1)/2)*Product[(x +1/(1-x^k)), {k, n}], {n, Floor[Sqrt[9 +8*(max+5)]/2]}], {x, 0, max+5}], x]; Table[n*b[[n + 2]], {n, 2, max}] (* G. C. Greubel, Nov 29 2019 *)
  • Sage
    max=50;
    def A056219_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( sum(x^binomial(n+1,2)*product((x + 1/(1-x^j)) for j in (1..n)) for n in (1..floor(sqrt(9+8*max)/2))) ).list()
    b=A056219_list(max);
    [(n-1)*(n-2)*b[n] for n in (3..max)] # G. C. Greubel, Nov 29 2019

A180230 a(n) is the minimal number of additions needed to grow to radius n, in the two-dimensional abelian sandpile growth model with h=2.

Original entry on oeis.org

2, 6, 10, 22, 26, 50, 66, 78, 122, 142, 154, 194, 254, 270, 342, 386, 418, 490, 518, 578, 654, 698, 766, 914, 942, 1074, 1150, 1178, 1310, 1366, 1410, 1570, 1646, 1794, 1894, 2054, 2130, 2246, 2406, 2466, 2654, 2742, 2894, 3006, 3138, 3318, 3582, 3670, 3826
Offset: 0

Views

Author

Anne Fey (a.c.fey-denboer(AT)tudelft.nl), Aug 17 2010

Keywords

Comments

The abelian sandpile growth model starts with height h on every site of the square grid.
An addition increases the height of the origin by 1. After each addition, the model is stabilized by toppling unstable sites.
A site is unstable if its height is at least 4; in a toppling, its height decreases by 4 and the height of its neighbors increases by 1.
If h=2, then for any number of additions, the set of sites that toppled at least once is a square. This was proved in Fey-Redig-2008.
For all n, a(n) <= (2n+3)^2. In Fey-Levine-Peres-2010, it was proved that for n large enough, a(n) >= Pi/4 n^2.

Examples

			After 2 additions, the origin is unstable and topples once. Then every site is stable. Therefore a(0)=2.
After 4 more additions, the origin topples again. Then more sites become unstable, so that the set of sites that toppled at least once becomes the square with radius 1. Therefore a(1) = 6.
		

Crossrefs

Extensions

More terms from Rémy Sigrist, Dec 15 2021

A292726 a(n) is the number of states that can be achieved when starting from n piles each containing one stone, where any number of stones can be transferred between piles that start with the same number of stones.

Original entry on oeis.org

1, 2, 2, 5, 6, 8, 14, 22, 27, 38, 55, 70, 100, 130, 167, 231, 296, 371, 489, 618, 775, 995, 1254, 1549, 1951, 2428, 2980, 3707, 4564, 5549, 6841, 8349, 10085, 12300, 14862, 17894, 21636, 26004, 31082, 37308, 44582, 53024, 63260, 75160, 88931, 105545, 124753, 147034, 173510, 204174
Offset: 1

Views

Author

Peter Kagey, Sep 21 2017

Keywords

Comments

This sequence is bounded above by A000041.
Conjecture: A000041(n) - a(n) = 0 if and only if n is a power of 2, and
Conjecture: A000041(n) - a(n) = 1 if and only if n is an odd prime.
Order does not matter: a state containing one pile of two stones and one pile of three stones is considered the same as a state containing one pile of three stones and one pile of two stones.
A056219 is the analogous sequence when only one stone can be moved between piles, and A018819 is the analogous sequence when all stones must be moved between piles. - Peter Kagey, Sep 24 2017
Consider the inverse operation: either divide an even stack in two, or replace two stacks of equal parity with their averages. The states which have no inverse moves are precisely those with all parts equal and odd. If n is a power of two, its only odd divisor is 1 and so every state can be inverted to the all-ones state, and if n is an odd prime then the only states which cannot be inverted are the all-ones state and [n]. If n has an odd divisor d with 1 < d < n, then unreachable states include the all-d's state and any state obtainable from it by combining d's in pairs, of which there is at least one. Therefore, both conjectures are true. - Charlie Neder, Jan 28 2019

Examples

			For n = 5, the a(5) = 6 states are:
(1 1 1 1 1), (2 1 1 1), (2 2 1), (3 1 1), (3 2), and (4 1).
To reach state (3 2) starting from (1 1 1 1 1):
(1 1 1 1 1) -> (2 1 1 1) -> (2 2 1) -> (3 1 1) -> (3 2).
		

Crossrefs

Extensions

a(44)-a(50) from Charlie Neder, Jan 28 2019

A307097 Number of configurations in the repeating cycle of the sandpile model in a bounded square of size 2n+1.

Original entry on oeis.org

2, 4, 4, 4, 6, 6, 8, 6, 10, 18, 26, 10, 10, 8, 12, 30, 8, 32, 14, 32, 52, 26, 60, 52, 34, 74, 14, 80, 36, 38, 24, 54, 26, 30, 36, 58, 22, 14, 26, 36, 38, 20, 36, 60, 24, 24, 18, 14, 24, 34, 70, 104, 48, 56, 36, 50, 50, 48, 152, 28, 110, 30, 172, 64, 104, 158, 150, 60, 36, 186, 52, 50
Offset: 1

Views

Author

Scott R. Shannon, Mar 24 2019

Keywords

Comments

The Abelian sandpile model considers the behavior of grains of sand on a square grid when a square topples sand to its nearest neighbors when the number of grains in the square is greater than or equal to 4, where 4 is the number of nearest neighbors. If the grid is instead bounded by a square box then it is natural to extend this rule so that squares on the border also topple when they contain more or the same number of grains as the number of their nearest neighbors, i.e., 2 for corner squares, 3 for edge squares. Unlike the standard Abelian sandpile model on a finite grid, the square grid in this model does not lose sand, and assuming one keeps adding sand to the grid after each topple stabilization, eventually a critical number of grains will be added such that the resulting configurations will cycle. This sequence {a(n)} is the number of configurations in the cycle, for the sandpile model bounded by a square of size 2n+1, assuming the square grid starts with no sand and sand is continuously added to the center square until a cycle first occurs. As the toppling in a given area will repeat indefinitely, once the repeating cycle state is reached, one cannot topple the unstable squares in any random order and reach a stable configuration. To avoid such issues all squares are toppled simultaneously.

Examples

			For n=1 the square size is 2*1+1 = 3. The number of sand grains in each square is shown below, after the addition of 4, 8 and 12 grains to the central square:
.
   After 4         After 8         After 12
+---+---+---+   +---+---+---+   +---+---+---+
| 0 | 1 | 0 |   | 0 | 2 | 0 |   | 0 | 3 | 0 |
+---+---+---+   +---+---+---+   +---+---+---+
| 1 | 0 | 1 |   | 2 | 0 | 2 |   | 3 | 0 | 3 |
+---+---+---+   +---+---+---+   +---+---+---+
| 0 | 1 | 0 |   | 0 | 2 | 0 |   | 0 | 3 | 0 |
+---+---+---+   +---+---+---+   +---+---+---+
.
The edge squares now contain 3 grains, which means they are unstable as 3 equals their nearest neighbor count. This configuration thus topples to:
.
+---+---+---+
| 2 | 0 | 2 |
+---+---+---+
| 0 | 4 | 0 |
+---+---+---+
| 2 | 0 | 2 |
+---+---+---+
.
The central square is again unstable, as are the four corner squares as they contain 2 grains. This configuration topples to:
.
+---+---+---+
| 0 | 3 | 0 |
+---+---+---+
| 3 | 0 | 3 |
+---+---+---+
| 0 | 3 | 0 |
+---+---+---+
.
This is the same as the configuration after 12 grains above. These last two configurations cycle forever, thus a(1) = 2.
		

Crossrefs

Cf. A007341 (order of the sandpile group of the (n-1)X(n-1) grid graph).

A166872 a(n) = floor(n/2 + 2 - sqrt(17/4 + 2*n)).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 3, 4, 4, 5, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 10, 10, 10, 11, 11, 12, 12, 12, 13, 13, 14, 14, 14, 15, 15, 15, 16, 16, 17, 17, 18, 18, 18, 19, 19, 20, 20, 20, 21, 21, 22, 22, 22, 23, 23, 24, 24, 24, 25, 25, 26, 26, 27, 27, 27, 28, 28, 29
Offset: 1

Views

Author

Roger L. Bagula, Oct 22 2009

Keywords

Comments

Each nonnegative integer k occurs 2 to 6 times in the sequence, with 0 occurring 6 times, 3 occurring 4 times, all others either 2 or 3 times. Conjecture: The sequence of integers k which occur 3 times has the g.f. (1 + 2*x^2 - 2*x^3 + x^6 - x^8 - x^9 + x^11)/(1 - 2*x + x^2 - x^8 + 2*x^9 - x^10). - Robert Israel, May 27 2016

Crossrefs

Cf. A056219.

Programs

  • Maple
    nk:= k -> ceil(2*(k+1)+sqrt(16*k+17)) - ceil(2*k+sqrt(16*k+1)):
    seq(k$nk(k), k=0..50); # Robert Israel, May 27 2016
  • Mathematica
    Table[Floor[n/2 + 2 - Sqrt[2*n + 17/4]], {n, 1, 100}] (* G. C. Greubel, May 27 2016 *)

Formula

a(n) = floor(n/2 + 2 - sqrt(17/4 + 2*n)).
a(n) = k iff ceiling(2*k + sqrt(16*k+1)) <= n <= ceiling(2*k + 3 + sqrt(16*k+17)). - Robert Israel, May 27 2016

Extensions

Edited by the associate editors of the OEIS, Nov 09 2009
Showing 1-6 of 6 results.