필터 지우기
필터 지우기

When i try to calculate the convolution of two functions i get: Warning: Using only the real component of complex data.

조회 수: 1 (최근 30일)
m3=length(x3);
n3=length(h1);
X3=[x3,zeros(1,n3)];
H3=[h1,zeros(1,m3)];
for i=1:n3+m3-1
Y3(i)=0;
for j3=1:m3
if(i-j3+1>0)
Y3(i)=Y3(i)+X3(j3)*H3(i-j3+1);
else
end
end
end
figure;
subplot(3,1,1); stem(x3, '-b^'); xlabel('n');
ylabel('x[n]'); grid on;
subplot(3,1,2); stem(h1, '-ms');
xlabel('n'); ylabel('h[n]'); grid on;
subplot(3,1,3); stem(Y3, '-ro');
ylabel('Y[n]'); xlabel('n'); grid on;
title('Convolution of Two Signals without conv function')
What can i do to plot the full real and imaginary parts
  댓글 수: 6

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Subplots에 대해 자세히 알아보기

제품


릴리스

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by