Invia SMS: Hamilton's principle and physical systems