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.

A166497 A Per Bak sand pile collapse sequence using A147665 in the A153112 form.

This page as a plain text file.
%I A166497 #11 Jul 16 2025 11:32:40
%S A166497 1,1,1,1,2,3,2,2,3,2,2,3,2,2,3,2,2,4,3,2,4,3,2,4,3,2,5,1,2,2,2,2,3,2,
%T A166497 2,4,3,2,4,3,2,4,3,2,5,4,3,5,4,2,5,5,5,5,4,3,6,3,2,4,4,4,4,3,2,5,4,3,
%U A166497 5,5,5,6,3,2,7,3,2,4,5,6,5,4,3,4,3,2,4,3,2,4,1,2,2,2,2,3,2,2,4,3,2,4,3,2,4
%N A166497 A Per Bak sand pile collapse sequence using A147665 in the A153112 form.
%D A166497 Per Bak, "How nature works, the science of self-organized criticality", Springer-Verlag, New York, 1996, pages 49-64
%t A166497 f[0] = 1; f[1] = 1; f[2] = 1;
%t A166497 f[n_] := f[n] = If[Mod[Floor[Sum[f[i], {i, 0, n - 1}]/2], 2^(4 + Mod[n, 3])] == 1, 1 + Mod[n, 3], f[f[n - 1]] + If[Mod[n, 3] == 0, f[f[n/3]], If[Mod[n, 3] == 1, f[f[(n - 1)/3]], f[n - f[(n - 2)/3]]]]];
%t A166497 Table[f[n], {n, 0, 200}]
%Y A166497 Cf. A153112, A147665.
%K A166497 nonn,uned
%O A166497 0,5
%A A166497 _Roger L. Bagula_, Oct 15 2009