Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

problem in ploting charts

조회 수: 3 (최근 30일)
hey there
hey there 2020년 7월 12일
마감: MATLAB Answer Bot 2021년 8월 20일
hey there,
this is my code every thing works good with no errors.
but show me some charts az empty, how to fix
is it related to : the Equation doesnt have real value?
code :
syms t
x1 = @(t) (exp(-t) * heaviside(t));
X_w = fourier(x1(t))
h = @(t) heaviside(t + 1) - heaviside(t - 1);
H_w = fourier(h(t))
Y_w = (X_w)*(H_w)
y1 = ifourier(Y_w)
subplot(2, 4, 1);
fplot(X_w, [0, 2*pi]);
grid on;
xlabel("w");
ylabel("X(w)");
subplot(2, 4, 2);
fplot(H_w);
grid on;
xlabel("w");
ylabel("H(w)");
subplot(2, 4, 3);
fplot(Y_w);
grid on;
xlabel("w");
ylabel("Y1(w)");
subplot(2, 4, 4);
fplot(y1);
grid on;
xlabel("t");
ylabel("y1(t)");

답변 (1개)

Takumi
Takumi 2020년 7월 12일
All parts other than y1 are complex, so the real or imaginary part must be specified.
eg. real(X_w)

이 질문은 마감되었습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by