1
$\begingroup$

I have the Mathematica code below to show the game of life rule B3/S23, can you please tell me how I can change it in order to show rule B25/s4 ?

GameOfLife = {224, {2, {{2, 2, 2}, {2, 1, 2}, {2, 2, 2}}}, {1, 1}};
ArrayPlot[CellularAutomaton[GameOfLife, RandomInteger[1, {100, 100}], {{{100}}}]]
$\endgroup$

1 Answer 1

3
$\begingroup$
rules = <|"Dimension" -> 2, "GrowthSurvivalCases" -> {{2, 5}, {4}}|>;
ArrayPlot[CellularAutomaton[rules, RandomInteger[1, {100, 100}], {{{100}}}]]
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.