irreducible-representations / irrep

GNU General Public License v3.0
59 stars 30 forks source link

Check transformation of unit cell #44

Closed MIraola closed 2 years ago

MIraola commented 2 years ago

This PR corrects the automatic calculation of the transformation to the convenctional unit cell.

  1. Internally, the tranformation follows now the notation of spglib. Accordingly, the matrix refUC describes how the row of basis vectors of the convenctional cell (c1, c2, c3) is obtained from the row of vectors of the DFT cell (a1, a2, a3):

    (**c1**, **c2**, **c3**) = (**a1**, **a2**, **a3**) . `refUC`

    Externally, the user still sets refUC as in Eq. (6) of the paper. This way we keep the code consistent with the paper.

  2. The formatting of some messages has been improved.

  3. Some error messages contain now more info, which makes them easier to understand.

Tests

To test the code, I have run all the tests implemented in Github without setting refUCand shiftUC (i.e. automatic calculation of the transformation) and checked that they yield the same irreps as in the way they are actually implemented.

I have also tried the code with 30 DFT calculations and it has found correctly the transformation to the convenctional cell.