Animations for graph rewrite rules
The graph rewrite rules from https://github.com/Quantomatic/zxlive/commit/44cf15e431fbf094108d3855668c7b27a84ff949 are missing animations
How can I fuse two phase gadgets? I've selected two below, but the "fuse phase gadgets" rewrite action is still disabled.
This applies to phase gadgets in graph-like form if I'm not mistaken. So if you colour-change the red ones and fuse the green spiders, it should match.
Ah okay, is this what you mean?
This also isn't enabling the rewrite, so I'm probably missing something
Hmm that's weird. I believe that should be matching. Not sure why it isn't working. Maybe because it is connected directly to the boundaries?
Tried adding some vertices between the boundaries with no luck. I was wondering if we could use some DSL for graphs that would allow us more easily create matchers, as it isn't obvious when looking at the matcher's code, why it isn't registering the match. What do you think?
Ah, I see why it doesn't match. The matcher in pyzx checks that the phase is non-Clifford first. I don't really remember why I did it this way. I think that check can be removed without breaking anything. This is indeed confusing behaviour.