Aiming to develop on-the-fly procedures to solve the exact-factorization equations, the electronic wavefunction is expanded in the adiabatic basis, i.e., the basis formed by the eigenstates of ĤBO (r, R). Therefore, the expression Φ(r, t; R) = j C j (R, t)ϕ j (r; R) is inserted in Eq. ( ) to derive a set of evolution equations for the expansion coefficients C j (R, t). Following from the above observations, when the idea of trajectories is introduced, the electronic equation ( ) is affected as well, and the evolution of the coefficients is ultimately expressed as a total time-derivative Ċj (R α (t), t) = Ċα j (t). The key quantity arising in such a trajectory-based formulation of the electron-nuclear dynamics is the so-called quantum momentum. In Eq. ( ), the operator Ûen [Φ, χ] depends on the nuclear wavefunction, and, when it is expressed in polar form, i.e., χ(R, t) = e iS(R,t) |χ(R, t)| using its modulus |χ(R, t)| and phase S(R, t), one gets