Lying on my bed, doing nothing I recently noticed flies usually fly in small circles, right under my ceiling lamp. Worth noting - the lamp was off as it was middle of a day. And those flies kept flying like this for hours, not moving anywhere else! Later I noticed it repeated every day, pretty much the same pattern. Why is that?
Flies use any object they can find as a landmark.
The flies patrol well-defined airspaces underneath landmarks like lampshades. ... Male flies approach a landmark from below and, in the absence of other flies, settle to patrol an airspace close to the landmark. A second male approaching the same landmark chases, or is chased away by, the patrolling fly when it comes too close and may eventually settle to patrol 10–30 cm below the airspace occupied by the first fly. ... The position of male patrolling stations relative to the landmark suggests that females might arrive at landmarks from the side (and not from below, as males do), thus crossing the dorsal visual field of patrolling males.
Source: Jochen Zeil. The territorial flight of male houseflies (Fannia canicularis L.) Behavioral Ecology and Sociobiology. August 1986, Volume 19, Issue 3, pp 213-219