Fireflies are a diverse lot. Some flash their lights Morse-code style, some glow more languorously, some synchronize with others around them, and some fly in a distinctive pattern while flashing.
The diversity of signals allows species living in the same habitat to distinguish among themselves while looking for mates, according to firefly expert Marc Branham, an associate professor at the University of Florida.
"That is the same in (frogs), every (frog) species has its own song, and that is why in a swamp or in a wet place you can hear lots of different species based on their mating calls," Branham said.
A male firefly's flashes also encode some information about him, so when a female on the ground below sees what she likes, she signals back.
Fireflies, bioluminescent organisms that are able to produce their own light using a chemical reaction, are members of the Lampyridae beetle family. As larvae, all fireflies light up, warning predators of the toxins they contain. [ A Glow-in-the-Dark Gallery ]
"What is really cool is that [lighting up] has then been carried over to the adult stage and is used both as warning signal and also as mating signal," Branham said.
But not all fireflies light up as adults. The more primitive species lose their glow when they grow, and signal to potential mates using pheromones instead. Meanwhile, the more advanced firefly species have lost the elaborate, pheromone-sensing antennae of their ancestors and adopted specific bioluminescent signals and habits.
The big dipper firefly, Photinus pyralis, flies in a "J" pattern as it flashes. A species in south Florida, Photinus collustrans, flashes for only 28 or 29 minutes at dusk.Other fireflies stay out all night, lighting up the tree canopy. Fireflies in parts of southeastern Asia congregate en masse and synchronize their pulses of light.
Fireflies produce their own light by combining the energy storage molecule ATP, another molecule called luciferin and oxygen in the presence of an enzyme, luciferase. The insects turn their light off or on by controlling the flow of oxygen into their photic organ, where the reaction takes place. More advanced fireflies have a reflective layer in the back of their photic organ, somewhat akin to a piece of tinfoil, to help send the light out, Branham said.
Fireflies appear to be in decline over the past 15 years or so, Branham said. While no research exists documenting their decline, he said that each spring, he receives phone calls from people who say they don't see the same swarms of fireflies they did as children, even in the same places.
"The problem is there haven't been any counts of the population densities in the past, so we can't quantitatively tell if this is true or not, or how much populations are down," Branham said. "Pretty much everyone seems to agree their numbers are much fewer, and I think that is probably due to a couple of different things."
Light pollution, which interferes with fireflies' ability to find mates, herbicide and pesticide use, and drier conditions, could all be contributing factors to the population's decline, he said.
Fireflies and other glowing organisms strut their stuff in the exhibit "Creatures of Light: Nature's Bioluminescence," which opens at the American Museum of Natural History on Saturday (March 31) and is scheduled to run until Jan. 6, 2013.
Editor's Note: This story was updated on March 30 at 6:20 p.m. EDT to correct a reference to frogs' calls. Marc Branham was referring to the distinct calls of frogs in wet, swampy areas, not birds.
You can followsenior writer Wynne Parry on Twitter. Follow LiveScience for the latest in science news and discoveries on Twitter and on.