Motor Boat

A captain on a motor boat successfully stops their vessel from crashing into a dock by reducing the velocity uniformly from 5 m/s to 1 m/s during the first 20 m. Assuming constant deceleration, what is the total distance traveled by the boat before coming to a rest?

Expand Hint
$$$v^2=v_0^2+2a_0(s-s_0)$$$
where $$v$$ is the velocity along the direction of travel, $$v_0$$ is the velocity at time $$t_0$$ , $$a_0$$ is constant acceleration, $$s$$ is the displacement at time $$t$$ along the line of travel, and $$s_0$$ is the displacement at time $$t_0$$ .
Hint 2
Use the above equation to first solve for acceleration, then again for the total distance.
For constant acceleration, the equation for velocity as a function of position:
$$$v^2=v_0^2+2a_0(s-s_0)$$$
where $$v$$ is the velocity along the direction of travel, $$v_0$$ is the velocity at time $$t_0$$ , $$a_0$$ is constant acceleration, $$s$$ is the displacement at time $$t$$ along the line of travel, and $$s_0$$ is the displacement at time $$t_0$$ .

First, let’s solve for acceleration from the first 20 m scenario:
$$$(1m/s)^2=(5m/s)^2+2a(20m)$$$
$$$a=\frac{(1m/s)^2-(5m/s)^2}{2(20m)}=\frac{(1-25)m^2/s^2}{40m}=\frac{-24m}{40s^2}=-0.6\:m/s^2$$$
Since acceleration is constant, let’s reuse the same equation to analyze the whole picture:
$$$(0m/s)^2=(5m/s)^2+2(-0.6m/s^2)(x)$$$
where $$x$$ is the total distance traveled. Therefore,
$$$x=\frac{-(5m/s)^2}{2(-0.6m/s^2)}=\frac{-25m^2/s^2}{-1.2m/s^2}=20.83\:m$$$
20.83 m