I am new to CUDA programming, and I am working on a problem that requires multiple GPUs in one machine. I understand that for better graphics programming multiple GPUs need to be combined via SLI. However, for CUDA programming do I need to combine GPUs via SLI as well?
No, in general you don't want to use SLI if you plan on using the GPUs for compute instead of pure graphics applications. You will be able to access both GPUs as discrete devices from within your CUDA program. Note that you will need to explicitly divide work between the GPUs.
I don't have an explanation for why SLI isn't desirable for compute applications, but it's what I've read on the Nvidia forums and heard from others in IRC channels.