login
A166872
a(n) = floor(n/2 + 2 - sqrt(17/4 + 2*n)).
1
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,10
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
LINKS
Matthieu Latapy, Roberto Mantaci, Michel Morvan and Ha Duong Phan, Structure of some sand pile model, Theoretical Computer Science 262 (2001), pp. 525-556.
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
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 *)
CROSSREFS
Cf. A056219.
Sequence in context: A085886 A088676 A276797 * A283480 A189575 A216503
KEYWORD
nonn
AUTHOR
Roger L. Bagula, Oct 22 2009
EXTENSIONS
Edited by the associate editors of the OEIS, Nov 09 2009
STATUS
approved