update to total formula