I want to produce the following ArrayPlot programmatically:

[![enter image description here](https://i.stack.imgur.com/FUIK2.png)](https://i.stack.imgur.com/FUIK2.png)

To produce the leftmost grid, I tried this:

```
GridBox[{
   {ArrayPlot[{{0, 1, 0}}]},
   {ArrayPlot[{{1, 1, 1}}]}, 
   {ArrayPlot[{{0, 0, 0}}]}}, 
  GridBoxDividers -> {"Rows" -> {{True}}, 
    "Columns" -> {{True}}}] // DisplayForm

```

I'm unsure if this can be tailored to look like I want, or if I should pursue another solution.

edit: the general formula for the plots is an ellementary cellular automaton that inverts its output if the state of its cell is 1 (black) in t-1 (the upper square). The `CellularAutomaton` function can serve as guide.