OFFSET
0,2
COMMENTS
Number of ON cells at n-th generation of 1-D CA defined by Rule 158, starting with a single ON cell at generation 0. Equivalently, number of 1's in n-th row of triangle in A071037. - N. J. A. Sloane, Aug 10 2014
REFERENCES
S. Wolfram, A New Kind of Science, Wolfram Media, 2002; Chapter 3.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
A. J. Macfarlane, Generating functions for integer sequences defined by the evolution of cellular automata with even rule numbers, 2016.
N. J. A. Sloane, Illustration of first 20 generations of Rule 158
FORMULA
G.f.: (-x^3+2x^2+3x+1)/(1-x^2)^2.
a(n) = (5/4)*n + 3/2 + (n/4 - 1/2)*(-1)^n. - Robert Israel, Aug 11 2014
MATHEMATICA
CoefficientList[Series[(-x^3 + 2 x^2 + 3 x + 1)/(1 - x^2)^2, {x, 0, 100}], x] (* Vincenzo Librandi, Aug 11 2014 *)
ArrayPlot[CellularAutomaton[158, {{1}, 0}, 20]] (* N. J. A. Sloane, Aug 11 2014 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Hans Havermann, May 26 2002
EXTENSIONS
Simpler definition from N. J. A. Sloane, Aug 11 2014
STATUS
approved