Daniel Lemire's blog

What comes first, theory or experiments?

In “my research process“, I explain how I proceed to produce research papers. As a comment to my most recent post, Peter Turney wrote:

I don’t usually start writing until all the research is done. It sounds like you write and research in parallel.

From what I understand, Peter proceeds like this:

His approach is efficient if you can implement and test algorithms very fast. (He is probably using high level languages.) However, he can waste time on implementation and testing. He wastes no time writing uninteresting papers.

My own process is slightly different:

Of course, my approach is almost totally inadequate for fields like Machine Learning where a priori work is often barren or irrelevant. Also, I end up writing uninteresting papers—and throw them away (hopefully). I also cannot tell, when I start writing it, what the paper will say and to whom exactly it might be interesting. Hence, I often change the abstract and the title several times. Many sections that I write are thrown away. I have entire, very long papers, that nobody will ever read.

Hopefully, my process produces papers with a sane balance between theory and practice. At least, that is what I tell myself.

Here are a few of my papers that are typical of my approach:

Hence, I only write down the code after I have some interesting theoretical results. But I do not require the theoretical results to be worth a paper. Hence, I always start experiments after I have started a paper. Then I iterate, working on the paper (the theory) and on the experiments. The idea is that one is supposed to help the other. Experiments are meant to suggest new theory, and theory is supposed to suggest new experiments.

How do you work?