Not enough input arguments
2 ビュー (過去 30 日間)
古いコメントを表示
Hi, I've been trying to do a coding for FM Modulating Signal but when using the code below, I got a "not enough input arguments" error. Would really appreciate it if anybody could help. Thank you!
fs=100;
ts=1/fs;
fd=25;
t=(0:ts:0.5-ts)';
x=sin(2*pi*4*t);
MOD=comm.FMModulator('SampleRate',fs,'FrequencyDeviation',fd);
ym=step(MOD,x);
subplot(2,1,1);
plot(t,[x real (ym)]);
xlabel ('Time')
ylabel ('Amplitude')
title ('Modulated Signal')
the error :
Error using real
Not enough input arguments.
Error in lab4dm (line 11)
plot(t,[x real (ym)]);
0 件のコメント
採用された回答
the cyclist
2021 年 11 月 21 日
You need
real(ym)
instead of
real (ym)
2 件のコメント
Stephen23
2021 年 11 月 21 日
"Didn't realize that the space could cause errors"
Because it means that you are using command syntax:
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Modulation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!