  The classical and quantum dynamics in a high frequency field are found to be
described by an effective time independent Hamiltonian. It is calculated in a
systematic expansion in the inverse of the frequency ($\omega$) to order
$\omega^{-4}$. The work is an extension of the classical result for the Kapitza
pendulum, which was calculated in the past to order $\omega^{-2}$. The analysis
makes use of an implementation of the method of separation of time scales and
of a quantum gauge transformation in the framework of Floquet theory. The
effective time independent Hamiltonian enables one to explore the dynamics in
presence of rapidly oscillating fields, in the framework of theories that were
developed for systems with time independent Hamiltonians. The results are
relevant, in particular, for exploration of the dynamics of cold atoms.
