I assume this needs to be solved for x?
x^2+m^2x^2+2mcx+c^2=a^2.
x^2(1+m^2)+2mcx+c^2=a^2.
x^2+(2mc/(1+m^2))x+c^2/(1+m^2)=a^2/(1+m^2).
Complete the square:
x^2+(2mc/(1+m^2))x+(mc/(1+m^2))^2+c^2/(1+m^2)=
a^2/(1+m^2)+(mc/(1+m^2))^2.
(x+(mc/(1+m^2))^2=a^2/(1+m^2)+(mc/(1+m^2))^2-c^2/(1+m^2)=
(a^2-c^2)/(1+m^2)+(mc/(1+m^2))^2.
Take square roots of each side:
x+(mc/(1+m^2)=±√(a^2-c^2)(1+m^2)+(mc/(1+m^2))^2)/(1+m^2).
So x=-(mc/(1+m^2)±√(a^2-c^2)(1+m^2)+(mc)^2)/(1+m^2).
x=(-mc±√((mc)^2+(a^2-c^2)(1+m^2))/(1+m^2).
The same result is obtained by applying the quadratic formula.