fixes for the new calculations