cubing / cubing.js

🛠 A library for displaying and working with twisty puzzles. Also currently home to the code for Twizzle.
https://js.cubing.net/cubing/
GNU General Public License v3.0
232 stars 42 forks source link

[puzzle-geometry] All moves in GAP output are inverted #284

Closed benwh1 closed 11 months ago

benwh1 commented 11 months ago

Steps to reproduce the issue

  1. Generate GAP output for 3x3x3
  2. Evaluate:
T1 := M_R * M_U * M_R^-1 * M_U^-1 * M_R^-1 * M_F * M_R^2 * M_U^-1 * M_R^-1 * M_U^-1 * M_R * M_U * M_R^-1 * M_F^-1;
T2 := M_R^-1 * M_U^-1 * M_R * M_U * M_R * M_F^-1 * M_R^2 * M_U * M_R * M_U * M_R^-1 * M_U^-1 * M_R * M_F;

where T1 is a T perm algorithm and T2 is T1 but with each move inverted.

Observed behaviour

T1 = (1,10,5,18,13,23)(2,11,6,16,14,24)(3,12,4,17,15,22)(25,42,33,36,31,27)(26,41,34,35,32,28)(49,52,51,50);
T2 = (1,4)(2,5)(3,6)(27,31)(28,32)(49,50,51,52);

T2 is actually a T perm, T1 is something else.

🖼 Screenshots

No response

Expected behaviour

T1 should be a T perm made of 5 2-cycles, T2 should be something else.

Environment

https://alpha.twizzle.net/explore/

Additional info

Also affects #283.

rokicki commented 11 months ago

This should be fixed in commit 4697f79da63feb3c688d73b4d70f76d8b91e3a4d. If the Mathematica pull request needs adjustment, please adjust. Thanks for the bug!

A quick test would be: (M_U M_F M_R)^80 should be the null permutation.

Thank you for the thorough bug report.