Hamiltonians and Lagrangians of non-autonomous one-dimensional   mechanical systems
  It is shown that a given non-autonomous system of two first-order ordinary differential equations can be expressed in Hamiltonian form. The derivation presented here allow us to obtain previously known results such as the infinite number of Hamiltonians in the autonomous case and the Helmholtz condition for the existence of a Lagrangian. 
G.F. Torres del Castillo, I. Rubalcava Garcia