fixed small bug with time step