Look not to understand a part of the convolution simulation code, a great god answer:
The code is as follows:
T=0.01;
T1=0;
T2=3;
T3=2;
T4=2;
T5=t1: T: t2; % generated t5 time vector
T6=t3: T: t4; % generated t6 time vector
F1=2 * exp (2 * t5); % sample value vector generation f1
F2=3 * (stepfun (t6, - 1) - stepfun (t6, 2)); % stepfun () is the unit step function
[y]=conv (f1, f2); % conv for calculating f1, f2 convolution
Y=y * T;
T=(t1 + t3) : t: + t4 (t2);
Subplot (313);
The plot (t, y);
The axis ([(t1 + t3), + t4 (t2), min (y), Max (y) + 0.5]).
Ylabel (' y (t));
The line ([0, 0], [0,2.5]);
The title (' signal convolution);
There was a line y=y * T;
This line of code is what ah, not to say that [y]=conv (f1, f2); Has been begged convolution, so why take the amplitude transform T do?