Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- %% Task 4
- %
- FFTSIZE = 512;
- Fs = 7.68e6 ; % Hz
- Fc = 859.6e6; % Carrier Frequency
- pdp = mean(abs(ifft(H2,50)).^2,2);
- figure;
- plot(linspace(0,222e-9 * 50,50), 10*log10(pdp))
- title 'Power delay profile'
- Pm = sum(pdp); % total power
- tau = linspace(0,222e-9 * 50,50);
- tmp = 0;
- Tm2= sum(tau*pdp)/Pm;
- for i =1:length(pdp)
- tmp = tmp + pdp(i) *tau(i);
- end
- Tm = tmp/Pm; % Average mean delay
- tmp2 = 0;
- for i =1:length(pdp)
- tmp2 = tmp2 + pdp(i)*power(tau(i),2);
- end
- S = sqrt( tmp2/Pm - power(Tm,2)); % Average delay spread
- fprintf('Average delay spread %e ns\n', S);
- fprintf('Average mean delay %e ns\n', Tm);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement