fix a bug;the boundary value is not correct