TITLE: dimension of space of polynomials
QUESTION [5 upvotes]: Let $\mathcal P_k^n$ be the space of all polynomials of degree $\leq k$ in $n$ variables. Prove $\dim\mathcal P_k^n = {n+k\choose k}$.
I tried showing this by taking $n\in\mathbb N$ an arbitrary number and using induction for $k$ to show that the formula holds, but couldn't work out the inductive step. How do I work this out?

REPLY [2 votes]: Introduce a dummy variable $x_0$ and count all monomials of exact degree $k$ in the $n+1$ variables $x_0$, $x_1$, $\ldots$, $x_n$. This is a "stars and bars problem": We have $k$ stars in $n+1$ groups and $n$ bars separating the groups, making a total of
$$N={n+k\choose n}$$
such arrangements. This number $N$ is the dimension of your space ${\cal P}_k^{(n)}$.