|
|
A265379
|
|
Binary representation of the n-th iteration of the "Rule 158" elementary cellular automaton starting with a single ON (black) cell.
|
|
3
|
|
|
1, 111, 11101, 1110011, 111011101, 11100110011, 1110111011101, 111001100110011, 11101110111011101, 1110011001100110011, 111011101110111011101, 11100110011001100110011, 1110111011101110111011101, 111001100110011001100110011, 11101110111011101110111011101
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,2
|
|
LINKS
|
Eric Weisstein's World of Mathematics, Rule 158
|
|
FORMULA
|
a(n) = 10001*a(n-2) - 10000*a(n-4) for n>3.
G.f.: (1+111*x+1100*x^2-100*x^3) / ((1-x)*(1+x)*(1-100*x)*(1+100*x)).
(End)
|
|
EXAMPLE
|
First 12 rows:
1
1 1 1
1 1 1 0 1
1 1 1 0 0 1 1
1 1 1 0 1 1 1 0 1
1 1 1 0 0 1 1 0 0 1 1
1 1 1 0 1 1 1 0 1 1 1 0 1
1 1 1 0 0 1 1 0 0 1 1 0 0 1 1
1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1
1 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1
1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1
1 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1
1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0 1
(End)
|
|
MATHEMATICA
|
rule = 158; rows = 20; Table[FromDigits[Table[Take[CellularAutomaton[rule, {{1}, 0}, rows-1, {All, All}][[k]], {rows-k+1, rows+k-1}], {k, 1, rows}][[k]]], {k, 1, rows}]
|
|
PROG
|
(Python) print([(11100 - (n%2))*100**n//9999 for n in range(30)]) # Karl V. Keller, Jr., Sep 20 2021
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|