added in some transitions when updating the data
cleaning up the math used to calculate gradient direction
added in user controllable update time