One-row in-place Life update
ID: one-row-in-place-life-update
On a finite rectangular Conway's Game of Life board stored as an array of Boolean variables, retain the preceding row's old values in one auxiliary row. Before overwriting a column, retain rolling sums of the old three-cell vertical columns. Their sum minus the old center is the old neighbor count. Read the next column before changing the current one; replace the saved row entry by the old current cell. The invariant is that every count uses the previous generation, just as in the two-array algorithm. For a board with rows and columns this uses auxiliary storage and time. The boundary convention must still be implemented explicitly. The Life blinker and Life glider provide exact expected generations for checking it.
New to topics? Read the docs here!