https://123dok.net/document/qo519325-homoclinic-and-periodic-orbits-for-hamiltonian-systems.html