I'm running some code that calculates a function for a wide range of temperatures. When running the programme my output file gives 1.#INF as qVproduct for each T. qVproduct is calculated the number of times equal to num_modes which is calculated earlier in the code. I looked this up and apparently it could be down to an overflow or dividing by 0. However, I can't seem to work out where in my code the issue is coming from. If anybody could have a look and point me in the right direction I would be extremely grateful :)