Why does $(a+b)^2= a^2+b^2 + 2ab$? Why is the $2ab$ there? When I was doing research on finding the derivative I came across something strange.
If $f(x) = x^2$ you find the derivative by going 
$$\frac{f(x+h)^2-f(x)^2}{h}
=\frac{x^2+2xh+h^2-x^2}{h}.$$
Why is there the $2xh$? Can someone explain the logic behind this? I'm assuming you plus $x$ and $h$ together then square it but why?

\begin{align*}
(a+b)(a + b) &= a(a + b) + b(a + b)\quad &(\text{addition distributes over multiplication})\\
&= aa + ab + ba + bb\quad &(\text{multiplication distributes over addition})\\
&= a^2 + ab + ba + b^2\quad &(xx = x^2)\\
&= a^2 + ab + ab + b^2\quad &(\text{multiplication is commutative})\\
&= a^2 + 2ab + b^2
\end{align*}
