smooth shifts in z-direction