When researchers found a group of brain cells in the fruit fly that function like a compass, they were very satisfied. They had found what they were looking for.

But, said Vivek Jayaraman, when he and Johannes D. Seelig realized that the cells were actually arranged in a physical circle in the brain, so they looked just like a compass, they were taken aback.

“It’s kind of like a cosmic joke that they are arranged like that,” he said.

Dr. Jayaraman was investigating key components of navigation – how a moving creature knows the direction it is headed both in the presence of visual landmarks and in their absence.

When navigating, animals rely on visual cues, like landmarks, and also a sense of where their bodies are pointed, a process called angular path integration. It is different from other ways animals navigate, such as the use of polarized light from the sun or sensitivity to Earth’s magnetic field.