Convolution signal with Dirac Delta function

11 vues (au cours des 30 derniers jours)
Nick Papanikolaou
Nick Papanikolaou le 24 Déc 2015
I would like to know how can I calculate and plot the result of the convolution: 10sinc(10t)* δ(t-3)
In another example
ts = 0.01; % Sampling step
tx = -5:ts:5; % Time vector for x(t)
x = cos(pi * tx/ 2); % x(t)
th = -2:ts:2; % Time vector for h(t)
h = 2*rectpulse(th,0,2); % h(t)
plot(tx, x, th, h); % Plot the result
ty = -7:ts:7; % Convolution time vector
y = ts*conv(x,h); % Convolution approximation
plot(tx, x, th, h, ty, y); % Plot the result
axis([-8 8 -3 3]);
grid;
xlabel('Time (sec)');
ylabel('Amplitude');
title('Signals of Example 1');
legend('Cosine', 'Rectangular', 'Convolution');
the conv(x,y) command is working ok
Thank you in advance!
  1 commentaire
Charles Albanese
Charles Albanese le 2 Juin 2020
Error using rectpulse
Too many input arguments.

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Trigonometry dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by