I am attempting to derive a function modelling the position of the midpoint of the rear axis of a car, given the function modelling the position of the midpoint of the front axis of a car. I found the following paper:
On Page 3, it gives the following lines for the derivation:
$$\dot{B}(t)=-\gamma(t)B(t)-\dot{P}(t)$$ $$\dot{B}\cdot B=-\gamma(t)||B||^2-\dot{P}\cdot B$$ $$0=\frac{d}{dt}(||B||^2)=-2\gamma L^2 -2\dot{P}\cdot B$$
Where $P(t)$ is the position of the midpoint of the rear axis of the car, $B(t)$ is the direction vector between the midpoints of the front and rear axes of the car, with magnitude $L$, and $\gamma(t)$ is scalar function representing the speed of $Q(t)$.
However, I do not know how the 3rd line was derived fromo the 2nd line. Could this process be explained?
First, note $||B||^2 = B \cdot B$. Thus,
$$\frac{d}{dt}(||B||^2) = \frac{d}{dt}(B \cdot B) = 2B \cdot \dot{B} \tag{1}\label{eq1}$$
This uses that the product rule also applies to dot products, such as discussed at Proof for Derivative of Dot Product.
This shows \eqref{eq1} is double the LHS of the second line, so if you multiply both sides of that line by $2$, you'll get the RHS of \eqref{eq1} on the LHS of the third line you're asking about. Also, since $B(t) = Q(t) - P(t)$ and the distance between $P(t)$ and $Q(t)$ is fixed, this means $||B||^2$ is a constant. Thus, it's derivative WRT to time will be $0$. Finally, from somewhat earlier on that page, $L(\cos(\phi),\sin(\phi)) = B(t)$, so their magnitudes are equal. However, I'm not quite sure how they are able to specifically state $L^2 = ||B||^2$.