I would like to replace every possible $A+B$ and $AB$ in expansion of $(A+B)^{10}-A^{10}-B^{10}$ with
$x$ and $y$, respectively. How to do it with the simplest code in Mathematica?
For example,
\begin{align*} (A+B)^3-A^3-B^3 &= 3AB(A+B)\\ &= 3xy \end{align*}
In other words, having $A+B=x$ and $AB=y$, how do I express $(A+B)^{10}-A^{10}-B^{10}$ in terms of $x$ and $y$.
Bonus question
Rather than creating a new question for it, I think I should ask here. If I want to find $a^{10}+b^{10}$ in terms of $x$ and $y$, why does
Simplify[(a + b)^10 - Expand[(a + b)^10 - a^10 - b^10],a b == x && a + b == y]
not produce the expected result?