?? root_raised_cosine.m
字號:
function h = root_raised_cosine(Q, b, trunc)
% h = root_raised_cosine(Q, b, trunc)
%
% Computes a truncated root raised cosine FIR filter.
%
% Input:
% Q = number of samples per symbol
% b = roll-off factor (optional, default 0.22)
% trunc = truncation, computes impulse response in the interval
% [-trunc*Tsymb , trunc*Tsymb ] (optional, default trunc=5)
%
% Output:
% h = inpulse respone
% 2000-09-03 written /Stefan
if nargin < 3
trunc = 5;
end
if nargin < 2
b = 0.22;
end
% The symbol time T is assumed to be unity.
T = 1*Q;
t = -trunc*Q:1:trunc*Q;
h = 4 * b * ...
( cos((1+b)*pi*t/T) + (1-b)*pi/(4*b) * sinc((1-b)*t/T) ) ./ ...
(pi*sqrt(T)*(1-16*b^2*t.^2/T^2));
% Normalize
h = h / sqrt(h*h');
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -