-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug fixes in caching and comparison of Wyckoff positions #45
Conversation
The existing test of conjugation of a group's cached Wyckoff positions is expanded to include a translation component (one I checked was non-trivial). I test another group which has point-like Wyckoff positions. And I expand the test of Wyckoff positions to actually test that the cached positions were conjugated correctly (up to mathematical equality, at least).
Comparison of LeftAction Wyckoff Positions could fail. This was because ImageAffineSubspaceLattice failed to account for the matrix being LeftAction. A check has been added, as has a test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Contributions are recorded by the commit metadata. Co-authored-by: Max Horn <[email protected]>
Change grammar of comments. Reference issue gap-packages#42 in comments. Change the test from issue gap-packages#44 to be separate to the existing tests rather than modifying it. Co-authored-by: Max Horn <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, looks really good to me.
Now, instead of duplicating the code, we test for a non-empty basis then apply the linear transformation separately.
The prior fix, checking if a single matrix was left-acting within ImageAffineSubspaceLattice, led to spurious results because that isn't a reliable check. Instead, we now ensure that the group U given to ImageAffineSubspaceLattice is right acting. This was done in other places it had been called, but not in the comparisons.
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## master #45 +/- ##
=======================================
Coverage 94.32% 94.32%
=======================================
Files 24 24
Lines 7572 7582 +10
=======================================
+ Hits 7142 7152 +10
Misses 430 430
|
Fixes for issues #42 and #44 .
Tests for the fixes.
In testing, I came across another bug, where comparison of certain LeftAction WyckoffPositions (with complicated conjugations) would raise errors about rationals being where integers were expected. I traced this down to ImageAffineSubspaceLattice not handling the case of left-acting affine matrices (instead treating them as if they were right-acting).