Velocity correlations and memory functions in surface diffusion