- added TX windowing - added RX git-svn-id: http://moon:8086/svn/matlab/trunk@3 801c6759-fa7c-4059-a304-17956f83a07c
11 lines
336 B
Matlab
11 lines
336 B
Matlab
function [p Nt] = txwin_eval(Nu, Ng, Alpha)
|
|
|
|
Nfft = Nu; % FFT size
|
|
CP = Ng; % Nb. samples in Cyclic Prefix
|
|
%Alpha = 1/32; % RX Alpha
|
|
Nt = 2*round(Nfft*Alpha/2); % Nb. samples in taper region
|
|
p = 1/2*(1+cos(pi*[-Nt+1/2:Nt-1/2]/Nt)); % Raised-Cosine in TD
|
|
p = [p(1:Nt), ones(1,Nfft+CP-Nt), p(Nt+1:2*Nt)]; % Add ones in middle
|
|
|
|
|