Gyrating and intermediate ion distributions upstream from the Earth's bow shock