In July and August of 2016, astronomers noticed something really strange in the data from the Gaia space observatory. A distant star oddly brightened, then dimmed. A few weeks later, it brightened again, and dimmed again.

This odd behaviour wasn't because of anything the star was doing; rather, the gravity of an invisible object between us and it was warping the fabric of space-time, magnifying the star's light as it passed through.

Now astronomers have figured out what that invisible object is: a binary star 2,544 light-years away that's so dim we can't see it at all. Yet, based on the way the star's gravity magnifies light, astronomers were able to calculate the mass, distance and orbit of the system.

These techniques, they say, could be a way to locate other hidden massive objects in the Milky Way galaxy - such as the estimated millions of lone stellar mass black holes out there.

The big clue as to the nature of the system, according to a team of astronomers, was the repeated brightening and dimming of the source object. The event has since been named Gaia16aye.

"If you have a single lens, caused by a single object, there would be just a small, steady rise in brightness and then there would be a smooth decline as the lens passes in front of the distant source and then moves away," said astronomer Łukasz Wyrzykowski from the University of Warsaw in Poland.

"In this case, not only did the star brightness drop sharply rather than smoothly, but after a couple of weeks it brightened up again, which is very unusual. Over the 500 days of observation, we have seen it brighten up and decline five times."

This suggested a binary object producing what is known as a gravitational microlens; an effect predicted by Einstein, which occurs when the gravity of a foreground object causes space-time to bend, magnifying something behind it.

On larger scales, this allows us to study distant objects, but the smaller lenses can be useful too.

In the case of Gaia16aye, the microlens was a complex network of high-magnification regions. Background sources passed over by these regions will brighten rapidly, then immediately dim again as the region moves on.

Careful study of these patterns in the Gaia16aye microlensing event revealed a binary star system called 2MASS19400112+3007533, two red dwarf stars clocking in at 57 percent and 36 percent of the mass of the Sun. They orbit a mutual centre of gravity every 2.88 Earth years.

"We don't see this binary system at all, but from only seeing the effects that it created by acting as a lens on a background star, we were able to tell everything about it," said astronomer Przemek Mróz, formerly of the University of Warsaw and now at the California Institute of Technology.

"We could determine the rotational period of the system, the masses of its components, their separation, the shape of their orbits - basically everything - without seeing the light of the binary components."

The team hopes that these techniques will help them to find lonely stellar mass black holes - one of the aims of the automated tool looking for brightening and dimming stars in Gaia data.

At the moment, we know of a few dozen of these black holes. We spot them when they interact with stuff in the space around them, such as when they're actively snacking on a star, or when they're in a binary pair with a regular star.

To date, however, lone-wolf dormant black holes have remained elusive. But if we can find invisible red dwarf stars that combined are less than the mass of the Sun, these techniques could reveal stellar mass black holes, which are generally accepted to have a lower limit of around five times the mass of the Sun.

"Our method allows us to see the invisible," Wyrzykowski told Science in Poland.

"I think that this year we will have the first black holes. I am an optimist."

The research has been published in Astronomy & Astrophysics.