Fixed add, grow, and calcIndex based on feedback