 reserve n,m for Nat,
      o for object,
      p for pair object,
      x,y,z for Surreal;

theorem Th17:
  for x1,x2,y,z be Surreal st not x2 == 0_No & y = x1*x2" holds
     (y*y < z iff x1*x1 < z*(x2*x2)) &
     (z < y*y iff z*(x2*x2) < x1*x1)
proof
  let x1,x2,y,z be Surreal such that
A1:not x2 == 0_No & y = x1*x2";
  x2*x2" == 1_No by A1,SURREALI:33;
  then (x2*x2") * (x2*x2") == 1_No * (x2*x2") == 1_No * 1_No = 1_No
  by SURREALR:54;
  then
A2: (x2*x2") * (x2*x2") == 1_No by SURREALO:4;
  (x2"* x2") * (x2*x2) == x2"* (x2" * (x2*x2)) == x2"* (x2" * x2*x2)
  by SURREALR:54,69;
  then (x2"* x2") * (x2*x2) == x2"* ((x2" * x2)*x2) == x2"* x2*(x2" * x2)
  by SURREALO:4,SURREALR:69;
  then (x2"* x2") * (x2*x2) == x2"* x2*(x2" * x2) by SURREALO:4;
  then
A3: (x2"* x2") * (x2*x2) == 1_No by A2,SURREALO:4;
  y*y == x1*(x2"* (x2"*x1)) == x1*(x1* (x2"* x2"))
  by SURREALR:54,69,A1;
  then y*y == x1*(x1* (x2"* x2")) == (x1*x1)* (x2"* x2")
  by SURREALO:4,SURREALR:69;
  then y*y == (x1*x1)* (x2"* x2") by SURREALO:4;
  then y*y * (x2*x2) == (x1*x1)* (x2"* x2") * (x2*x2) ==
  (x1*x1)* ((x2"* x2") * (x2*x2)) by SURREALR:54,69;
  then y*y * (x2*x2) == (x1*x1)* ((x2"* x2") * (x2*x2)) ==
  (x1*x1)* 1_No = (x1*x1) by A3,SURREALO:4,SURREALR:54;
  then
A4:y*y * (x2*x2) == x1*x1 by SURREALO:4;
A5: 0_No < x2*x2 by A1,SURREALR:72;
  thus y*y < z implies x1*x1 < z*(x2*x2)
  proof
    assume y*y < z;
    then y*y*(x2*x2) < z*(x2*x2) by A5,SURREALR:70;
    hence thesis by A4,SURREALO:4;
  end;
  A6: 0_No <= x2*x2 by A1,SURREALR:72;
  thus x1*x1 < z*(x2*x2) implies y*y < z
  proof
    assume x1*x1 < z*(x2*x2);
    then y*y * (x2*x2) < z*(x2*x2) by A4,SURREALO:4;
    hence thesis by A6,SURREALR:75;
  end;
  thus z < y*y implies z*(x2*x2) < x1*x1
  proof
    assume z < y*y;
    then z*(x2*x2) < (y*y)*(x2*x2) by A5,SURREALR:70;
    hence thesis by A4,SURREALO:4;
  end;
  assume z*(x2*x2) < x1*x1;
  then z*(x2*x2) < y*y * (x2*x2) by A4,SURREALO:4;
  hence thesis by A6,SURREALR:75;
end;
