Scattering theory in homogeneous Sobolev spaces for Schrödinger and wave equations with rough potentials