(CNN) -- It's the kind of macho undertaking that might arise from an argument in a bar: Scan history for the toughest warriors of all time and then speculate on which would have bashed the others' brains in most effectively.
"Deadliest Warrior," Spike TV's most popular show, tackles this challenge every week, thanks to high-tech gadgets that decide whether a ninja could kill a Spartan or whether Genghis Khan might have conquered the Comanche.
The show's experts use a computer program adapted from a video game, along with speedometers, accelerometers, heat sensors and other measuring tools, to render a scientific judgment on who'd win each hypothetical duel.
"For years, people have always debated: Would a pirate beat a ninja? There are many websites devoted to just that," said Gary Tarpinian, executive producer of the show, which airs Tuesdays and began its second season last week.
"These are the types of things you can debate over the water cooler, or over a cold one, endlessly ... [but] we can't think of anyone else who's ever done a real scientific test using the kind of gear we use."
Each episode features rival teams who extol, and demonstrate, the prowess of their favorite warriors and an in-house team of medical, technical and military experts who evaluate both sides.
But the star of the show may be the computer program that renders the final verdict.
Tarpinian and company are tight-lipped on details about the program's algorithm. "It is a proprietary program," he said.
He said it's adapted from a combat engine originally developed by a British video game company.
"It's almost like artificial intelligence," Tarpinian said. "It wasn't exactly right for what we needed, but it gave us a jumping-off point. We took their technology and adapted it."
At the end of every episode, after experts enter data collected from multiple tests, the computer program engages with a flourish.
The computer simulates 1,000 fights and then spits out which side won the most of them, complete with information about which weapon delivered the killing blow.
"We felt the key to this game was not only evaluating the destructive power of these weapons and the protective power of the armor and shields but to get that information into a very accurate computer program," Tarpinian said.
The program sometimes surprises the very experts who fill it with data.
For example, in a virtual battle between Shaolin monks and Maori warriors, the Maori weapons won three out of four comparisons with similar Shaolin weapons.
But the single Shaolin victory -- with a pair of hooked swords that can be used to slice an opponent up to six feet away -- was so overwhelming that it trumped everything else and gave the monks the overall win.
Other results -- such as this season's upcoming showdown between Al Capone's Mafia family and the posse of Western outlaw Jesse James -- were surprisingly close, according to the computer. Despite Capone's more modern arsenal, Tarpinian said, that battle is one of the show's closest ever.
The tests that gather information for the computer are high-tech experiments as well.
Geoff Desmoulin, a biomedical engineer and former Olympian and karate black belt, devises most of those tests.
For example, he'll use an accelerometer in the head of a crash-test dummy to get a reading on the impact a weapon has and then compare that impact with, say, a head-on car collision.
An orientation sensor, mounted on a weapon, can get an inch-by-inch measure of that weapon's accuracy, efficiency and speed. So a weapon that hits equally hard as another but moves faster would get an edge, for example.
"All of those are hard numbers we can use in the simulation," Desmoulin said.
Multiple instruments measure air speed for projectiles, including a chronometer: an electronic speed trap with two sensors that report how quickly an arrow, spear, stone or other object flies from Point A to Point B.
Using that method, the "Deadliest Warrior" crew found that an arrow shot from an Apache bow takes only one second to travel 75 feet. At that speed, based on a person's average reaction time, it would be virtually impossible to escape an accurate shot from closer than 38 feet.
Then there are the dummies filled with ballistic gel that mimics the density and viscosity of human tissue. Again, Desmoulin said, results can be surprising.
"The one big surprise for me was William Wallace's ball and chain. Everyone had seen 'Braveheart,' " in which Mel Gibson, as the Scottish warrior, uses the weapon to deadly effect, he said.
"In fact, those weapons, when we tested them out, actually took a lot of time to get up to speed, and when you do release it, it's horribly inaccurate. It's very difficult to hit your target, it was used with two hands, not one, and when it hit, it was only about as hard as a heavyweight boxer would hit you."
"Deadliest Warrior" has a strong online community. Producers film short, web-only "postmortem" shows to answer viewer questions and let advocates for the show's warriors (particularly the losing side) pontificate about what they think the computer program missed.
It's all of that combined, Desmoulin said, that keeps a surprisingly broad-based crowd coming back for more.
"It maintains the core Spike audience with all the carnage, but then you've got the doctors, me, you get a lot of geek following with Max [Geiger, the show's simulations programmer] and his computer stuff," he said. "It's really guilt-free viewing for everyone."