Calculate the angle between two vectors

Calculator for calculating the angle between two vectors


This page calculates the angle between two vectors. To perform the calculation enter the X/Y coordinates of the two vectors. Then click on the 'Calculate' button.


Vector angle calculator

 Input
Vector a Vector b
x
y
Decimal places
 Results
Angle


Formulas of angle between vectors


\(\displaystyle cos(θ) = \frac{\vec{a}·\vec{b}}{|\vec{a}|·|\vec{b}|}\)

The scalar product of the two vectors is in the numerator and the product of the absolute value (lengths) of the vectors is in the denominator.


Example


Calculation of the angle between \(\displaystyle \vec{a} = \left[\matrix{4 \\ 5 }\right]\)   and   \(\displaystyle \vec{b} = \left[\matrix{-7 \\ \;\;2 }\right]\)


1. Calculate scalar product

\(\displaystyle \vec{a}·\vec{b}=4·(-7)+5·2=(-28)+10=-18\)

2. Calculate lengths of vectors

\(\displaystyle |\vec{a}| = \sqrt{4^2+5^2} =\sqrt{16+25}=\sqrt{41}\)
\(\displaystyle |\vec{b}| = \sqrt{-7^2+2^2} =\sqrt{49+4}=\sqrt{53}\)

3. calculate formula

\(\displaystyle cos(θ)=\frac{-18}{\sqrt{41}\cdot\sqrt{53}} ≈ 0.3861\)

\(\displaystyle θ=cos^{-1}(0.3861)≈112.71°\)

More graphics functions

Angle of two lines
Angle of two vectors
Center of a straight line
Distance of two points
Distance of a point and a line
Rise over Run
Slope of a line
Straight line equation
Circular arc
Helix
Koch snowflake



Is this page helpful?            
Thank you for your feedback!

Sorry about that

How can we improve it?