Minor fixes
Minor fix to calculations