reserve FT for non empty RelStr,
  A,B,C for Subset of FT;

theorem Th44:
  for f,g being FinSequence of FT st f is continuous & g is
  continuous & g.1 in U_FT (f/.(len f)) holds f^g is continuous
proof
  let f,g be FinSequence of FT;
  assume that
A1: f is continuous and
A2: g is continuous and
A3: g.1 in U_FT (f/.(len f));
A4: len (f^g)=len f+len g by FINSEQ_1:22;
  len g>=1 by A2;
  then len (f^g)>=0+1 by A4,XREAL_1:7;
  hence len (f^g)>=1;
  let i be Nat,x1 be Element of FT;
  set g2=f^g;
A5: dom f=Seg len f by FINSEQ_1:def 3;
A6: len f>=1 by A1;
  assume that
A7: 1<=i and
A8: i<len(f^g) and
A9: x1=(f^g).i;
  i+1 <=len g2 & 1<i+1 by A7,A8,NAT_1:13;
  then i+1 in dom g2 by FINSEQ_3:25;
  then g2.(i+1)=g2/.(i+1) by PARTFUN1:def 6;
  then reconsider x2=g2.(i+1) as Element of FT;
  per cases;
  suppose
A10: i<len f;
A11: 1<=i+1 by NAT_1:11;
    i+1<=len f by A10,NAT_1:13;
    then i+1 in dom f by A11,FINSEQ_3:25;
    then
A12: g2.(i+1)=f.(i+1) by FINSEQ_1:def 7;
    i in dom f by A5,A7,A10;
    then g2.i=f.i by FINSEQ_1:def 7;
    hence thesis by A1,A7,A9,A10,A12;
  end;
  suppose
A13: i>=len f;
    then
A14: i+1>len f by NAT_1:13;
A15: i<len f+len g by A8,FINSEQ_1:22;
A16: len g2=len f+len g by FINSEQ_1:22;
    then
A17: i+1<=len f+len g by A8,NAT_1:13;
    per cases by A13,XXREAL_0:1;
    suppose
A18:  i=len f;
A19:  len f in dom f by A6,FINSEQ_3:25;
      then
A20:  x1=f.(len f) by A9,A18,FINSEQ_1:def 7
        .=f/.(len f) by A19,PARTFUN1:def 6;
      x2=g.(i+1-len f) by A14,A16,A17,FINSEQ_1:24
        .= g.1 by A18;
      hence thesis by A3,A20;
    end;
    suppose
A21:  i>len f;
      set j=i-'len f;
A22:  i-len f>0 by A21,XREAL_1:50;
      then
A23:  i-'len f=i-len f by XREAL_0:def 2;
      then j+1=i+1-len f;
      then
A24:  x2=g.(j+1) by A14,A16,A17,FINSEQ_1:24;
A25:  i-len f<len g by A15,XREAL_1:19;
      i>=len f+1 by A21,NAT_1:13;
      then
A26:  x1=g.j by A9,A15,A23,FINSEQ_1:23;
      i-'len f>=0+1 by A22,A23,NAT_1:13;
      hence thesis by A2,A23,A24,A26,A25;
    end;
  end;
end;
