Reverted the changes introduced by the commit that changed division by qmax to multiplication byt its reciprocal. It caused NaNs.
Minor fix.