Stars and comets make unlikely dance partners. Their gravitational partnership is one that astronomers have long suspected but have never seen — until now. For the first time, a Polish group has identified two nearby stars that seem to have plucked up their icy partners, swinging them into orbits around our sun.

The astronomers found the stellar duo after studying the movements of over 600 stars that came within 13 light-years of the sun. The new findings validate a theory born more than a half-century ago, and in doing so have also shown just how rare these stellar dances can be.

Out on the far edge of the solar system, hanging like wallflowers around the planetary dance floor, is the Oort Cloud. This icy group of objects were left over after the formation of the solar system, creating a giant shell enveloping our home system that extends from 66 times the distance to Neptune to 9.23 trillion miles (14.9 trillion kilometers) away from the sun. Astronomers think the Oort Cloud is a reservoir for long-period comets — those that take more than 200 years to orbit the sun. Comet Hale-Bopp, which has a 2,500-year orbit, is one of the most famous of these long-period comets.

Related: The 12 Strangest Objects in the Universe

Since the cloud's existence was first proposed by Jan Oort in the 1950s, astronomers have suspected that every so often, a passing star might be able to pick up an object and send it swinging on a wild ride through our solar system; that ride would bring some of those comets streaming through the night sky for us to marvel at. Astronomers have spent years trying to find proof of these stellar dances, but none had been conclusively shown until now.

A new paper, accepted for publication in the journal Monthly Notices of the Royal Astronomical Society and published on the preprint database arXiv, describes how astronomers calculated the paths of nearly 650 stars, which they compared with the orbits of over 270 long-period comets. The study used a catalogue from the Gaia spacecraft, which has measurements for some 1.7 billion astronomical objects, along with surveys like Pan-STARRS, which looks for asteroids, comets and other small bodies in our solar system.

They created models for the star-comet pairs to rewind and replay their history. The astronomers then would "remove" a star from their model to see if that significantly changed the partner comet's orbit. If it did, the astronomers would know that the stars had tangoed with the comets.

"In our study, we discovered only two cases in which this actually happened, and yet, we observe dozens of comets every year," lead study author Rita Wysoczańska, an astronomer at the Institute Astronomical Observatory at Adam Mickiewicz University in Poland, told Live Science. "At this moment, we can say that the mechanism proposed by Oort is not sufficient enough to generate all comets we observe."

It's likely that the collective gravitational force of more distant stars can boost comets into long-period orbits. And once a comet enters the solar system, it can be further perturbed by the planets therein.

Related: 15 Amazing Images of Stars

"I think, in general, it is hard to associate a particular comet with a particular star," said Coryn Bailer-Jones, an astronomer at the Max Planck Institute for Astronomy in Germany, who was not involved with the new study. "We must also consider the contribution of the galactic background potential, which is essentially the influence of all the other much more distant, but also much more numerous, stars in the galaxy."

Creating computer models to look at all of those influences, something called a multibody model, is a much more complex and computationally intensive task.

Additionally, information doesn't yet exist for every star. With current data, the astronomers had to rely on estimates for some of the stellar masses and movements. The astronomers hope that a future data release of the stellar survey they used can help shed more light on comet-star interactions.

Editor's note: This article was updated to indicate the astronomers looked at stars that came within 13 light-years of the sun, not 1.3 light-years as had been written.

Originally published on Live Science.