reserve x,y for set;
reserve G for Graph;
reserve vs,vs9 for FinSequence of the carrier of G;
reserve IT for oriented Chain of G;
reserve N for Nat;
reserve n,m,k,i,j for Nat;
reserve r,r1,r2 for Real;
reserve X for non empty set;

theorem Th15:
  for f being FinSequence of TOP-REAL 2 st f is nodic & PairF(f)
  is Simple & f.1<>f.len f holds f is s.n.c.
proof
  let f be FinSequence of TOP-REAL 2;
  assume that
A1: f is nodic and
A2: PairF(f) is Simple and
A3: f.1<>f.len f;
  reconsider f1=f as FinSequence of the carrier of PGraph(the carrier of
  TOP-REAL 2);
A4: len f-'1<=len f by NAT_D:44;
  per cases;
  suppose
A5: len f-'1>2;
    then
A6: len f-'1>1 by XXREAL_0:2;
    then
A7: 1<len f by NAT_D:44;
    len f>=1 by A6,NAT_D:44;
    then
A8: f1 is_oriented_vertex_seq_of PairF(f) by Th7;
A9: 1+1<len f by A5,NAT_D:44;
A10: len f-'1=len f-1 by A6,NAT_D:39;
    then
A11: (len f-'1)+1=len f;
    now
      assume
A12:  LSeg(f,1) meets LSeg(f,len f-'1);
      now
        per cases by A1,A12;
        case
          LSeg(f,1) /\ LSeg(f,(len f-'1))={f.1} &(f.1=f.(len f-'1) or
          f.1=f.((len f-'1)+1));
          hence contradiction by A2,A3,A4,A6,A8,A10,Th1;
        end;
        case
A13:      LSeg(f,1) /\ LSeg(f,(len f-'1))={f.(1+1)} &(f.(1+1)=f.(len
          f-'1) or f.(1+1)=f.((len f-'1)+1));
          now
            per cases by A13;
            case
              f.(1+1)=f.(len f-'1);
              hence contradiction by A2,A4,A5,A8,Th1;
            end;
            case
              f.(1+1)=f.((len f-'1)+1);
              hence contradiction by A2,A8,A9,A10,Th1;
            end;
          end;
          hence contradiction;
        end;
        case
          LSeg(f,1)=LSeg(f,(len f-'1));
          then LSeg(f/.1,f/.(1+1))=LSeg(f,(len f-'1)) by A9,TOPREAL1:def 3;
          then
A14:      LSeg(f/.1,f/.(1+1))=LSeg(f/.(len f-'1),f/.((len f-'1)+ 1)) by A6,A10,
TOPREAL1:def 3;
A15:      1+1<(len f-'1)+1 by A6,XREAL_1:6;
          (len f-'1)<len f by A11,NAT_1:13;
          then
A16:      f/.(len f-'1)=f.(len f-'1) by A6,FINSEQ_4:15;
          1<len f by A6,NAT_D:44;
          then
A17:      f/.1=f.1 by FINSEQ_4:15;
A18:      f/.(1+1)=f.(1+1) & f/.((len f-'1)+1)=f.((len f-'1)+1) by A7,A9,A10,
FINSEQ_4:15;
          now
            per cases by A14,A17,A16,A18,SPPOL_1:8;
            case
              f.1=f.(len f-'1) & f.(1+1)=f.((len f-'1)+1);
              hence contradiction by A2,A8,A10,A15,Th1;
            end;
            case
              f.1=f.((len f-'1)+1) & f.(1+1)=f.(len f-'1);
              hence contradiction by A3,A10;
            end;
          end;
          hence contradiction;
        end;
      end;
      hence contradiction;
    end;
    hence thesis by A1,A2,Th13,Th14;
  end;
  suppose
A19: len f-'1<=2;
    for i,j be Nat st i+1 < j holds LSeg(f,i) misses LSeg(f,j)
    proof
      let i,j be Nat;
      assume
A20:  i+1 < j;
      per cases;
      suppose
A21:    1<=i & j+1<=len f;
        then 1<i+1 by NAT_1:13;
        then 1+1<i+1+1 by XREAL_1:8;
        then
A22:    1+1+1<=i+1+1 by NAT_1:13;
        i+1+1<j+1 by A20,XREAL_1:6;
        then i+1+1<len f by A21,XXREAL_0:2;
        then 1+1+1<len f by A22,XXREAL_0:2;
        then
A23:    1+1+1-1<len f-1 by XREAL_1:9;
        then 1<len f-1 by XXREAL_0:2;
        hence thesis by A19,A23,NAT_D:39;
      end;
      suppose
A24:    1>i or j+1>len f;
        now
          per cases by A24;
          case
            1>i;
            then LSeg(f,i)={} by TOPREAL1:def 3;
            hence LSeg(f,i) /\ LSeg(f,j) = {};
          end;
          case
            j+1>len f;
            then LSeg(f,j)={} by TOPREAL1:def 3;
            hence LSeg(f,i) /\ LSeg(f,j) = {};
          end;
        end;
        hence thesis;
      end;
    end;
    hence thesis by TOPREAL1:def 7;
  end;
end;
