The correct option is B x2+x+1
Consider the eq. 1+x+x2=0
Roots of the above eq. are w & w2
where w is the cube root of unity.
∴w3=1&1+w+w2=0
f(x)=x3m+x3n−1+x3r−2
f(w)=w3m+w3n−1+w3r−2=(w3)m+(w3)nw+(w3)rw2⇒f(w)=1+w+w2w3=0
f(w2)=w6m+w6n−2+w6r−4=(w3)2m+(w3)2nw2+(w3)2rw4⇒f(w2)=1+w4+w2w6=1+w+w2=0
Since w&w2 are the roots of the equation f(x)=0
⇒f(x) is divisible by (x−w)(x−w2)
Therefore f(x) is divisible by 1+x+x2.
Hence, option 'B' is correct.