Equation of state and elastic properties of beryllium from first principles calculations