am_mod.m

来自「am and dsb modu and demodu」· M 代码 · 共 12 行

M
12
字号
function u=am_mod(a,m,ts,fc)
%       u=am_mod(a,m,ts,fc)
%AM_MOD     takes signal m sampled at ts and carrier
%       freq. fc as input and returns the AM modulated
%       signal. "a" is the modulation index
%       and ts << 1/2fc. 

t=[0:length(m)-1]*ts;
c=cos(2*pi*fc.*t);                 
m_n=m/max(abs(m)); 
u=(1+a*m_n).*c;          

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?