bug in claculate total reads function