Can computer software invent scientific theories and ideas as well as crunch numbers? That's the suggestion being put forward by Michael Levin and Daniel Lobo, two computer scientists at Tufts University, Massachusetts in the US, who have programmed a computer to come up with its own scientific hypothesis on one of biology's most well-known mysteries.

The mystery in question: how the genes of a sliced-up flatworm regenerate into new organisms. It's one that's baffled the brightest human minds over the last century or so, and the two researchers picked it because it was "incredibly interesting", as William Herkewitz reports for Popular Mechanics. "These worms are basically immortal, you can cut them up and they continuously form new organisms," Levin told Herkewitz. "And why that happens could be key to developing everything from regenerative medicines to designing self-repairing robots."

The computer program created by Levin and Lobo was designed to repeat real-life studies over and over again, making small tweaks each time. With a huge binary brain to draw on and no need for either food or sleep, the machine was able to chew through many different hypotheses much faster than mere mortals can.

Essentially, the computer was guessing how a worm's genes connect together, and simulating a new theory each time - if the end results were closer to data obtained in the real world, it took another step in that direction; if not, it changed course. After three days, the software came up with a core genetic network code that matched all of the hundreds of actual experiments in its database.

Three days is an impressively short span of time but the actual software took years to put together. A customised computer language was required before the software could handle the available data, and of course all that data had to be collected and collated from the various scientific research projects that have taken place down the years. Only with the right raw materials in place could the program draw its conclusions.

"The invention of models to explain what nature is doing is the most creative thing scientists do... this is the heart and soul of the scientific enterprise," says Levin. "None of us could have come up with this model; we as a field have failed to do so after over a century of effort. This problem, and our approach, is nearly universal. It can be used with anything, where functional data exist but the underlying mechanism is hard to guess."

Levin and Lobo's work has been published in the journal PLOS Computational Biology, and the pair believe the same kind of reverse-engineering approach can be used in many other areas of science, particular in situations where there's a lot of raw data that's difficult for the human mind to process. Next up, the computer scientists are tackling the question of metastasis: how cancer begins to spread through the body.