fix the sum calculations (whoops).