I have some problem with math today :) Could you tell me how should I calculate $P$ angle?
![img]](../../images/d034417c4f41425b557efe26bc1b8771.webp)
I know first and last point of each line. So I have:
L1 = [(10,10),(15,15)]
L2 = [(15,15),(20,8)]
But I don't have idea how calculate this angle. If I should be more specific I need to know $\cos$ of this angle. I would like to write this in Python.
np.dot()function to get the scalar product of the two vectors. Then if you are interested in the cosine of the angle, divide by magnitudes of both vectors. – Andrew Chin Jun 05 '20 at 13:29