如何在matlab中创建产生信号的公式?
我很难在MATLAB中创建公式。首先是因为我不太了解这个软件 所以我想问,比如这个问题:如何在matlab中创建产生信号的公式?,matlab,Matlab,我很难在MATLAB中创建公式。首先是因为我不太了解这个软件 所以我想问,比如这个问题: % b is the input binary bit stream % f is the frequency of the carrier n = length(b); % determine the length of bit stream t = 0:0.01:n-0.01; % time axis for i = 1:n bw( ((i-1)*100)+1 : i*100 ) = b(i);
% b is the input binary bit stream
% f is the frequency of the carrier
n = length(b); % determine the length of bit stream
t = 0:0.01:n-0.01; % time axis
for i = 1:n
bw( ((i-1)*100)+1 : i*100 ) = b(i); % loop
end
carrier = cos(2*pi*f*t); % carrier signal
modulated = bw.*carrier; % modulated signal
用载波信号s1(t)=cos(10*pi*t)
和单极不归零二进制比特流m1(t)
绘制ASK调制信号的时域
为什么我们必须使用循环?公式是如何产生信号的 您可能想从这里开始。通过使用循环,可以在时间(t)从0到无穷大变化时获得结果