Skip to content

Conversation

@mducle
Copy link
Member

@mducle mducle commented Oct 22, 2024

For some reason specifying 'sym', 0 does not turn off symmetry but instead uses 'P 1' which means that rather than making every bond with the same distance equivalent it makes each bond inequivalent. This causes an error in tutorial 4 as noted by a user in #205. Instead an empty 'sym', [] means no symmetry and to use the bond lengths.

This PR adds a check which reverts the 'sym', 0 behaviour of the tutorial, but also changes the tutorial to remove any specification of symmetry (the 'sym' parameter is empty by default).

@codecov-commenter
Copy link

codecov-commenter commented Oct 22, 2024

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 42.58%. Comparing base (d859b68) to head (b00f26a).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #206      +/-   ##
==========================================
- Coverage   42.65%   42.58%   -0.07%     
==========================================
  Files         241      241              
  Lines       16253    16255       +2     
==========================================
- Hits         6933     6923      -10     
- Misses       9320     9332      +12     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions
Copy link

github-actions bot commented Oct 22, 2024

Test Results

    4 files    116 suites   5m 38s ⏱️
  733 tests   705 ✅ 18 💤 3 ❌  7 🔥
2 104 runs  2 040 ✅ 36 💤 8 ❌ 20 🔥

For more details on these failures and errors, see this check.

Results for commit b00f26a.

♻️ This comment has been updated with latest results.

param.sym = param.spgr;
end
end
if ~isempty(param.sym) && isnumeric(param.sym) && param.sym == 0

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fails when symmetry is given as a matrix
`spgr_type=[ 1 0 0 0
0 1 0 0
0 0 1 0]';

Can add && isscalar(param.sym) to the check:
if ~isempty(param.sym) && isnumeric(param.sym)&& isscalar(param.sym) && param.sym == 0,

but it seems like there's also an issue with the label it makes, and I didn't manage to figure out what's supposed to happen there...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants