Transport of ions in ion guides under flow and diffusion