Jakube
Veteran
I want to reduce my transition table size for edge permutations in my 3x3x3 solver. By using symmetry, I can reduce it by a factor of 48. I have found a way, of calculating the correct index (between 0 and 12! / 48 - 1) from a random permutation, but it is very complicated.
My method is to bring the piece 0 to the UB posititon by rotating the cube. After this, I bring the smallest piece of the positions UR, UL, BL, BR to position UR (by doing y2 x or mirroring). So I converted all 48 identical permutations into the same one. Now I need to convert this permutation into a unique number between 0 and 12! / 48 - 1. The picture shows the code for this.

I checked the results, and it works. But it is ugly as ...
Is there any nicer way of doing this?
My method is to bring the piece 0 to the UB posititon by rotating the cube. After this, I bring the smallest piece of the positions UR, UL, BL, BR to position UR (by doing y2 x or mirroring). So I converted all 48 identical permutations into the same one. Now I need to convert this permutation into a unique number between 0 and 12! / 48 - 1. The picture shows the code for this.

I checked the results, and it works. But it is ugly as ...
Is there any nicer way of doing this?
Last edited: