# Cube of Sum

## Reference > Algebra: Sums and Differences of Squares and Cubes

 DescriptionThe Cube of Sum Rule states that:$${(a+b)}^{3}={a}^{3}+3{a}^{2}b+3a{b}^{2}+{b}^{3}$$
 Examples${x}^{3}+6{x}^{2}+12x+8$1 Rewrite it in the form $${a}^{3}+3{a}^{2}b+3a{b}^{2}+{b}^{3}$$, where $$a=x$$ and $$b=2$$.${x}^{3}+3{x}^{2}(2)+3(x)\times {2}^{2}+{2}^{3}$2 Use Cube of Sum: $${(a+b)}^{3}={a}^{3}+3{a}^{2}b+3a{b}^{2}+{b}^{3}$$.${(x+2)}^{3}$Done(x+2)^3