Fix PSD prior error
This hopefully fixes the How did PSD come outside the prior
error. It was caused by incorrect calculation of the PSD prior at the beginning of the run. This has been fixed now. Will look into whether this change makes the error go away too.