Given : A={x∈R:x2+(m−1)x−2(m+1)=0}
and B={x∈R:(m−1)x2+mx+1=0}
When m=1, then
A={x:x2−4=0}⇒A={−2,2}B={x:x+1=0}⇒B={−1}∴A∪B={−2,−1,2}
When m≠1, then
x2+(m−1)x−2(m+1)=0⇒x=−(m−1)±√(m−1)2+8(m+1)2⇒x=−(m−1)±√(m+3)22⇒x=2,−(m+1) ⋯(1)
(m−1)x2+mx+1=0⇒x=−m±√m2−4(m−1)2(m−1)⇒x=−m±√(m−2)22(m−1)⇒x=−1,11−m ⋯(2)
For exactly three elements in A∪B, two roots of both the quadratic equation must be same, so the possibilities are
(i) 2=−(m+1)⇒m=−3⇒A∪B={−1,14,2}(ii) 2=11−m⇒m=12⇒A∪B={−1,−32,2}(iii) −(m+1)=−1⇒m=0⇒A∪B={−1,1,2}(iv) −(m+1)=11−m⇒m2=2⇒m=±√2(v) 11−m=−1⇒m=2⇒A∪B={−3,−1,2}
∴m={1,−3,12,0,−√2,√2,2}
Hence, the number of possible values of m is 7.