-
Notifications
You must be signed in to change notification settings - Fork 61
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
Reorganize the supergroup function #181
Comments
|
from pyxtal import pyxtal
import pymatgen.analysis.structure_matcher as sm
paras = [
('0-G62', '2-G71'),
('0-G62', '3-G139'),
('0-G62', '4-G225'),
]
for para in paras:
(cif1, cif2) = para
s1 = pyxtal()
s2 = pyxtal()
s1.from_seed('pyxtal/database/cifs/'+cif1+'.cif')
s2.from_seed('pyxtal/database/cifs/'+cif2+'.cif')
pmg_s2 = s2.to_pymatgen()
strucs, _, _ = s2.get_transition(s1)
if strucs is not None:
# high symmetry structure in subgroup representation
struc_G_in_H = strucs[-1]
s3 = pyxtal()
s3.from_seed(struc_G_in_H.to_pymatgen(), tol=1e-3)
# Match in space group number
print("Space group", s3.group.number == s2.group.number)
# Match in structure
pmg_s3 = s3.to_pymatgen()
print("Structure", sm.StructureMatcher().get_rms_dist(pmg_s2, pmg_s3))
else:
print("Problem in ", cif1, cif2) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The current functions is a bit messy. Needs a better organization so that one can easily do
1, search for pseudo symmetry
2, find the mapping between two symmetry-related structures.
The text was updated successfully, but these errors were encountered: