I would use Pascal's triangle. You need the first seven (7) levels.
level 1 1
level 2 1 1
level 3 1 2 1
level 4 1 3 3 1
level 5 1 4 6 4 1
level 6 1 5 10 10 5 1
level 7 1 6 15 20 15 6 1
You get the numbers by adding the two numbers above together. Now we use the X and Y to create the factors. x goes down and y goes up.
x^6+6x^5y+15x^4y^2+20x^3y^3+15x^2y^4+6xy^5+y^6