
theorem sq00:
for R being domRing,
    a,b being Element of R holds a^2 = b^2 iff (a = b or a = -b)
proof
let R be domRing, a,b be Element of R;
hereby assume a^2 = b^2;
   then 0.R = a^2 - b^2 by RLVECT_1:15
              .= (a + b) * (a - b) by P4a;
   then per cases by VECTSP_2:def 1;
   suppose a + b = 0.R;
      hence a = b or a = -b by RLVECT_1:6;
     end;
   suppose a - b = 0.R;
     hence a = b or a = -b by RLVECT_1:21;
     end;
   end;
assume a = b or a = -b;
   then per cases;
   suppose a = b;
     hence a^2 = b^2;
     end;
   suppose a = -b;
     hence a^2 = b^2 by VECTSP_1:10;
     end;
end;
