Let \(L\) be the language of strings of length \(3\) over the alphabet \(\{0, 1\}\) containing at most one occurrence of \(1\). Each position is represented by a color: ⬤,⬤ and ⬤. The complex representing \(L\) is a triangle (the picture on the right below).
There is a function \(f:\{0,1\}^3\to\{0,1\}^3\) whose image is \(L\), and such that the value of \(f(x)\) at a position \(i\in\{0,1,2\}\) only depends on the values of \(x\) at the other two positions. Specifically, \(f(a,b,c)=(b\land \neg c, c\land \neg a, a\land \neg b)\).
Each \(i\) has a partial view on the input \(x\), sufficient to evaluate \(f(x)\) at position \(i\). This structure can be represented as a simplicial complex: the triangles are the inputs of \(f\) and the vertices are the local views of the positions on these inputs (picture on the left below).
The function \(f\) can then be represented as a color-preserving simplicial map from the input complex to the output complex representing \(L\), and the animation below shows how this map works.