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

Reduce state mutation related to ph-iso #130

Open
nakib opened this issue Feb 27, 2024 · 0 comments
Open

Reduce state mutation related to ph-iso #130

nakib opened this issue Feb 27, 2024 · 0 comments
Assignees
Labels
invalid This doesn't seem right

Comments

@nakib
Copy link
Owner

nakib commented Feb 27, 2024

The phonon object should not be mutated outside the initialization step. Somehow the following:

!!Initialize the matrix elements storage
    if (phiso .and. .not. phiso_Tmat) then 
      call ph%xiso%allocate_xmassvar(ph, usetetra, phiso_Tmat)
    end if 
    if (phsubs) then
      call ph%xsubs%allocate_xmassvar(ph, usetetra, phiso_Tmat)
    end if

has crept into the module bz_sums. This will have to be removed from here since bz_sums should ideally not mutate random particle states.

Related issue: I am not a fan of data types containing data types. So this will have to be reworked.

@nakib nakib self-assigned this Feb 27, 2024
@nakib nakib added the invalid This doesn't seem right label Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
Status: In progress
Development

No branches or pull requests

1 participant