How do I find the convolution of the following signals?
Once you understand the intuition of convolution using the link in the comments, you can work on deriving the equations. These problems are a bit tedious at first and can cause confusion if you try to do too much at once. I'm uploading my hand written notes on how to break the problem down. The key is to think about what happens when there is no overlap, partial overlap when the box enters the triangle from the left, full overlap (occurs only when $t=6$), and partial overlap wen the box begins to exit the triangle.



So now we can check our work using MATLAB! We just need to be careful and understand that conv computes the convolution sum, not integral, but we can still use it to approximate. Here is the code to check your work:

%% Do the problem in MATLAB first
% Original time axis for x(t) and h(t)
t = linspace(-10, 10, 1000);


% Make x(t)
x = zeros( size(t) );
x(  t &lt;= 5 &amp; t &gt;= 3  ) = linspace( 2, 0, length( find( t &lt;= 5 &amp; t &gt;= 3 ) ) );

% Plot the triangle
subplot(4, 1, 1)
plot(t, x)


% Make h(t)
h = zeros( size(t) );
h( t &gt;= 1 &amp; t &lt;= 3 ) = 2;

% Plot the box
subplot(4, 1, 2)
plot(t, h)


% Calculate the convolution and new time axis
y = conv(x, h);
ty = linspace(-20, 20, length(x) + length(h) - 1 );
dy = ty(2) - ty(1);

% Need to multiply by dy to get the same result as doing the integral by hand
% MATLAB conv() does discrete time sum for the convolution but we can
% approximate the integral by multiplying by the time step dy
y = y .* dy;

% Plot the convolution result
subplot(4, 1, 3)
plot(ty, y)
ylim([0 5])


%% Verify using "by-hand" equations
% Make the plot using the derived equations
t = linspace(-10, 10, 100);
y = zeros( size(t) );

tt = t( 4 &lt;= t &amp; t &lt;= 6 );
y( 4 &lt;= t &amp; t &lt;= 6 ) = 10*(tt - 1) - (tt - 1).^2 - 21;

tt = t( 6 &lt; t &amp; t &lt;= 8 );
y( 6 &lt;= t &amp; t &lt;= 8 ) = (tt - 8).^2;

subplot(4, 1, 4)
plot(t, y)
xlim([-20 20])
ylim([0 5])
```