The aerial ballet the birds perform while flocking is mesmerizing to watch. But even more fascinating is the science behind how they are capable of such coordinated movement.

"It's an awe-inspiring yet humbling first hand experience of nature. The way they move — it's like being able to watch the invisible flows of life energy.﻿"

These are just a few of the comments left on a video of a starling murmuration that went viral last year. And it's no surprise. If you've ever had the pleasure of seeing a flock of starlings fly together, then you know that it is like watching a shape-shifting cloud, a single being moving and twisting in unpredictable formations in the sky. But that single being is thousands, sometimes millions of individual birds. (And if you seen it, there's a great video at the bottom of this post.)

"It is so awesome that birds can make such coordinated changes en masse... The communication must be instantaneous," writes one commenter.

Well, not instantaneous but extraordinarily rapid. So fast that it leaves us staring in wonder. And that wonder is something that has captured the interest of scientists for a long time. Now that we have technology that can keep up with, and then slow down, the birds' activity, scientists are figuring out how they are capable of such coordinated movement. Here's what they've discovered.

As starlings gather in the evenings to roost, often they will participate in what is called a murmuration — a huge flock that shape-shifts in the sky as if it were one swirling liquid mass. Often the behavior is sparked by the presence of a predator like a hawk or peregrine falcon, and the flock's movement is based on evasive maneuvers. There is safety in numbers, so the individual starlings do not scatter, but rather are able to move as an intelligent cloud, feinting away from a diving raptor, thousands of birds changing direction almost simultaneously. The question that has had scientists stumped is how a bird, tens or hundreds of birds away from those nearest danger, sense the shift and move in unison?

The secret lies in the same systems that apply to anything on the cusp of a shift, like snow before an avalanche, where the velocity of one bird affects the velocity of the rest. It is called "scale-free correlation" and every shift of the murmuration is called a critical transition. Giorgio Parisi, a theoretical physicist with the University of Rome, lead a research team looking into the amazing movement of starlings and published a paper in the Proceedings of the National Academy of Sciences in 2010.

"The change in the behavioral state of one animal affects and is affected by that of all other animals in the group, no matter how large the group is. Scale-free correlations provide each animal with an effective perception range much larger than the direct interindividual interaction range, thus enhancing global response to perturbations."

Because the size of the flock doesn't matter, a huge flock is able to respond to a predator attack as effectively and fluidly as a small flock. No matter the size, the system works. If one bird changes speed or direction, so do others. The question remains, however, how does an individual bird spark a change if all are busy responding to the movement of everyone else? And more importantly, how do they do it so incredibly quickly?

"In particle physics, synchronized orientation is found in systems with 'low noise,' in which signals are transmitted without degrading. But low noise isn’t enough to produce synchronized speeds, which are found in critical systems. The researchers give the example of ferromagnetism, where particles in a magnet exhibit perfect interconnection at a precise, 'critical' temperature," writes Wired. The team's research suggests that starling murmurations are just such a critical system.

In 2012, the team published further research showing that each bird is actually reacting to the birds nearest to it, that the movement is the result of a series of short-range reactions. With the 2010 study the team looked at velocity; this time they studied orientation. Measuring how a change in direction by one bird affects those around it, the team discovered that one bird's movement only affects its seven closest neighbors. So one bird affects its seven closest neighbors, and each of those neighbors' movements affect their closest seven neighbors and on through the flock. This is how a flock is able to look like a twisting, morphing cloud with some parts moving in one direction at one speed and other parts moving at another direction and at another speed.

"The closest statistical fit for this behavior comes from the physics of magnetism, and describes how the electron spins of particles align with their neighbors as metals become magnetized," reports Wired. "In future research, Giardina’s team plans to study flocking in other organisms, such as local species of midges, which demonstrate other patterns of collective flight."

Why seven? It's one of those numbers that just works in nature, and a systems-theoretic approach to studying starling flocks showed it. "Interacting with six or seven neighbors optimizes the balance between group cohesiveness and individual effort," write the researchers.

The exact workings of starling murmurations is something we have yet to fully understand, though Giardina's team has made significant headway. When we do, there are exciting possibilities in science for applying that knowledge. The research team states that their results as well as their approach to studying the behavior "implications for uncertainty management in social and technological networks."

But for now, we can stand at twilight and watch as a starling flock moves like a single entity, swirling and writhing as individuals move as a collective whole. Curious about how to see this with your own two eyes? Grainger Hunt writes on All About Birds:

"Look for starlings in the cooler months near dairies, feedlots, vineyards, or anywhere agricultural leftovers are present. When you find them in their multitudes — critical mass, so to speak — a Peregrine Falcon is probably close by, or perhaps a Merlin, Prairie Falcon, Cooper’s Hawk, or even a Red-tailed Hawk. All are capable of invoking the cloud response, though none so spectacularly as a peregrine. Get comfortable, lean back with your binoculars, and look for the predator near the darkest areas where individuals are packed the tightest. Look closely, just outside the margins of the cloud, and let nature reveal itself."

Here's the video I mentioned earlier. It went viral last year and it's easy to see why: murmurations are mesmerizing. Additional and equally jaw-dropping videos of murmurations can be viewed here.