Diamond. The previous best known position is shown as "0", and the positions to try next as "1".
Hexagon. The "1"s pattern is iterated; the "2"s pattern is run only once after the "1"s have terminated (i.e. once an iteration finds none of the "1"s to be any better than the "0").
Code:
1 1
222
12021
222
1 1
Uneven multihexagon has 3 different search patterns that it runs once each, and then switches to the same pattern as hexagon. I have superimposed the patterns below; they aren't necessarily centered on the same location.
Code:
3
3 3 3
3 3
3 3 3
1
3 3 3 3
1
3 3 3 3 3
3 3 1 3 3
3 3 22222 3 3
3 22122 3
31 131 131 13121012131 131 131 13
3 22122 3
3 3 22222 3 3
3 3 1 3 3
3 3 3 3 3
1
3 3 3 3
1
3 3 3
3 3
3 3 3
3
Exhaustive.
Code:
...
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
...111111111111011111111111...
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
111111111111111111111111
...