correct way for Zero padding I am doing simulation of FMCW radar. I am applying signal processing chain on raw radar data. Here in the code below, I am taking fft of data and plotting it. Moreover, I am doing zero padding by multiplying the signal length by 1000. I should be getting beat frequency at 2.020 MHz instead I am getting at 2.019MHz. There is something little probelem but I do not know what. 

Is it the correct way for Zero padding? Moreover, am I defining frequency axes correctly? Thanks everyone in advance

% second-order butterworth
[b, a] = butter(2, [w1 w2], 'bandpass');


load('fb2030');                                   % loading the data
x = fb2030(30,:);
% filtering
y_filt = filter(b,a,x);                           % filtering the received signal
nfft = length(y_filt)*1000;                       %%%% Zero Padding
res = fft(y_filt,nfft)/ nfft;                     % normalizing the fft


f = fs/2*linspace(0,1,nfft/2+1);                  % choosing correct frequency axes
res = res(1:nfft/2+1);                            % amplitude of fft(taking the half length of nfft)
figure,plot(f,2*abs(res));
xlabel('Frequency in MHz');ylabel('amp')
This line seems suspicious to me:

f = fs/2*linspace(0,1,nfft/2+1);  


Your frequency bins should be:

$$f_k = \frac{f_s}{\tt nfft} k$$

so 

$$ \begin{array}{rcl}
f_{{\tt nfft}/2 + 1} &amp;=&amp; \frac{f_s}{\tt nfft} ({\tt nfft}/2 + 1)\\
&amp;=&amp; \frac{f_s}{2} + \frac{f_s}{\tt nfft} 
\end{array}$$

whereas your linspace setting has it mapping to just $\frac{f_s}{2}$.