Sailors across cultures have told so many tales of maritime voyages to exotic locations that they have inspired a distinct genre.
Now, scientists show that male humpback whales also sing songs shaped by their travels, and even exchange new tunes with each other at select sites, according to a study published Wednesday in Open Science. As a result, the likely route of male humpbacks across the ocean can be reconstructed by listening to their vocalizations.
“The migration patterns of humpback whales are written into their songs,” according to the study’s authors, led by Clare Owen of the University of Saint Andrews.
Owen’s team recorded 52 male humpback singers across six wintering grounds in the South Pacific. The researchers then categorized the recordings into three main songs using the Levenshtein distance metric, a technique used to measure differences between sequences—in this case, musical compositions.
“Song type 1” was the most frequent vocalization heard in the central Pacific, around the Cook Islands and French Polynesia. “Song type 2” was a popular tune in the west Pacific, near New Caledonia, Tonga, and Niue. Australia was the only location where “Song type 3” was picked up in the recordings.
Owen and her colleagues compared these three songs to recordings of 39 humpbacks at the Kermadec Islands, a newly discovered outpost where scientists think multiple humpback migration routes might overlap. The team made predictions about where these Kermadec Island whales had traveled from based on the similarity of their songs to Song types 1, 2, and 3.
The results revealed that most of the Kermadec singers were vocalizing song types 1 and 2, suggesting the whales came from places such as New Caledonia, Tonga, and the Cook Islands. None of the Kermadec whales were vocalizing song type 3, so it’s unlikely any originated from the Australian wintering grounds.
Interestingly, one singer was jamming on a hybrid of songs 1 and 2, which may signal that he was in the process of switching between the tunes.
“Hybrid songs are rare and likely short lived, so this hybrid song, with which we have likely captured some part of the process by which singers change their song display from an older to a new song version, suggests that the Kermadecs are a location where song learning occurs,” the team said.
While scientists have already established that evolving renditions of humpback songs are transmitted across the South Pacific, the new research reveals that some sites, such as the Kermadecs, could be especially important for song exchange. It may be that whales, like humans, are compelled to meet up and trade tunes before setting out on the next voyage.
This article originally appeared on VICE US.