How is the angle between 2 vectors in more than 3 dimensions defined?

If your two vectors $v$ and $w$ are not collinear then they span a two-dimensional plane $E\subset{\mathbb R}^n$. This plane inherits the given scalar product in ${\mathbb R}^n$ and so becomes an ordinary euclidean plane like the sheet of paper you are drawing on. The angles in this plane are related to the scalar product as they are in two-dimensional vector geometry, namely by $$\cos\bigl(\angle(v,w)\bigr)={\langle v, w\rangle\over|v|\ |w|}\ .$$


In the $n$-dimensional real space the angle between two vectors is defined by the inner-product: $$\cos\theta=\frac{\langle v,w \rangle}{||v||\cdot||w||}$$ Where $||v||$ is the length of the vector.


While you can certainly compute the angle using the usual inner product formula, it's also possible and perfectly acceptable to use the same flavor of geometric definition of angles as is done in $\mathbb{R}^2$ and $\mathbb{R}^3$. Radially project two given nonzero vectors onto the unit sphere via the map $\vec{x}\to\vec{x}/\|\vec{x}\|$. Any two nonidentical points on a hypersphere determine a unique "great circle" containing both of them; the angle in radians can be defined as the length of the shorter arc between the two. (Of course, this raises the question, "How is arclength defined in higher dimensions?" - but this is moot given that the 2 and 3-dimensional definitions immediately generalize to any dimension.)

Demonstrating the inner product formula works in higher dimensions given this definition is fairly easy: the general idea is to use an orthonormal change-of-base matrix $M$ which takes the plane determined by the great circle containing two unit vectors to the $xy$-plane (inner products are unchanged under $M$'s action: $\langle Mx,My\rangle = \langle x,M^TMy\rangle = \langle x,Iy\rangle=\langle x,y\rangle$) and then the formula's validity is reduced to the two-dimensional case.


Another approach, from Levandosky:

Using the triangle inequality it is possible to make sense of the angle between two vectors in $R^n$. Let $v$ and $w$ be nonzero vectors in $R^n$ and assume that $v$ is not a scalar multiple of $w$. We can associate to this pair of vectors a triangle in the plane with side lengths $A = |v|, B = |w|$, and $C = |v - w|.$ To see that there exists such a triangle we apply the triangle inequality three times .... By the SSS Theorem of plane geometry, all such triangles are congruent. We can therefore define the angle $\theta$ between $v$ and $w$ to be the corresponding angle in any plane triangle with sides of length $|v|$,$|w|$, and $|w-v|$. If $v=cw$ we define $\theta=0$ if $c$ is positive and $\theta=\pi$ if $c$ is negative.