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-4 of 4 results.

A349991 For any n >= 0, consider a sandpile model on the infinite hexagonal lattice starting with n grains at the origin, the other sites being empty; a(n) gives the number of nonempty sites after stabilization of this sandpile model.

Original entry on oeis.org

0, 1, 1, 1, 1, 1, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 18, 19, 19, 19, 19, 19, 18, 19, 19, 19, 19, 19, 18, 19, 19, 19, 19, 19, 18, 19, 19, 19, 19, 19, 18, 19, 19, 19, 19, 19, 18, 19, 19, 19, 19, 19, 24, 25
Offset: 0

Views

Author

Rémy Sigrist, Dec 08 2021

Keywords

Comments

A site is unstable when it holds 6 or more grains.
As long as there is an unstable site:
- choose such an unstable site,
- remove 6 grains from this site and add 1 grain to each of its six neighbors.
This procedure is guaranteed to result in a stable configuration, which does not depend on the order in which we treat the unstable sites.

Examples

			For n = 54:
- after stabilization, we have the following configuration:
             2
          4     4
       2     3     2
          3     3
       4           4
          3     3
       2     3     2
          4     4
             2
- we have 18 nonnempty sites,
- so a(54) = 18.
		

Crossrefs

Cf. A349990.

Formula

a(6*n) + 1 = a(6*n + k) for k = 1..5.

A350188 Consider a 2D sandpile model where each site with 3 or more grains, say at location (x, y), topples and transfers one grain of sand to the sites at locations (x+1, y-1), (x+1, y) and (x+1, y+1); a(n) gives the number of nonempty sites after stabilization of a configuration starting with n grains at the origin.

Original entry on oeis.org

0, 1, 1, 3, 4, 4, 3, 4, 4, 7, 8, 8, 10, 11, 11, 10, 11, 11, 14, 15, 15, 17, 18, 18, 17, 18, 18, 21, 22, 22, 24, 25, 25, 24, 25, 25, 27, 28, 28, 30, 31, 31, 30, 31, 31, 36, 37, 37, 39, 40, 40, 39, 40, 40, 39, 40, 40, 42, 43, 43, 42, 43, 43, 45, 46, 46, 48, 49
Offset: 0

Views

Author

Rémy Sigrist, Mar 09 2022

Keywords

Comments

Sites containing 0, 1 or 2 grains are stable.
After stabilization, there are:
- 2*a(n) - n sites with one grain,
- n - a(n) sites with two grains.

Examples

			For n = 10 :
- the model evolves (for example) as follows:
                       1          1
            3        . 2        . 2 1
  10  ->  1 3  ->  1 . 3  ->  1 . . 1
            3        . 2        . 2 1
                       1          1
- there are 8 nonempty sites in the stabilized configuration,
- so a(10) = 8.
		

Crossrefs

Programs

  • PARI
    a(n) = { my (s=[n], v=0); for (k=-1, oo, if (vecmax(s)==0, return (v), v += sum(k=1, #s, s[k]%3>0); s \= 3; s = concat([ s , [0], [0]]) + concat([[0],  s , [0]]) + concat([[0], [0],  s ]); while (#s>2 && s[1]==0, s = s[2..#s-1]))) }

Formula

a(3*n) + 1 = a(3*n + 1) = a(3*n + 2).

A351784 Number of cells containing one or more grains of sand after n grains of sand are added to one cell in an initially empty and infinite 3D cubic grid for the 3D sandpile model.

Original entry on oeis.org

0, 1, 1, 1, 1, 1, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 6, 7, 7, 7, 7, 7, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25, 25, 25, 25, 24, 25, 25
Offset: 0

Views

Author

Keywords

Comments

The 3D sandpile model follows the same rules as the 2D model except that cells topple and transfer one grain of sand to their six nearest neighbors when the cell contains 6 or more grains. Cells containing 0 to 5 grains are stable.

Crossrefs

Cf. A351783, A351379, A349990 (2D version), A307652, A259013, A180230.

A352226 Consider a 2D sandpile model where each site with 2 or more grains, say at location (x, y), topples and transfers one grain of sand to the sites at locations (x+1, y) and (x, y+1). Let S(n) be the configuration after stabilization of a configuration with n grains at the origin. a(n) = Max_{ (x,y) in S(n) } (x+y).

Original entry on oeis.org

0, 1, 1, 3, 3, 3, 3, 5, 5, 5, 5, 7, 7, 7, 7, 9, 9, 9, 9, 9, 9, 9, 9, 11, 11, 11, 11, 13, 13, 13, 13, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 17, 17, 17, 17, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 21, 21, 21, 21, 23, 23, 23, 23, 23, 23, 23, 23
Offset: 1

Views

Author

Rémy Sigrist, Mar 08 2022

Keywords

Comments

Sites containing 0 or 1 grain are stable. S(n) contains n elements.

Examples

			For n = 15:
- S(15) corresponds to the following configuration:
    4|  X X X
    3|X   X   X
    2|X     X X
    1|X       X
    0|X X X X
     +---------
      0 1 2 3 4
- x+y is maximized for (x,y) = (4,3) and (3,4),
- so a(15) = 3+4 = 7.
		

Crossrefs

Programs

  • PARI
    a(n) = { my (s=[n]); for (k=-1, oo, if (vecmax(s)==0, return (k), s \= 2; s = concat(0, s) + concat(s, 0); if (#s>2 && s[1]==0, s = s[2..#s-1]))) }
Showing 1-4 of 4 results.