identity crisis - Non-deterministic cellular automata
The precise specification is contained in the comments in calcValue(x, y). Roughly speaking:
Cells attempt to shift their hue towards that of their most similar neighbor
If there is a lack of diversity (peers too similar or too equally opposite), shift the hue towards the most different neighbor.
There is a 25% chance to ignore any given neighbor. The start configuration is random.