Changed final iteration point over interval from n+1 to n