a) ta có: \(a\left(a-b\right)+b\left(b+a\right)=a^2-ab+b^2+ab=a^2+b^2\)
Thay a=-5, b=2 vào đa thức, ta có: \(\left(-5\right)^2+2^2=25+4=29\) b) ta có: \(x\left(x^2-y\right)-x\left(x+y\right)+y^2\left(x^2-x\right)=x^3-xy-x^2-xy+x^2y^2-xy^2=x^3-2xy-x^2+x^2y^2-xy^2=x^3+x^2y^2-\left(x^2+xy^2\right)-2xy=x^2\left(x+y^2\right)-x\left(x+y^2\right)-2xy=\left(x^2-x\right)\left(x+y^2\right)-2xy=x\left(x-1\right)\left(x+y^2\right)-2xy\)