Definition of General Angles and Perpendicularity
Definition 1
Let’s say $V$ is a vector space. For two vectors $\mathbf{u}, \mathbf{v} \in V$, $\theta$ is defined as the angle between two vectors if it satisfies the following. $$ \cos \theta = {{ \left< \mathbf{u}, \mathbf{v} \right> } \over { \left| \mathbf{u} \right| \left| \mathbf{v} \right| }} $$ If two vectors $\mathbf{u}, \mathbf{v}$ satisfy $\left< \mathbf{u}, \mathbf{v} \right> = 0$, then $\mathbf{u}$ is said to be orthogonal or perpendicular to $\mathbf{v}$, and is shown as $\mathbf{u} \perp \mathbf{v}$.
- $\left< \cdot, \cdot \right>$ is the dot product, and $| \cdot |$ is the length of the vector, which is calculated as $\left| \mathbf{u} \right| := \sqrt{ \left< \mathbf{u}, \mathbf{u} \right> }$.
Explanation
Although not everyone may agree, orthogonal has an abstract nuance and perpendicular has a geometric feel. Basically, it doesn’t matter which word you use, just bear in mind that ‘perpendicular’ is not seriously a minor term as the tex symbol $\perp$ uses \perp
.
Contrary to considering the dot product as the magnitude of vectors and inner angles in the curriculum, in multidimensional Euclidean space $V = \mathbb{R}^{n}$, angles are rather thought through dot products. According to this generalized definition, one can think about the ‘difference in direction’ of two vectors without the need for words like ‘coordinates’.
Application
In applied mathematics, including machine learning, measures like cosine similarity are used based on this. For example, when the frequencies of specific words a, b, c are represented as vectors in two documents A and B, it becomes a measure to understand how similar the two documents are.
If the length of document B is overwhelmingly longer than document A, for example, 100 pages to 1000 pages, the frequency of words would naturally be proportional, so a simple frequency comparison would be meaningless. By using cosine similarity, instead of simple counts, one compares the directionality of the two documents, which can lead to more reasonable results.
Millman. (1977). Elements of Differential Geometry: p3. ↩︎