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

Expose ibrav and A, B, C, cosAB, cosAC, cosBC in PW schema #6

Open
afonari opened this issue Apr 8, 2021 · 2 comments
Open

Expose ibrav and A, B, C, cosAB, cosAC, cosBC in PW schema #6

afonari opened this issue Apr 8, 2021 · 2 comments

Comments

@afonari
Copy link
Contributor

afonari commented Apr 8, 2021

Hi All,

Currently ibrav is hardcoded to 0 and cell CELL_PARAMETERS (vectors) are expected from the XML.
This case is to allow setting ibrav not to zero and setting corresponding parameters to the schema.

This is coming from: (1) some pieces of the code don't work to work with ibrav = 0 (for example Makov-Payne correction) and (2) also QE output saying that using ibrav=0 with symmetry is DISCOURAGED, use correct ibrav instead =)

@pietrodelugas
Copy link
Member

pietrodelugas commented Apr 9, 2021

Hi Sasha @afonari
We could do this first in the converter without modifying the schema. If bravais index is found it writes the namelist using ibrav=0 and computing A,B,C and the angles from the cell vectors provided in the xml format. If cell vectors and ibrav are incompatible it issues an error.
In the long run, in next releases of qe we can also add an alternative component format for the cell structure in the schema, and write ABC and the cosines directly in the input element of the xml file.

@afonari
Copy link
Contributor Author

afonari commented Apr 9, 2021

Hi Pietro,

We could do this first in the converter without modifying the schema.

Sounds good.

If cell vectors and ibrav are incompatible it issues an error.

Instead of error, please return triclinic (ibrav=14) it is always correct.

Code-wise, I think Modules :: latgen.f90 :: at2ibrav can be implemented: https://gitlab.com/QEF/q-e/-/blob/develop/Modules/latgen.f90#L490

If possible please ping me in the PR.

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

No branches or pull requests

2 participants