Expand an expression using the binomial theorem