Why do I get an error on line 17?

2 ビュー (過去 30 日間)
Porgs
Porgs 2018 年 5 月 7 日
コメント済み: KSSV 2018 年 5 月 7 日
clc
deviation = (1) .^ 0.5;
n = deviation .* randn(100000, 1); % noise
t = [-5: 0.01: 4.99]; % time
p = 5 .* sin(20 .* pi .* t + (pi / 4)); % pulse p(t)
T = (2 * 1500) / 1000;
t2 = t - T;
p2 = 5 * sin(20 .* pi .* t2 + (pi / 4));
r = p2 + n;
x = randn(length(t), 1);
i = (t - T);
y = linfilt(x, i, length(t));
figure(1);
subplot(3, 1, 1);
plot(t, p);
title('Plot 4a: Pulse p(t)'); % pulse p(t)
xlabel('Time');
ylabel('Amplitude');
grid;
subplot(3, 1, 2);
plot(t2, r);
title('Plot 4b: Received Signal r(t)'); % received signal r(t)
xlabel('Time');
ylabel('Amplitude');
axis([-5 4.99 min(y) max(y)]);
grid;
[C, tau] = xcorr(r,p); % cross-correlation R_rp(tau)
subplot(3, 1, 3);
plot(tau, C);
title('Plot 3c: Cross-Correlation R_rp(tau)');
grid;
  2 件のコメント
Walter Roberson
Walter Roberson 2018 年 5 月 7 日
We do not know which is line 17. Also, linfit() is not a MATLAB routine. There are several linfit() in the File Exchange, but we would not know which one of those you are using.
KSSV
KSSV 2018 年 5 月 7 日
?What is this function linfilt?

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeGraphics Object Identification についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by