I have a bunch of symbols in the time domain and I am trying to do the fft of them and then calculate their bandwith. I have been trying to use the obw function to do this but the values do not seem to be right. My code is below:
p(1,:) = (2/symbol_duration)*cos(2*pi*15*t) + (2/symbol_duration)*cos(2*pi*50*t);
xform=(1/Fs) .* fft( p(i,:) );
fshift = (-n/2:n/2-1)*(Fs/n);
yshift(i,:) = abs( fftshift(xform) );
bw(i)= obw( yshift(i,:) )
The plot of my fft appears to be correct, but bw always seems to be some very small number that seems incorrect. Any help would be appreciated!