We explain a correspondence between some invariants in the dynamics of color exchange in a 2d coloring problem, which are polynomials of winding numbers, and linking numbers in 3d. One invariant is visualized as linking of lines on a special surface with Arf-Kervaire invariant one, and is interpreted as resulting from an obstruction to transform the surface into its chiral image with special continuous deformations. We also consider additional constraints on the dynamics and see how the surface is modified.