The van der Waals corrected first-principles approach (DFT-D) is for the first time applied for investigation of interlayer interaction and relative motion of graphene layers. A methodological study of the influence of parameters of calculations with the dispersion corrected and original PBE functionals on characteristics of the potential relief of the interlayer interaction energy is performed. Based on the DFT-D calculations, a new classical potential for interaction between graphene layers is developed. Molecular dynamics simulations of relative translational vibrations of graphene layers demonstrate that the choice of the classical potential considerably affects dynamic characteristics of graphene-based systems. The calculated low values of the Q-factor for these vibrations Q≈ 10-100 show that graphene should be perfect for the use in fast-responding nanorelays and nanoelectromechanical memory cells.