reserve i,j,k,n,m for Nat,
  x,y,z,y1,y2 for object, X,Y,D for set,
  p,q for XFinSequence;

theorem Th5: ::from FINSEQ_5:60
  dom p = dom Rev p & rng p = rng Rev p
proof
  thus
A1: dom p = len p
    .= len (Rev p) by Def1
    .= dom(Rev p);
A2: len p = len(Rev p) by Def1;
  hereby
    let x be object;
    assume x in rng p;
    then consider z being object such that
A3: z in dom p and
A4: p.z = x by FUNCT_1:def 3;
    reconsider i=z as Element of NAT by A3;
    i+1<=len p by NAT_1:13,A3,AFINSQ_1:86;
    then len p -'(i+1)=len p -(i+1) by XREAL_1:233;
    then reconsider j = len p - (i + 1) as Element of NAT;
A5: j in len (Rev p) by A2,AFINSQ_1:86,XREAL_1:44;
    then (Rev p).j = p.(len p - (j + 1)) by Def1;
    hence x in rng(Rev p) by A4,A5,FUNCT_1:def 3;
  end;
  let x be object;
  assume x in rng(Rev p);
  then consider z being object such that
A6: z in dom(Rev p) and
A7: (Rev p).z = x by FUNCT_1:def 3;
  reconsider i=z as Element of NAT by A6;
  i < len p by A2,A6,AFINSQ_1:86;
  then i+1<=len p by NAT_1:13;
  then len p -'(i+1)=len p -(i+1) by XREAL_1:233;
  then reconsider j = len p - (i + 1) as Element of NAT;
  len p -(i+1)<len p by XREAL_1:44;
  then
A8: j in len (Rev p) by A2,AFINSQ_1:86;
  (Rev p).i = p.(len p - (i + 1)) by A6,Def1;
  hence thesis by A1,A7,A8,FUNCT_1:def 3;
end;
