
theorem ISM:
  for a,b,c,d be positive Real st (a + b = c + d & a*b = c*d) holds
  max (a,b) = max (c,d)
  proof
    let a,b,c,d be positive Real such that
    A1: a + b = c + d & a*b = c*d;
    reconsider x = max (a,b) as positive Real;
    reconsider y = min (a,b) as positive Real;
    reconsider z = max (c,d) as positive Real;
    reconsider t = min (c,d) as positive Real;
    ((max (a,b) = a & min (a,b) = b) or (max (a,b) = b & min (a,b) = a)) &
    ((max (c,d) = c & min (c,d) = d) or (max (c,d) = d & min (c,d) = c))
      by XXREAL_0:def 9,def 10; then
    x*(z + t - x) = z*(x + y - z) by A1; then
    A3: x*(x - t) = z*(z - y);
    A4: x - z = t - y by A1,SAD; then
    x - t = 0 or x = z by A3,XCMPLX_1:5; then
    per cases;
    suppose
      x = z;
      hence thesis;
    end;
    suppose
      B1: x = t;
      x >= a & a >= y & z >= c & c >= t by XXREAL_0:17,25; then
      x >= y & z >= t by XXREAL_0:2;
      hence thesis by B1,A4,XXREAL_0:1;
    end;
  end;
