In research that would cause nightmares for any libertarian, Japanese scientists say they're encroaching further into the privacy of the human brain to do no less than decode the mystery of dreams.

Those mishmashes of logic and imagery, time and perception, those alternate realities in which we spend so much of our existence, researchers say they can decipher at least partially.

With complex algorithms useful in detecting fraudulent credit card purchases among millions, investigators are employing functional magnetic resonance imagery and electroencephalograph technology to make sense of blood flow and electrical activity in the brain. Peering at visual cortices, the researchers say they can decode dream imagery with an accuracy of about 60 percent, sometimes higher.

"For some categories - like male, female and other characters - you can predict if this character was in the dream or not with an accuracy of 70 percent to75 percent," said study leader Yukiyasu Kamitani, a neuroscientist at ATR Computational Neuroscience Laboratories in Kyoto.

They published the research Thursday in the journal Science.

Jack Gallant, a researcher who studies the brain's visual system at the University of California at Berkeley, expressed enthusiasm about the Japanese project. "We're all intrinsically interested in dreaming but neuroscientists to this day aren't certain what it does for us," he said. "It would be great to have a method of decoding to allow us to know what is going on when we dream."

But aside from mere curiosity, researchers would like to gain useful insights into such core brain functions as learning and memory consolidation, in addition to greater knowledge of perceptions within the subconscious mind. To do so, researchers scanned the brains of three volunteers as they fell asleep without anesthesia, entering an early dream stage called hypnagogic hallucination. Every six minutes, about 200 times during the testing, the researchers woke the study subjects to receive verbal reportage.

"I saw a person was something like a scene that I hid a key in a lace between a chair and a bed and someone took it," was one such response. The researchers took the nouns from verbal responses and combined them into generic categories, which were represented by images - such as a face, a key, a chair - which they then presented to the subjects when awake.

The researchers then looked to the computer to find links between those images and brain activity.

"If you have a theory of the brain, you should be able to decode the brain," Gallant said. The only limiting factors, he said, are "how well you can measure brain activity, how good your models are and how fast your computers are.

"There's something in common between what goes on in dreaming and what goes on in perception," he said.

In Gallant's work, computers managed to identify 92 percent of dream images presented to subjects upon waking, with other studies finding links between dreams and the brain's attempt at motor control of the body.

Scientists say such work has profound implications for not only neuroscience and psychology but practical fields such as law enforcement, recalling to some perhaps the dream that was "Minority Report" (2002).