Relaxation mesh dynamics in the method of finite differences