Note that I'm only focused on 2x2 block patterns here, so I'll be looking at the simplest outer-totalistic rules that represent each block CA. These rules may or may not have interesting properties outside 2x2 block patterns, but they're not what I'm concerned with here.
Also note that I'm not a CA expert and I did all this on my own, so there might be some open questions, missing stuff, or mistakes in here. If anyone has any insights or corrections, please feel free to share :D
The "methodology"
My process here was pretty informal, and not very in-depth - I'm mostly interested in general properties, so I haven't looked at much more than a few random soups, small objects, and scribbles for each rule. Perhaps more systematic searches could find more stuff, but I wouldn't know where to start :)
To aid with enumerating the rules and making sure I didn't miss any, I came up with a simple Wolfram-like numbering system, where each bit is a specific set of transitions. From most to least significant: S8, B5/S67, B4/S4, B3/S5, B12/S3, and B0. So, for instance, rule 11 (binary 001011) corresponds to B0124/S34. I will be using this shorthand to refer to specific rules sometimes, though I'll always give their rulestring equivalents when introducing them.
I also made some scripts to assist with this, which I'll put at the bottom, so as not to take up a bunch of space here.
The rules
To get this out of the way: there aren't exactly any "Life-like" rules to be found here. Almost every rule is either B1 explosive, or else is incapable of escaping its initial bounding diamond. Strobing B0 rules do pose a theoretical exception to this, and there is in fact a family of B0 rules which are neither B1 explosive nor bounded (though they do still happen to be very explosive), which I'll look at in a bit more detail further down.
Also, many of these rules are black/white reversals of each other (though none are self-complementary). How these will be treated depends on the rule:
- For rules with S8 and no B0 (even rules >= 32), complementary rules can still act quite differently on finite patterns, so I'll largely be treating them separately.
- For rules without B0 or S8 (even rules < 32), their B0/S8 complementary rules (odd rules > 32) will be treated as basically equivalent.
- For strobing B0 rules (odd rules < 32), I'll also be treating their complementary rules as equivalent, though they can sometimes appear to behave slightly different in Golly/LifeViewer due to how they're emulated.
I'll start with a bunch of trivial / uninteresting rule families that I really have nothing to say about. Rules in italics are trivial B/W reversals of the rule immediately before it.
- all finite patterns die: 0 (B/S), 63 (B012345/S345678), 8 (B4/S4), 55 (B01235/S35678), 16 (B5/S67), 61 (B0345/S45678), 24 (B45/S467), 53 (B035/S5678), 32 (B/S8), 40 (B4/S48), 48 (B5/S678), 56 (B45/S4678)
- patterns stabilize after 1 generation: 1 (B0/S), 31 (B012345/S34567)
- nonnotable B1 rules: 2 (B12/S3), 47 (B01234/S3458), 10 (B124/S34), 39 (B0123/S358), 26 (B1245/S3467), 37 (B03/S58), 34 (B12/S38), 38 (B123/S358), 42 (B124/S348), 46 (B1234/S3458), 54 (B1235/S35678), 62 (B12345/S345678)
- nonnotable B1 rules but I kinda like the patterns they make: 6 (B123/S35), 43 (B0124/S348), 14 (B1234/S345), 35 (B012/S38), 22 (B1235/S3567), 41 (B04/S48), 30 (B12345/S34567), 33 (B0/S8), 50 (B125/S3678)
- B0 rules that just act like B1 ones: 17 (B05/S67), 29 (B0345/S4567), 21 (B035/S567), 25 (B045/S467)
Vote-like rules
Rules 3 (B012/S3) and 7 (B0123/S35) exhibit Vote-esque behavior when starting from random patterns, very quickly stabilizing into smoothed-out versions:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 HISTORYSTATES 15 LOOP 25 GPS 8 ]]
x = 80, y = 80, rule = B01234/S345
4b4o8b8o2b8o2b6o2b6o2b4o2b2o4b2o2b2o2b2o$4b4o8b8o2b8o2b6o2b6o2b4o2b2o
4b2o2b2o2b2o$10b16o12b2o6b4o2b2o8b4o4b4o2b2o$10b16o12b2o6b4o2b2o8b4o4b
4o2b2o$2b4o6b2o4b8o4b4o4b4o8b4o2b4o4b2o4b4o$2b4o6b2o4b8o4b4o4b4o8b4o2b
4o4b2o4b4o$10b12o6b2o2b6o6b2o4b2o2b2o2b4o2b4o2b8o$10b12o6b2o2b6o6b2o4b
2o2b2o2b4o2b4o2b8o$8b6o2b2o2b2o2b4o2b2o2b2o2b4o2b10o2b2o8b4o4b2o2b2o$
8b6o2b2o2b2o2b4o2b2o2b2o2b4o2b10o2b2o8b4o4b2o2b2o$2o4b2o16b2o4b6o6b4o
2b4o2b4o4b4o4b8o$2o4b2o16b2o4b6o6b4o2b4o2b4o4b4o4b8o$4b2o8b2o4b2o4b6o
4b4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2b6o6b2o2b12o2b2o4b4o
6b4o8b2o$2o2b8o2b4o2b6o6b2o2b12o2b2o4b4o6b4o8b2o$2b4o10b6o10b4o4b2o2b
2o2b2o8b2o2b8o8b2o$2b4o10b6o10b4o4b2o2b2o2b2o8b2o2b8o8b2o$2o6b8o4b2o2b
2o2b2o2b4o6b6o8b2o4b2o8b8o$2o6b8o4b2o2b2o2b2o2b4o6b6o8b2o4b2o8b8o$6b4o
18b6o2b14o8b2o6b6o2b2o$6b4o18b6o2b14o8b2o6b6o2b2o$2b10o2b2o6b6o2b2o2b
4o2b8o6b14o2b4o$2b10o2b2o6b6o2b2o2b4o2b8o6b14o2b4o$10b4o2b2o4b6o6b4o4b
6o4b2o2b4o6b2o2b6o2b2o$10b4o2b2o4b6o6b4o4b6o4b2o2b4o6b2o2b6o2b2o$4o6b
2o2b2o2b6o20b10o2b2o4b4o2b2o4b4o$4o6b2o2b2o2b6o20b10o2b2o4b4o2b2o4b4o$
2o4b8o4b6o4b2o8b2o2b2o6b4o4b4o2b2o2b2o4b2o$2o4b8o4b6o4b2o8b2o2b2o6b4o
4b4o2b2o2b2o4b2o$4o4b4o2b2o2b4o2b10o2b6o2b2o2b4o2b6o2b2o2b4o2b8o$4o4b
4o2b2o2b4o2b10o2b6o2b2o2b4o2b6o2b2o2b4o2b8o$2o2b2o8b2o2b2o2b2o4b2o6b4o
4b4o6b4o4b2o12b2o$2o2b2o8b2o2b2o2b2o4b2o6b4o4b4o6b4o4b2o12b2o!
Diamond rules
Rules 28 (B345/S4567), 52 (B35/S5678), and 60 (B345/S45678) expand to fill, or nearly fill, their bounding diamonds.
52 and 60 are very similar, creating solid diamonds. I like setting them to a low density and watching them expand to take over most of the pattern:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 270 ZOOM 5 GRID ]]
x = 80, y = 80, rule = B35/S5678
2o2b2o6b2o8b2o18b2o6b2o22b4o$2o2b2o6b2o8b2o18b2o6b2o22b4o$2b2o12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2o10b2o2b4o4b2o2b2o20b2o4b2o$4b2o14b2o2b6o16b2o2b2o24b2o$
4b2o14b2o2b6o16b2o2b2o24b2o$2b2o2b2o2b2o26b2o2b2o6b2o22b2o$2b2o2b2o2b
2o26b2o2b2o6b2o22b2o$4b2o6b2o6b2o2b2o12b2o12b4o6b2o6b2o$4b2o6b2o6b2o2b
2o12b2o12b4o6b2o6b2o!
Rule 28 (B345/S4567) (and its trivial B/W reversal, 49 (B05/S678)), on the other hand, does not create solid diamonds, but instead very chaotic ones:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 270 ZOOM 4 GRID ]]
x = 80, y = 80, rule = B345/S4567
2o8b2o10b2o16b2o2b2o4b2o26b2o$2o8b2o10b2o16b2o2b2o4b2o26b2o$22b2o16b2o
10b2o24b2o$22b2o16b2o10b2o24b2o$2b4o16b2o2b2o6b2o8b2o$2b4o16b2o2b2o6b
2o8b2o$2b4o18b2o24b2o4b2o6b2o8b2o2b2o$2b4o18b2o24b2o4b2o6b2o8b2o2b2o$
2b2o2b2o2b4o2b2o20b2o4b2o6b4o10b2o$2b2o2b2o2b4o2b2o20b2o4b2o6b4o10b2o$
14b4o8b2o16b2o22b2o2b2o$14b4o8b2o16b2o22b2o2b2o$14b2o4b6o2b2o20b2o6b2o
4b2o$14b2o4b6o2b2o20b2o6b2o4b2o$2b2o48b2o2b2o20b2o$2b2o48b2o2b2o20b2o$
2o2b2o10b2o12b2o16b2o4b4o$2o2b2o10b2o12b2o16b2o4b4o$10b2o6b2o48b2o$10b
2o6b2o48b2o$4b2o2b4o4b4o22b2o6b2o10b2o$4b2o2b4o4b4o22b2o6b2o10b2o$8b4o
2b2o2b4o14b6o6b2o2b2o4b2o16b4o$8b4o2b2o2b4o14b6o6b2o2b2o4b2o16b4o$20b
2o26b2o10b2o12b2o$20b2o26b2o10b2o12b2o$26b2o10b6o2b2o10b2o2b2o10b4o$
26b2o10b6o2b2o10b2o2b2o10b4o$8b4o10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2b2o28b2o16b4o14b2o6b2o$4b2o6b2o44b2o6b
2o$4b2o6b2o44b2o6b2o$2b2o8b2o2b2o6b2o2b2o6b6o26b2o6b2o$2b2o8b2o2b2o6b
2o2b2o6b6o26b2o6b2o$2o14b2o14b4o18b2o2b2o8b2o$2o14b2o14b4o18b2o2b2o8b
2o$14b4o6b2o6b2o2b2o18b4o2b2o12b2o$14b4o6b2o6b2o2b2o18b4o2b2o12b2o$6b
2o14b6o16b2o6b2o8b2o8b2o$6b2o14b6o16b2o6b2o8b2o8b2o!
I swear I've seen very similar-looking oscillators in another outer-totalistic rule before, but I can't think of it offhand.
2x2-like rules
Rules 4 (B3/S5), 12 (B34/S45), 20 (B35/S567), 36 (B3/S58), and 44 (B34/S458) all show similar dynamics to the classic 2x2 rule. In fact 4 (B3/S5) is exactly the same as 2x2, and 36 (B3/S58) is what LifeWiki calls 2x2 2. (Rules 59 (B01245/S34678), 51 (B0125/S3678), and 57 (B045/S4678) are trivial B/W reversals of 4, 12, and 20 respectively.)
All of these rules quickly stabilize into oscillators when given random seeds, though 20 (B35/S567) results in notably denser ash and a somewhat larger variety of oscillators compared to the others:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 200 GRID ]]
x = 60, y = 60, rule = B35/S567
4b2o8b4o8b4o4b2o6b10o2b2o$4b2o8b4o8b4o4b2o6b10o2b2o$2o2b6o2b2o6b10o2b
4o4b2o2b2o2b2o6b2o$2o2b6o2b2o6b10o2b4o4b2o2b2o2b2o6b2o$4b4o4b2o2b6o6b
2o12b4o4b2o4b2o$4b4o4b2o2b6o6b2o12b4o4b2o4b2o$2b2o6b8o4b2o2b4o4b2o2b4o
2b10o2b4o$2b2o6b8o4b2o2b4o4b2o2b4o2b10o2b4o$4o4b2o2b4o4b2o2b4o6b2o2b2o
2b2o2b4o4b6o$4o4b2o2b4o4b2o2b4o6b2o2b2o2b2o2b4o4b6o$2o4b4o4b4o4b2o12b
6o2b6o2b6o$2o4b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o6b2o6b6o2b12o$2b2o4b4o4b4o2b2o2b4o2b4o2b4o2b2o4b2o2b2o2b2o$2b2o
4b4o4b4o2b2o2b4o2b4o2b4o2b2o4b2o2b2o2b2o$4o12b2o2b2o12b6o2b4o2b4o4b4o$
4o12b2o2b2o12b6o2b4o2b4o4b4o$6b2o4b2o2b4o6b6o2b2o4b6o10b2o$6b2o4b2o2b
4o6b6o2b2o4b6o10b2o$2b2o2b2o2b4o2b4o4b2o4b2o2b2o2b8o2b2o2b2o4b2o$2b2o
2b2o2b4o2b4o4b2o4b2o2b2o2b8o2b2o2b2o4b2o$6o4b2o6b6o2b8o4b2o2b2o4b2o4b
2o$6o4b2o6b6o2b8o4b2o2b2o4b2o4b2o$10o8b4o6b2o6b2o2b2o4b6o6b2o$10o8b4o
6b2o6b2o2b2o4b6o6b2o$4o2b2o4b2o2b6o4b6o14b4o2b4o$4o2b2o4b2o2b6o4b6o14b
4o2b4o$2o8b6o4b2o2b10o2b4o2b4o2b4o2b4o$2o8b6o4b2o2b10o2b4o2b4o2b4o2b4o!
More notable is their behavior when started with long lines. 4 (2x2) and 20 behave the exact same, resulting in complex oscillators:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GRID ]]
x = 162, y = 2, rule = B3/S5
162o$162o!
36 (2x2 2) also results in oscillators, with different (but related) behavior:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GRID ]]
x = 162, y = 2, rule = B3/S58
162o$162o!
12 instead quickly dies out:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 200 GRID ]]
x = 162, y = 2, rule = B34/S45
162o$162o!
And 44 leaves behind stable objects, reminiscent of Life:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 200 GRID ]]
x = 162, y = 2, rule = B34/S458
162o$162o!
B1 but it's actually interesting
Most B1 rules are pretty boring, but there are a couple with interesting behavior.
Rule 58 (B1245/S34678) is the black/white reversal of 36 (2x2 2), and when started with a complex-enough seed, shows some very complex edge behavior (no preview because you have to run it for a while to see it):
Code: Select all
x = 16, y = 16, rule = B1245/S34678
2o2b4o$2o2b4o$4o4b2o2b4o$4o4b2o2b4o$6b2o2b2o2b2o$6b2o2b2o2b2o$2b4o2b2o
2b2o$2b4o2b2o2b2o$2b2o6b4o$2b2o6b4o$2o2b4o2b2o2b2o$2o2b4o2b2o2b2o$2o4b
6o$2o4b6o$2o2b2o6b2o$2o2b2o6b2o!
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GPS 8 LOOP 33 ZOOM 6 GRID ]]
x = 12, y = 10, rule = B125/S367
2b2o4b2o$2b2o4b2o$2b2o4b2o$2b2o4b2o3$2o8b2o$2o8b2o$2b8o$2b8o!
B2-like expansion
Rules 5 (B03/S5) and 13 (B034/S45) are the only rules that don't stay bounded and don't act like B1 rules. (Rules 27 (B01245/S3467) and 19 (B0125/S367) are the trivial B/W reversals of 5 and 13 respectively.)
Now, it turns out they share similar explosive behavior, but it's more reminiscent of B2 (or perhaps B1e?) expansion than B1(c):
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 LOOP 120 ZOOM 2.5 GRID ]]
x = 4, y = 6, rule = B03/S5
2b2o$2b2o$2b2o$2b2o$2o$2o!
These rules are particularly noteworthy for being, as far as I can tell, the only 2x2 block rules where both stable and infinitely expanding / moving objects can exist. For instance, rule 5 has a large pond as a stable object, and it has a simple replicator:
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GPS 4 LOOP 34 ZOOM 8 GRID ]]
x = 8, y = 27, rule = B03/S5
2b4o$2b4o18$2b4o$2b4o$2o4b2o$2o4b2o$2o4b2o$2o4b2o$2b4o$2b4o!
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GPS 4 LOOP 8 GRID ]]
x = 30, y = 30, rule = B034/S45
4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o7$4o6b6o6b8o$4o6b6o6b8o$4o
6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o7$4o6b6o6b8o$4o6b6o6b8o$4o6b
6o6b8o$4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o$4o6b6o6b8o!
This also means that, I believe, these are the only block rules which can theoretically support spaceships. It's unclear whether either of them actually do in practice, but I have no idea how I'd prove or disprove this.
UPDATE: Apparently there are indeed known spaceships for both of these rules, see this post.
Signals?
Rule 9 (B04/S4) (and its trivial B/W reversal, 23 (B01235/S3567)), while it can't escape its initial bounding box, still seems to show class-4-esque behavior inside its bounding box on random patterns, with regions of chaos that eventually stabilize (no preview because it's hard to see at the small scale I've been using):
Code: Select all
x = 160, y = 160, rule = B04/S4
2b2o2b2o6b2o4b8o4b4o4b16o6b4o2b8o2b2o2b2o4b2o6b20o4b2o2b12o2b4o4b6o$2b
2o2b2o6b2o4b8o4b4o4b16o6b4o2b8o2b2o2b2o4b2o6b20o4b2o2b12o2b4o4b6o$4o2b
4o2b4o4b12o2b4o8b2o4b4o4b2o6b2o2b2o6b2o2b2o12b4o6b4o2b6o2b2o4b4o2b2o2b
2o6b10o2b2o$4o2b4o2b4o4b12o2b4o8b2o4b4o4b2o6b2o2b2o6b2o2b2o12b4o6b4o2b
6o2b2o4b4o2b2o2b2o6b10o2b2o$4o6b2o6b8o2b2o2b4o2b2o4b6o4b14o2b2o4b6o2b
4o4b4o4b10o6b2o4b2o4b2o2b6o10b4o6b2o$4o6b2o6b8o2b2o2b4o2b2o4b6o4b14o2b
2o4b6o2b4o4b4o4b10o6b2o4b2o4b2o2b6o10b4o6b2o$6b2o4b4o4b2o8b10o8b2o2b4o
2b4o2b4o12b2o8b2o2b2o2b2o12b2o4b2o2b4o2b2o2b2o4b4o6b2o6b2o$6b2o4b4o4b
2o8b10o8b2o2b4o2b4o2b4o12b2o8b2o2b2o2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
2b6o4b4o2b4o2b2o6b4o4b6o2b2o$6b2o4b10o4b2o2b2o2b2o4b2o8b4o4b2o2b4o8b2o
2b6o2b6o4b10o8b2o4b6o2b2o2b8o6b4o4b6o$6b2o4b10o4b2o2b2o2b2o4b2o8b4o4b
2o2b4o8b2o2b6o2b6o4b10o8b2o4b6o2b2o2b8o6b4o4b6o!
Code: Select all
#C [[ THUMBNAIL AUTOSTART WIDTH 600 HEIGHT 600 GPS 16 LOOP 70 GRID ]]
x = 50, y = 10, rule = B04/S4
22b2o$22b2o$8b2o12b2o$8b2o12b2o$6o4b40o$6o4b40o$40o4b6o$40o4b6o$40b2o$
40b2o!
Scaling similarity
One interesting property of the classic 2x2 rule (rule 4) is what I'll call "scaling similarity" (for lack of a seemingly well-established term), which means that the rule effectively simulates itself over a larger time scale when patterns are scaled up by factors of 2. For instance, a pattern made of 4x4 blocks will stay as 4x4 blocks every other generation, and simulate the same 2x2 block rule on those generations. A pattern made of 8x8 blocks will do the same, but every 4th generation; and so on.
It turns out scaling similarity is not universal for 2x2 block rules. Here's a list of all the rules which seem to show this behavior, listed together with their B/W reversals:
Code: Select all
0 (B/S), 63 (B012345/S345678) (trivially)
2 (B12/S3), 47 (B01234/S3458)
4 (B3/S5), 59 (B01245/S34678) (2x2)
10 (B124/S34), 39 (B0123/S358)
18 (B125/S367), 45 (B034/S458) (replicator rule)
22 (B1235/S3567), 41 (B04/S48)
26 (B1245/S3467), 37 (B03/S58)
30 (B12345/S34567), 33 (B0/S8)
32 (B/S8), 62 (B12345/S345678)
36 (B3/S58), 58 (B1245/S34678) (2x2 2)
38 (B123/S358), 42 (B124/S348)
Code: Select all
6 (B123/S35), 43 (B0124/S348)
8 (B4/S4), 55 (B01235/S35678)
12 (B34/S45), 51 (B0125/S3678)
14 (B1234/S345), 35 (B012/S38)
16 (B5/S67), 61 (B0345/S45678)
20 (B35/S567), 57 (B045/S4678)
24 (B45/S467), 53 (B035/S5678)
28 (B345/S4567), 49 (B05/S678)
34 (B12/S38), 46 (B1234/S3458)
40 (B4/S48), 54 (B1235/S35678)
44 (B34/S458), 50 (B125/S3678)
48 (B5/S678), 60 (B345/S45678)
52 (B35/S5678), 56 (B45/S4678)
Scripts
Finally, here's a bunch of scripts I made to help with investigating 2x2 block rules.
First, here's one that converts my rule numbers into regular OT rulestrings:
Code: Select all
-- quickly generates any possible 2x2 block rule
-- https://conwaylife.com/wiki/OCA:2%C3%972#Block_evolution
local g = golly()
local gp = require "gplus"
local ruleNum = gp.int(tonumber(g.getstring("Enter 2x2 rule (0-63):")))
if ruleNum < 0 or ruleNum > 63 then g.exit("Given rule is out of range.") end
local bStr = ""
local sStr = ""
local function getbit(num, bit)
return (num >> bit) % 2 == 1
end
if getbit(ruleNum, 0) then -- B0
bStr = bStr .. "0"
end
if getbit(ruleNum, 1) then -- B12/S3
bStr = bStr .. "12"
sStr = sStr .. "3"
end
if getbit(ruleNum, 2) then -- B3/S5
bStr = bStr .. "3"
sStr = sStr .. "5"
end
if getbit(ruleNum, 3) then -- B4/S4
bStr = bStr .. "4"
sStr = sStr .. "4"
end
if getbit(ruleNum, 4) then -- B5/S67
bStr = bStr .. "5"
sStr = sStr .. "67"
end
if getbit(ruleNum, 5) then -- S8
sStr = sStr .. "8"
end
local ruleString = "B"..bStr.."/S"..sStr
g.setrule(ruleString)
g.show("Set rule to "..g.getrule())Code: Select all
-- turns patterns into 2x2 blocks
local g = golly()
if g.empty() then g.exit("Pattern is empty.") end
local rect = g.getrect()
local cells = g.getcells(rect)
local newcells = {}
local n = 1
while n < #cells do
local x, y = cells[n], cells[n+1]
local block = {2*x, 2*y, 2*x + 1, 2*y, 2*x, 2*y + 1, 2*x + 1, 2*y + 1}
for _,v in ipairs(block) do
table.insert(newcells, v)
end
n = n + 2
end
g.select(rect)
g.clear(0)
g.select({})
g.putcells(newcells)
g.fit()Code: Select all
-- draw tool that works entirely in 2x2 blocks
-- left click to place, right click to cycle through parity of 2x2 blocks
local g = golly()
local gp = require "gplus"
--- config ---
local undoKeys = "z ctrl" -- change if your undo isn't ctrl-Z
local redoKeys = "z ctrlshift" -- change if your redo isn't ctrl-shift-Z
--- end config ---
--- history stuff ---
local historyStack = {} -- list of "before" and "after" cell arrays (always in multistate form)
local currHistoryIndex = 0 -- current place in history
local currVisitedCells = {} -- set of cell coordinates in string form, to avoid adding duplicates in a history state
local function createNewHistory()
currHistoryIndex = currHistoryIndex + 1
historyStack[currHistoryIndex] = {before = {}, after = {}}
-- delete future states that are now invalid
for i,v in ipairs(historyStack) do
if i > currHistoryIndex then
table.remove(historyStack, i)
end
end
currVisitedCells = {}
end
local function setCellBefore(x, y, state)
historyStack[currHistoryIndex].before = g.join(historyStack[currHistoryIndex].before, {x, y, state})
end
local function setCellAfter(x, y, state)
historyStack[currHistoryIndex].after = g.join(historyStack[currHistoryIndex].after, {x, y, state})
end
local function undo()
if currHistoryIndex > 0 then
g.putcells(historyStack[currHistoryIndex].before, 0, 0, 1, 0, 0, 1, "copy")
currHistoryIndex = currHistoryIndex - 1
end
end
local function redo()
if currHistoryIndex < #historyStack then
currHistoryIndex = currHistoryIndex + 1
g.putcells(historyStack[currHistoryIndex].after, 0, 0, 1, 0, 0, 1, "copy")
end
end
--- end history stuff ---
local function getBlockCoords(x, y, offsetX, offsetY)
return math.floor((x - offsetX) / 2) * 2 + offsetX, math.floor((y - offsetY) / 2) * 2 + offsetY
end
local function coordsStr(x, y) -- tables can't be used as table keys but strings can
return tostring(x).." "..tostring(y)
end
local function setBlock(blockX, blockY, state)
local x, y
for x = blockX, blockX + 1 do
for y = blockY, blockY + 1 do
if not currVisitedCells[coordsStr(x, y)] then
setCellBefore(x, y, g.getcell(x, y))
g.setcell(x, y, state)
setCellAfter(x, y, state)
currVisitedCells[coordsStr(x, y)] = true
end
end
end
end
local offsets = { {0, 0}, {1, 1}, {1, 0}, {0, 1} }
local function update()
local modIndex = 0
-- gets the current pattern's offset, using the leftmost and topmost cell coordinates
-- apparently the offsets work fine even if they're not strictly 0 or 1
local offsetX, offsetY = table.unpack(#g.getrect() > 0 and g.getrect() or {0, 0})
local drawing = false
local drawingState
local oldBlockX, oldBlockY
while true do
local event = g.getevent()
--if #event > 0 then g.show(event) end -- show event for debugging
if event:find("click") == 1 and not event:find("middle") then
local evt, x, y, button, mods = gp.split(event)
if button == "left" then
-- start drawing
drawing = true
local blockX, blockY = getBlockCoords(x, y, offsetX, offsetY)
local cellState = g.getcell(blockX, blockY)
drawingState = g.getoption("drawingstate")
if cellState == drawingState then drawingState = 0 end
createNewHistory()
setBlock(blockX, blockY, drawingState)
elseif button == "right" then
modIndex = (modIndex + 1) % 4
offsetX = offsets[modIndex + 1][1]
offsetY = offsets[modIndex + 1][2]
end
elseif event == "mup left" then
drawing = false
elseif not drawing and event == "key "..undoKeys then
undo()
elseif not drawing and event == "key "..redoKeys then
redo()
else
if #event > 0 then g.doevent(event) end -- pass event as-is
local mousepos = g.getxy()
if #mousepos == 0 then
drawing = false -- end drawing when mouse goes outside viewport (mouseup events aren't processed there)
else
local x, y = gp.split(mousepos)
local blockX, blockY = getBlockCoords(tonumber(x), tonumber(y), offsetX, offsetY)
if not (blockX == oldBlockX and blockY == oldBlockY) then
g.select{blockX, blockY, 2, 2}
if drawing then
setBlock(blockX, blockY, drawingState)
oldBlockX, oldBlockY = blockX, blockY
end
end
end
end
g.update()
end
end
g.show("Left click to add/remove 2x2 blocks. Right click to change the parity of the blocks.")
local oldcursor = g.getcursor()
g.setcursor("Draw")
local oldselrect = g.getselrect()
local status, err = xpcall(update, gp.trace)
if err then g.continue(err) end
-- the following code is executed even if error occurred or user aborted script
g.setcursor(oldcursor)
g.select(oldselrect)
Code: Select all
# adapted from https://conwaylife.com/forums/viewtopic.php?f=9&t=45&p=147334#p147334
# full INT support was not really necessary (in fact i think this breaks on INT rules)
# but this was the first script i found that did the work for me LOL
import golly as g
Hensel = [
['0'],
['1c', '1e'],
['2a', '2c', '2e', '2i', '2k', '2n'],
['3a', '3c', '3e', '3i', '3j', '3k', '3n', '3q', '3r', '3y'],
['4a', '4c', '4e', '4i', '4j', '4k', '4n', '4q', '4r', '4t', '4w', '4y', '4z'],
['5a', '5c', '5e', '5i', '5j', '5k', '5n', '5q', '5r', '5y'],
['6a', '6c', '6e', '6i', '6k', '6n'],
['7c', '7e'],
['8']
]
HenselC = [
['8'],
['7c', '7e'],
['6a', '6c', '6e', '6i', '6k', '6n'],
['5a', '5c', '5e', '5i', '5j', '5k', '5n', '5q', '5r', '5y'],
['4a', '4e', '4c', '4t', '4y', '4k', '4r', '4w', '4n', '4i', '4q', '4j', '4z'],
['3a', '3c', '3e', '3i', '3j', '3k', '3n', '3q', '3r', '3y'],
['2a', '2c', '2e', '2i', '2k', '2n'],
['1c', '1e'],
['0']
] #Used for computing the inverse of a transition
def parseTransitions(ruleTrans):
ruleElem = []
if not ruleTrans:
return ruleElem
context = ruleTrans[0]
bNonTot = False
bNegate = False
for ch in ruleTrans[1:] + '9':
if ch in '0123456789':
if not bNonTot:
ruleElem += Hensel[int(context)]
context = ch
bNonTot = False
bNegate = False
elif ch == '-':
bNegate = True
ruleElem += Hensel[int(context)]
else:
bNonTot = True
if bNegate:
ruleElem.remove(context + ch)
else:
ruleElem.append(context + ch)
return ruleElem
#invert a rule in place
def invertRule(rule):
# Parse rule string to list of transitions for Birth and Survival
Bstr, Sstr = rule.split('/')
Bstr = Bstr.lstrip('B')
Sstr = Sstr.lstrip('S')
b = parseTransitions(Bstr)
s = parseTransitions(Sstr)
def cTrans(x): #Calculate the B/W reversal of a list of transitions
H = []; HC = [] #Load flattened transition list
for n in range(9):
H.extend(Hensel[n])
HC.extend(HenselC[n])
for trans in x:
i = H.index(trans)
HC[i] = ''
return ''.join(HC)
cRule = 'B' + cTrans(s) + '/S' + cTrans(b)
g.show(cRule)
g.setrule(cRule)
return g.getrule()
rule = invertRule(g.getrule())
# delete irrelevant transitions for 2x2 (B678, S012)
rule = rule.split("/")
for b in "678":
rule[0] = rule[0].replace(b, "")
for s in "012":
rule[1] = rule[1].replace(s, "")
rule = str.join("/", rule)
g.setrule(rule)
g.show("Set rule to " + rule)
g.setclipstr(rule)