Lagrangian Mechanics II: Degrees of freedom, generalized coordinates and a cylinder