reserve X,Y,x,y for set;
reserve A for non empty Poset;
reserve a,a1,a2,a3,b,c for Element of A;
reserve S,T for Subset of A;
reserve f for Choice_Function of BOOL(the carrier of A);
reserve fC,fC1,fC2 for Chain of f;

theorem Th41:
  fC1 <> fC2 implies (fC1 is Initial_Segm of fC2 iff not fC2 is
  Initial_Segm of fC1)
proof
  assume
A1: fC1 <> fC2;
  set N = {a : a in fC1 /\ fC2 & InitSegm(fC1,a) = InitSegm(fC2,a)};
A2: N c= fC1
  proof
    let x be object;
    assume x in N;
    then
    ex a st a = x & a in fC1 /\ fC2 & InitSegm(fC1,a) = InitSegm(fC2,a);
    hence thesis by XBOOLE_0:def 4;
  end;
  then reconsider N as Subset of A by XBOOLE_1:1;
A3: N c= fC2
  proof
    let x be object;
    assume x in N;
    then ex a st a = x & a in fC1 /\ fC2 & InitSegm(fC1,a) = InitSegm(fC2,a);
    hence thesis by XBOOLE_0:def 4;
  end;
A4: now
    let a1,a2;
    assume that
A5: a2 in N and
A6: a1 in fC1 and
A7: a1 < a2;
A8: ex a st a = a2 & a in fC1 /\ fC2 & InitSegm(fC1,a) = InitSegm(fC2,a) by A5;
A9: InitSegm(fC1,a1) = InitSegm(fC2,a1)
    proof
      thus InitSegm(fC1,a1) c= InitSegm(fC2,a1)
      proof
        let x be object;
        assume
A10:    x in InitSegm(fC1,a1);
        then reconsider b = x as Element of A;
A11:    b in fC1 by A10,Th24;
A12:    b < a1 by A10,Th24;
        then b < a2 by A7,Th5;
        then b in InitSegm(fC1,a2) by A11,Th24;
        then b in fC2 by A8,Th24;
        hence thesis by A12,Th24;
      end;
      let x be object;
      assume
A13:  x in InitSegm(fC2,a1);
      then reconsider b = x as Element of A;
A14:  b in fC2 by A13,Th24;
A15:  b < a1 by A13,Th24;
      then b < a2 by A7,Th5;
      then b in InitSegm(fC2,a2) by A14,Th24;
      then b in fC1 by A8,Th24;
      hence thesis by A15,Th24;
    end;
    a1 in InitSegm(fC2,a2) by A6,A7,A8,Th24;
    then a1 in fC2 by XBOOLE_0:def 4;
    then a1 in fC1 /\ fC2 by A6,XBOOLE_0:def 4;
    hence a1 in N by A9;
  end;
A16: now
    let a1,a2;
    assume that
A17: a2 in N and
A18: a1 in fC2 and
A19: a1 < a2;
A20: ex a st a = a2 & a in fC1 /\ fC2 & InitSegm(fC1,a) = InitSegm(fC2,a)
    by A17;
A21: InitSegm(fC1,a1) = InitSegm(fC2,a1)
    proof
      thus InitSegm(fC1,a1) c= InitSegm(fC2,a1)
      proof
        let x be object;
        assume
A22:    x in InitSegm(fC1,a1);
        then reconsider b = x as Element of A;
A23:    b in fC1 by A22,Th24;
A24:    b < a1 by A22,Th24;
        then b < a2 by A19,Th5;
        then b in InitSegm(fC1,a2) by A23,Th24;
        then b in fC2 by A20,Th24;
        hence thesis by A24,Th24;
      end;
      let x be object;
      assume
A25:  x in InitSegm(fC2,a1);
      then reconsider b = x as Element of A;
A26:  b in fC2 by A25,Th24;
A27:  b < a1 by A25,Th24;
      then b < a2 by A19,Th5;
      then b in InitSegm(fC2,a2) by A26,Th24;
      then b in fC1 by A20,Th24;
      hence thesis by A27,Th24;
    end;
    a1 in InitSegm(fC1,a2) by A18,A19,A20,Th24;
    then a1 in fC1 by XBOOLE_0:def 4;
    then a1 in fC1 /\ fC2 by A18,XBOOLE_0:def 4;
    hence a1 in N by A21;
  end;
A28: the InternalRel of A well_orders fC1 & the InternalRel of A well_orders
  fC2 by Def12;
  now
    per cases by A2,A4,A28,A3,A16,Th35;
    suppose
A29:  N is Initial_Segm of fC1 & N = fC2;
      fC1 <> {} by Def12;
      hence thesis by A29,Th31;
    end;
    suppose
A30:  N is Initial_Segm of fC2 & N = fC1;
      fC2 <> {} by Def12;
      hence thesis by A30,Th31;
    end;
    suppose
      N = fC1 & N = fC2;
      hence thesis by A1;
    end;
    suppose
A31:  N is Initial_Segm of fC1 & N is Initial_Segm of fC2;
      fC2 <> {} by Def12;
      then consider b such that
A32:  b in fC2 and
A33:  N = InitSegm(fC2,b) by A31,Def11;
      fC1 <> {} by Def12;
      then consider a such that
A34:  a in fC1 and
A35:  N = InitSegm(fC1,a) by A31,Def11;
A36:  a = f.UpperCone(InitSegm(fC2,b)) by A34,A35,A33,Def12
        .= b by A32,Def12;
      then a in fC1 /\ fC2 by A34,A32,XBOOLE_0:def 4;
      then a in N by A35,A33,A36;
      hence thesis by A35,Th26;
    end;
  end;
  hence thesis;
end;
