Ta có
\(x^3+y^3=a^3+b^3\Rightarrow\left(x+y\right)\left(x^2-xy+y^2\right)=\left(a+b\right)\left(a^2-ab+b^2\right)\)
\(\Rightarrow x^2-xy+y^2=a^2-ab+b^2\) ( vì x+y = a+b )
\(\Rightarrow\left(x+y\right)^2-3xy=\left(a+b\right)^2-3ab\)
\(\Rightarrow-3xy=-3ab\Rightarrow xy=ab\)
\(\Rightarrow2xy=2ab\)
\(\Rightarrow\left(x+y\right)^2=\left(a+b\right)^2\Leftrightarrow x^2+2xy+y^2=a^2+2ab+b^2\)
\(\Leftrightarrow a^2+b^2=x^2+y^2\)
\(\Rightarrow x^2-a^2=b^2-y^2\Rightarrow\left(x-a\right)\left(x+a\right)=\left(b-y\right)\left(b+y\right)\)
Ta có
x+ y = a+b
=> x - a = b-y
* Với
\(x-a=b-y=0\)
\(\Rightarrow x=a;b=y\)
\(\Rightarrow x^{2011}+y^{2011}=a^{2011}+b^{2011}\) (*)
* Với
\(x-a=b-y\ne0\)
\(\Rightarrow x+a=b+y\)
\(\Rightarrow x-y=b-a\)
Mà x+y= b+a
\(\Rightarrow2x=2b\Rightarrow x=b\) ;
\(2y=2a\Rightarrow y=a\)
\(\Rightarrow x^{2011}+y^{2011}=a^{2011}+b^{2011}\) (**)
Kết hợp (*) và (**) ta có
\(P=x^{2011}+y^{2011}=a^{2011}+b^{2011}\)