UC San Diego Jacobs School of Engineering
A picture, produced through computer simulation, showing a twinned rainbow. The rainbow is split because of the interaction of light with two types of water drops.
updated 12/9/2011 4:12:44 PM ET 2011-12-09T21:12:44

Researchers in San Diego say they've discovered how a rare "twinned rainbow" works and can now simulate one on a computer.

By studying virtual rainbows, they figured out that the twinned rainbow needs sunlight to reflect off both small and large size water droplets at just the right angle.

"A double rainbow everyone has seen," said Iman Sadeghi, a Google software engineer and former doctoral student at the University of California San Diego's Jacobs School of Engineering.

"A twinned rainbow is very rare, and it's one thing that hasn't been explained before."

BIG PIC: Catching Legendary Rainbows

Sadeghi's paper appeared in this month's edition of ACM Transactions on Graphics.

Sadeghi says the image of any rainbow is dependent on the shape of the water droplets in the air, as well as the angle between the observer, the water droplets and the sun behind the observer.

If you draw an imaginary line from your eye to the water droplet in the sky, and then another line back toward the sun's position in the sky, the angle between those two lines must equal 42 degrees for a rainbow to appear.

A double rainbow — one on top of another — occurs when sunlight bounces back and forth twice inside the same rain drop before being reflected back to the observer.

A twinned rainbow appears to be two rainbows splitting from the base of a single one. That's the subject of the paper by Sadeghi and others at UCSD.

Henrik Jensen, professor of computer science and engineering at UCSD and a co-author, said he's been looking at simulating rainbows on a computer for the past few years. Although the origin of rainbows has been understood since French philosopher and mathematician Rene Descartes wrote about them in 1637, the ability to model them on a computer has come about just recently.

"We started out looking at what would cause rainbows," Jensen said, "and how could we capture rainbows in nature using computer graphics."

1. Science news from NBCNews.com
1. Cosmic rays may spark Earth's lightning

All lightning on Earth may have its roots in space, new research suggests.

2. How our brains can track a 100 mph pitch
3. Moth found to have ultrasonic hearing
4. Quantum network could secure Internet

NEWS: Airplanes Punch Holes in Clouds, Make it Rain

Jensen said that as raindrops fall through the air, they begin to flatten at their bottom. That hamburger-like shape — known as a "burgeroid" — affects how sunlight reflects back out and toward the viewer. Earlier simulated rainbows had only used spherical-shaped droplets, said Jensen.

As they started running various simulations, the scientists realized that the interaction of light with spherical drops could not explain some kinds of rainbows, such as twinned rainbows.

The UCSD team made all kinds of different virtual rainbows using computer simulations, (some took six to eight hours to create) which are available on their Flickr website.

"From a graphics point of view this looks very interesting," said Jerry Tessendorf, a computer graphics expert who teachers digital production at Clemson University.

UCSD's Jensen said the film and television industry is always interested in simulating reality (he worked on James Cameron's "Avatar" while Sadeghi worked on Disney's "Tangled"), and that rainbows have been difficult to get just right. The team's new finding should make that easier — although its still not going to enough to build a rainbow machine.

"That would be difficult," Sadeghi said. "You would have to control the shape of the water drops that are falling in the air."

1. UC San Diego Jacobs School of Engineering

Researchers in San Diego say they've discovered ...