Charles Darwin shook the world with his theory of evolution, but he couldn't figure out what ailed him.

The British naturalist, who lived from 1809 to 1882, suffered severe abdominal pain for much of his life, vomiting after every meal when it was at its worst. Some of England's most prominent physicians diagnosed lactose intolerance, lead poisoning, hypochondria, gout—even schizophrenia and repressed anger toward his physician father. Nothing helped.

Now,...