How to expand $(a_0+a_1x+a_2x^2+...a_nx^n)^2$? I know you can easily expand $(x+y)^n$ using the binomial expansion. However, is there a simple summation formula for the following expansion?
$$(a_0+a_1x+a_2x^2+...+a_nx^n)^2$$
I found something called the multinomial theorem on wikipedia but I'm not sure if that applies to this specific problem. Thanks.

For a set with $a_0=1$ I've organized a nice scheme, which even allows to generalize to infinitly many terms $a_k$ . I don't have that with a general $a_0$ at hand, but maybe this helps you to build it up your own one.
It is for a general (integer) power $p$; if you need it for $p=2$ you can set all terms which contain $(p-2)$ to zero (or ignore them).      
 
Errata: I've just found one typo at he coefficient at $x^4$: instead of $a^3b$ we must have $a^2b$
