First of all, I am very new to signal processing. I use FFT to get various characteristics (SNR, THD, etc.) of a sinusoidal wave, represented as a series of double numbers. However, this works only if the wave is "coherent", i.e. the last sample completes the wave. In other words, the number of periods is an integer number. If I just remove a few samples from the wave, I get a complete different FFT result, and the characteristics also look totally different. Is this a known issue in FFT? If yes, how should such waves be analysed? Thank you in advance.
Oh yes. This is a known issue. What you have just discovered is called "spectral leakage". Entire books could be written on this topic. What are you going to want to do is to use a "window" to reduce the effects of spectral leakage. I have some tutorial material on my website that may help you.