A class of stars that jangled out discordant frequencies across the galaxy have just been untangled. Using data collected by NASA's TESS space telescope, astronomers have finally found a rhythm in the pulsations of strange, young stars.

They're called delta Scuti variable stars, and they rotate so rapidly that the stars flatten slightly, scrambling their pulsation patterns and producing what seems to be chaos.

From that chaos, we now have order: regular, high-frequency pulsation modes identified in 60 delta Scuti stars of intermediate mass, ranging between 1.5 and 2.5 times the mass of the Sun.

"Delta Scuti stars clearly pulsate in interesting ways, but the patterns of those pulsations have so far defied understanding," said astronomer Tim Bedding of the University of Sydney in Australia.

"To use a musical analogy, many stars pulsate along simple chords, but delta Scuti stars are complex, with notes that seem to be jumbled. TESS has shown us that's not true for all of them."

Stellar pulsations aren't an unusual phenomenon. Many stars - maybe even all of them - oscillate in rhythmic patterns, caused by acoustic waves bouncing around inside the star. These waves are thought to be created by convection and the star's magnetic field, and they cause the star to expand and contract slightly, like a heartbeat. This is detectable as faint variations in the amount of light the star gives off.

Just as earthquakes can be used to probe Earth's guts, the oscillations of stars can reveal what's going on inside them, which can be used to learn more about properties such as their age, composition and temperature - a field known as asteroseismology.

To collect asteroseismological data, you need to stare at stars for quite a while to collect comprehensive information on their light variations. And as TESS was built exactly for staring at a whole lot of stars at once to detect light variations - albeit from exoplanetary transits, rather than stellar oscillations - it's turning out to be something of an asteroseismology champion.

In addition to its large-scale observations in search of exoplanets, TESS has been closely monitoring thousands of delta Scuti stars. It was in these latter observations that the researchers spotted something amazing: a subset of delta Scuti stars that seemed to have regular pulsation patterns.

Kepler, too, took observations of around 300 delta Scuti stars over a four-year period, so the team added those data to their search. Using specially designed software, they analysed 92,000 light curves, which led to the identification of 60 stars with regular pulsations in high frequencies.

"NASA's TESS data has delivered precise detections in a much larger number of these stars than we had before," said astronomer Daniel Huber of the University of Hawai'i. "This has now finally cleared up the picture, and we were able to identify regular structures. It's like notes of a song finally falling into place to play a beautiful melody."

A more comprehensive analysis of the properties of the regularly pulsating subset of delta Scuti stars is proving revealing: They are all younger than the delta Scuti stars that continue to defy order.

This is consistent with our understanding of stellar evolution - that pulsation spectra become more complex as stars age. But it can also be used as a powerful tool.

"We can use the information about regular spacings in other delta Scuti stars as an age diagnostic," explained astronomer Daniel Holdsworth of the University of Central Lancashire in the UK.

"The age of a star, or groups of stars, can be hard to determine with results differing by a factor of two. However, asteroseismology has the power to provide very precise ages thus providing the opportunity to expand our understanding of the Galaxy around us."

Already the data have helped to settle a debate over the age of a delta Scuti star called HD 31901, which belongs to the Pisces-Eridanus stream of stars near the solar neighbourhood. Two previous calculations had come up with wildly different ages - around 1 billion years, based on a red giant thought to be part of the stream; and 130 million years, based on the rotation of other stars within the stream.

The asteroseismological data on HD 31901 suggests it's around 150 million years old - supporting the younger age of the stream.

"This really is a breakthrough. Now we have a regular series of pulsations for these stars that we can understand and compare with models," said astronomer Simon Murphy of the University of Sydney.

"It's going to allow us to measure these stars using asteroseismology in a way that we've never been able to do. But it's also shown us that this is just a stepping-stone in our understanding of delta Scuti stars."

The research has been published in Nature.