Skip to content

lineshape: store the HDF5 q-point and lattice vectors in the labelled units - #191

Open
ramic-k wants to merge 1 commit into
tdep-developers:mainfrom
ramic-k:lineshape-hdf5-units
Open

ramic-k wants to merge 1 commit into
tdep-developers:mainfrom
ramic-k:lineshape-hdf5-units

Conversation

@ramic-k

@ramic-k ramic-k commented Oct 12, 2026 •

Copy link
Copy Markdown

Fixes #188.

  • src/lineshape/io.f90: the q-point dataset stored qpt%r, which is in 1/bohr, under the label 1/A. It is now converted with /lo_bohr_to_A, as the band-structure writer does.
  • src/libolle/type_crystalstructure_io.f90, write_structure_to_hdf5: the lattice vectors, held in bohr, were divided by lo_Bohr_to_A and labelled 1/A. They are now multiplied by lo_Bohr_to_A and labelled A. This also corrects the structure group of the thermal-conductivity output.

Checked on the MgO case in #188: the stored q-point equals (−0.25, −0.5, 0.25) times the stored reciprocal lattice vectors, and the stored lattice vectors times the transposed reciprocal vectors give the identity. The self-energies are unchanged.

Built with Meson and gfortran 16.2.0.

… units

The q-point dataset stored qpt%r, which is held in 1/bohr, under the label
1/A. Convert it with /lo_bohr_to_A, as the band-structure writer does.

write_structure_to_hdf5 stored the lattice vectors, held in bohr, divided by
lo_Bohr_to_A and labelled 1/A. Multiply by lo_Bohr_to_A and label them A.
This also corrects the structure group of the thermal-conductivity output.

Fixes tdep-developers#188.
@ramic-k
ramic-k force-pushed the lineshape-hdf5-units branch from 23c83fe to 31532bf Compare October 12, 2026 13:55
@mjv500 mjv500 assigned johkl and jpabatista and unassigned johkl and jpabatista Oct 13, 2026
@mjv500
mjv500 requested review from johkl and jpabatista October 13, 2026 07:29

This branch has not been deployed

No deployments
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

Successfully merging this pull request may close these issues.

lineshape: HDF5 output stores the q-point in 1/bohr and the lattice vectors in wrong units

3 participants