Two points are given: $A (x_1, y_1)$ and $B (x_2, y_2)$. These points form a line.
At point $B$ is the end of the line. I need to calculate the angle that is shown in the figure and also the position of the new point lying on this line that is 5 cm from point $B$. see here
Hint: $$\varphi=\arctan\bigg(\frac{\Delta y}{\Delta x}\bigg)=\arctan\bigg(\frac{y_1-y_2}{x_1-x_2}\bigg)$$ or $$\varphi=\pi-\arctan\bigg(\frac{y_1-y_2}{x_1-x_2}\bigg)$$ why?