How do I ask for a reference letter from a professor I do not want to work with? I'm a fourth year undergraduate student planning on applying to grad programs this fall. I will mainly be applying to PhD and research thesis master programs in machine learning and computer architecture. They would fall under the computer science or electrical/computer engineering departments.

I did part time research under a professor this school year. It was something I initiated/approached him about, asking for something interesting I could work on. We eventually co-authored a paper together and successfully published it.

Because of this being a positive experience, I plan on asking this professor for a reference letter for grad school.

He was an incredible supervisor, and I really enjoyed the work, however I don't see myself spending my life working in his field, so I'm not particularly interested in going to grad school for it.

He's obviously not a kid and I highly doubt he'll take it personally, so I'm not worried about him being insulted. However, as I mentioned before, I approached him at the beginning of the year saying his work looked interesting. Additionally, he was happy with my work so he decided to pay me for it. My main concern is that he will be annoyed that I made him invest so much time and money in me only for me to then claim I'm not really interested in his work. I did find the work interesting, but not interesting enough to spend years working in it. His field is signal processing algorithms, so fairly different from the machine learning and computer architecture programs I'll be applying to.
How do I ask for a reference letter from a professor I do not want to
  work with?


You can write a short email along these lines:


  Hi Bob,
  
  As you know I am intending to apply for a PhD at X, Y and
  Z universities and was wondering if you would be willing to write me a
  reference letter for my applications?
  
  If so, are you free to meet at [time/date/location] to discuss my
  application plans in more detail?
  
  Thanks,
  
  Farhad


If he says yes (which I am sure he will), you can give him more details of the places you want to apply to, the topics you are interested in and the people you are interested in working with. He may even be able to give you advice on the best places to apply for such topics.

Don't worry about hurting his feelings-- as you say, he is an adult. Furthermore, professors are very used to having students in exactly this situation, and it's perfectly fine for your interests to change over time. It happens. In fact, it's actually better that you have the maturity to recognise this change rather than working on a topic that doesn't interest you because you feel some kind of obligation to stick with that professor.

As for the investment of time and money into you-- if he really cares about you and your career I'm sure he'd be just as happy to see that investment paid off when you get a great PhD under someone else's supervision instead of his. If he doesn't care about you and your career-- well, you're dodging a bullet by leaving his supervision.

An addendum to describe my personal experience in a similar situation: I had a great supervisor for my Master's degree and would have been really happy to continue for my PhD with him. However, he encouraged me to apply to other places anyway and I was accepted to a bigger department at another institution with much more work going on in my specific field of interest. 

He advised me to move rather than stay with him and he was right: working on a topic I'm really passionate about in a lively department is far better than sticking with the familiar in a small, inactive group, even though I got on with him really well.

Good luck with your applications.