Advertisement:


DIAMOND CUBIC LIFE

well "life" is a whole other thing, that actually may have started as an attempt to write Go programs on computers but then got derailed into ooh, look at the pretty.

Anyway, a "diamond cubic lattice" has some interesting properties, one of them is that the corners of it -- if you size it right -- are similar to the corners of a Go board, in that the corner has two connections and the sides have three. And the ones in the middle have four.

Just like a plain old square grid. Only it's three-dimensional. Instead of four corners, there are six, and the sides, instead of being the edges of a flat board, are the faces of an octahedron.

So I whipped up a diamond cubic lattice in threejs some years ago, and lately I've been making it work as a go board. Tonight's hacking session has liberty adjustments to capturing groups after a capture debugged, and the way is clear to restoring a board position from a "compact format" which is 55 characters in base 27 instead of 165 characters each representing empty, black, or white. Use @ for zero and hey presto the capital alphabet makes a very nice base 27 notation, what with @ being immediately before A in ASCII, which the Perl guys amusingly call "Texas encoding."

That's what I'm working on. Good night

February 1, 2024, 1:34 AM


Advertisement: