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

Q points when symmetries are deactivated #23

Open
mesonepigreco opened this issue Jun 3, 2020 · 2 comments
Open

Q points when symmetries are deactivated #23

mesonepigreco opened this issue Jun 3, 2020 · 2 comments
Labels
cleaning cleaning of the code enhancement New feature or request
Milestone

Comments

@mesonepigreco
Copy link
Collaborator

This issue was raised by Francesco Belli

When the minimization is performed without symmetries, the dynamical matrix will break the symmetries present in the beginning.
Then the q star division and the number of irreducible q points is broken. However, now, the code ignores this issue and continues to treat and save the dynamical matrices with the wrong star.

Within the python code, it is trivial to reassemble the dynamical matrix into the correct q star, by just executing the command dyn.AdjustQStar(). However, when should this be called by the code? Before the final dynamical matrix is written? Or after each minimization step?

@ionerrea
@rafbianco

@mesonepigreco mesonepigreco added enhancement New feature or request cleaning cleaning of the code labels Jun 3, 2020
@mesonepigreco mesonepigreco added this to the Official Release milestone Jun 3, 2020
@adenchfi
Copy link

adenchfi commented Mar 22, 2021

Perhaps related: I tried loading an nqirr=8 set of dyn{1-8} files, but

image

yet I have

image

I suspect it is because I forced QE to not use symmetry for its 2x2x2 q-mesh PHonon calculation, because it was complaining otherwise due to supercell properties. Trying to use nqirr=8 didn't work, but using nqirr=2 (the "proper" amount that QE would've used had I let it use symmetry) successfully didn't crash at least, and it's running. This I presume only reads dyn_1 and dyn_2, not dyn_{1-8}. It may work for my current case (as dyn_1 and dyn_2 should be fine; we'll see), but maybe not desired behavior for more general cases.

@mesonepigreco
Copy link
Collaborator Author

Hi,
You can try a minimal script that just load the dynamical matrices and tries to enforces the symmetries:

import cellconstructor as CC
dyn = CC.Phonons.Phonons("dyn", nqirr = 8)
dyn.Symmetrize()

This should reproduce the same error as before.

If you modify the code in this way:

import cellconstructor as CC
dyn = CC.Phonons.Phonons("dyn", nqirr = 8)
dyn.AdjustQStar()
dyn.Symmetrize()
dyn.save_qe("new_dyn")

Does the code work?

If yes, after loading the dynamical matrix, use dyn.AdjustQStar() to fix the problem (this should reduce the number of irreducible points of the output new_dyn).

Alternatively, you can ask the code to symmetrize everything in real space setting use_spglib = True of the SSCHA_Minimizer object.

@mesonepigreco mesonepigreco modified the milestones: Official Release, 1.2 Mar 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleaning cleaning of the code enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants