Variational calculations of scattering