The inner product determines the structure of the space The Hilbert space employs inner product to determine the geometric structure,e.x. the angle. But I couldn't understand how. For example, the key structure of Euclidean space $\mathbb{R}^2$ is that it is a plane, with the inner product $x_1x_2+y_1y_2$, why can we know that it shows that structure?  
 A: Take two vectors $v = (v_1,...,v_n), w = (w_1,...w_2)$ in general Euclidean space $\mathbb{R}^n$ and suppose that they have an angle $\theta$ between them. By the law of cosines we know
$$\|v\|^2 + \|w\|^2 - 2\|v\|\|w\|\cos\theta = \|v - w\|^2$$
Rearranging a bit and expanding by the euclidean norm we get:
$$2\|v\|\|w\|\cos\theta = \|v\|^2 + \|w\|^2 - \|v - w\|^2 = \sum v_i^2 + \sum w_i^2 - \sum(w_i^2 - 2w_iv_i +v_i^2) = \sum 2w_iv_i$$
Cancelling a factor of two, we have the identity $\|w\|\|v\|\cos\theta = v \cdot w$. This is in fact, the definition of dot product I first was introduced by a multivariable book in high school, and the simpler componentwise expression was derived later. 
However, this method can in some sense be reverse engineered. If we have an inner product space, and the associated norm, but have no immediate way to define angle (function spaces, sequence spaces, hell even in Euclidean space of higher dimension) we can derive by the same argument that we should have by the law of cosines that
$$ \langle v, w\rangle = \|v\|\|w\|\cos\theta$$
So, if we want to define the angle between vectors we simply say it is
$$\theta = \arccos\left(\frac{ \langle v, w\rangle}{ \|v\|\|w\|}\right)$$
(note: this is well-defined by Cauchy-Schwarz, as the argument is in $[-1,1]$.)
A few other nice things: As a particular result of the above we can define orthogonality by $v\cdot w = 0$. We have the pythagorean theorem for triangles with legs orthogonal vectors. we have the parallelogram law (this in fact is sufficicent to characterize norms that arise from inner products). 
This also allows us to do things "canonically" that we couldn't do otherwise. For example, for a closed subspace $W$ of the Hilbert space, we can canonically choose a complementary closed subspace $V$ with $W + V$ being the whole space, simply by taking the space of vectors orthogonal to it. 
