reserve A,B,O for Ordinal,
        o for object,
        x,y,z for Surreal,
        n,m for Nat;
reserve d,d1,d2 for Dyadic;
reserve i,j for Integer,
        n,m,p for Nat;

theorem Th35:
  x in Day n implies ex d be Dyadic st x == uDyadic.d & uDyadic.d in Day n
proof
  assume
A1: x in Day n;
  then
A2: born x c= n by SURREAL0:def 18;
  per cases;
  suppose ex i be Integer st x == uDyadic.i;
    then consider i be Integer such that
A3:  x == uDyadic.i;
    take i;
    born_eq_set x = born_eq_set uDyadic.i by A3,SURREALO:34;
    then uDyadic.i in born_eq_set x by Th30;
    then uDyadic.i in Day born_eq x by SURREALO:def 6;
    then born uDyadic.i c= born_eq x c= born x
    by SURREAL0:def 18,SURREALO:def 5;
    then born uDyadic.i c= born x by XBOOLE_1:1;
    then born uDyadic.i c= n by A2,XBOOLE_1:1;
    then uDyadic.i in Day born uDyadic.i c= Day n by SURREAL0:def 18,35;
    hence thesis by A3;
  end;
  suppose
A4: for i be Integer holds not x == uDyadic.i;
    per cases;
    suppose
A5:   0_No <=x;
      not x == uDyadic.n by A4;
      then consider x1,y1,p1 be Nat such that
A6:   x == uDyadic.(x1 + y1 / (2|^p1)) & y1 < 2|^p1 & x1+p1 < n
      by A1,A5,Th25;
      not x1 + y1 / (2|^p1) is Integer by A6,A4;
      then consider n2,m2,p2 be Nat such that
A7:   x1 + y1 / (2|^p1) = n2 + (2*m2+1)/(2|^(p2+1)) &
      2*m2+1 < 2|^(p2+1) by Th28;
      take d = n2 + (2*m2+1)/(2|^(p2+1));
A8:   x1 = n2 by A6,A7,Th32;
      then
A9:   n2+(p2+1) <= n2 + p1 by Th34,A7,XREAL_1:6;
      n2+(p2+1) < n by A6,A8,A9,XXREAL_0:2;
      then n2+(p2+1)+1 <= n by NAT_1:13;
      then Segm(n2+(p2+1)+1) c= Segm n by NAT_1:39;
      then
A10:  Day (n2+(p2+1)+1) c= Day n by SURREAL0:35;
      born uDyadic.d = n2+(p2+1)+1 by Th26,A7;
      then uDyadic.d in Day (n2+(p2+1)+1) by SURREAL0:def 18;
      hence thesis by A10,A6,A7;
    end;
    suppose x < 0_No;
      then
A11:  0_No= -0_No <= -x by SURREALR:10;
      born -x = born x c= n by SURREAL0:def 18,A1,SURREALR:12;
      then
A12:  -x in Day (born x) c= Day n by SURREAL0:def 18,35;
      not -x == uDyadic.n
      proof
        assume -x == uDyadic.n;
        then - -x == - uDyadic.n = uDyadic.-n by SURREALR:10,Th27;
        hence thesis by A4;
      end;
      then consider x1,y1,p1 be Nat such that
A13:  -x == uDyadic.(x1 + y1 / (2|^p1)) & y1 < 2|^p1 & x1+p1 < n
      by A12,A11,Th25;
      - -x == -uDyadic.(x1 + y1 / (2|^p1)) by A13,SURREALR:10;
      then x == uDyadic.-(x1 + y1 / (2|^p1)) by Th27;
      then not - -(x1 + y1 / (2|^p1)) is Integer by A4;
      then consider n2,m2,p2 be Nat such that
A14:  x1 + y1 / (2|^p1) = n2 + (2*m2+1)/(2|^(p2+1)) &
      2*m2+1 < 2|^(p2+1) by Th28;
      set d = n2 + (2*m2+1)/(2|^(p2+1));
A15:  x = - -x == - uDyadic.d = uDyadic.-d by A13,A14,SURREALR:10,Th27;
A16:  x1 = n2 by A13,A14,Th32;
      then
A17:  n2+(p2+1) <= n2 + p1 by A14,Th34,XREAL_1:6;
      n2+(p2+1) < n by A13,A16,A17,XXREAL_0:2;
      then n2+(p2+1)+1 <= n by NAT_1:13;
      then Segm(n2+(p2+1)+1) c= Segm n by NAT_1:39;
      then
A18:  Day (n2+(p2+1)+1) c= Day n by SURREAL0:35;
      born uDyadic.d = born (-uDyadic.d) = born (uDyadic.-d)
      by SURREALR:12,Th27;
      then born uDyadic.-d = n2+(p2+1)+1 by Th26,A14;
      then uDyadic.-d in Day (n2+(p2+1)+1) by SURREAL0:def 18;
      hence thesis by A15,A18;
    end;
  end;
end;
