Skip to content
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

Incorrect Default Symmetry Operation in P1 Space Group Returns Three Projection Operations Instead of Identity #4230

Open
ztn9709 opened this issue Dec 20, 2024 · 0 comments
Labels

Comments

@ztn9709
Copy link

ztn9709 commented Dec 20, 2024

Python version

Python 3.12

Pymatgen version

2024.10.29

Operating system version

No response

Current behavior

When a structure does not contain any _symmetry_equiv_pos_as_xyz keys and pymatgen defaults to the P1 space group, the code currently generates three symmetry operations based on ("x", "y", "z"). This results in three separate projection operations along each axis rather than a single identity operation, which P1 space group should have.

in class pymatgen.io.cif.CifParser, method get_symops
if not sym_ops: msg = "No _symmetry_equiv_pos_as_xyz type key found. Defaulting to P1." warnings.warn(msg) self.warnings.append(msg) sym_ops = [SymmOp.from_xyz_str(s) for s in ("x", "y", "z")]

Expected Behavior

It should be: sym_ops = [SymmOp.from_xyz_str(s) for s in ["x,y,z"]] to get correct result.

Minimal example

No response

Relevant files to reproduce this bug

No response

@ztn9709 ztn9709 added the bug label Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant