Name two examples in which the mechanical energy of a system remains constant.