# How to prove $v_1\cdot v_2=|v_1||v_2|\cos(\theta)$ in n-dimensions?

It is easy to prove in 2D that $$v_1\cdot v_2=|v_1||v_2|\cos(\theta)$$ where $$\theta$$ is the angle between $$v_1$$ and $$v_2$$.

But how to generalize? What is the proof in n-dimensions?

• The two vectors span a two dimensional subspace. – Charlie Frohman Apr 23 at 14:09
• @CharlieFrohman ...usually. – Theo Bendit Apr 23 at 14:12
• What definition of the dot product are you starting from? The sum of the products of the terms? – Deepak Apr 23 at 14:17
• Here is how the dot product: $\vec{v} \cdot \vec{w}= v_1*w_1 + v_2*w_2 + ..... + v_n*w_n$ – CSPassionant Apr 23 at 14:24
• How do you define the angle between two vectors in $n$ dimensions? – md2perpe Apr 23 at 14:33