reserve i,j,k,n,m for Nat,
        b,b1,b2 for bag of n;

theorem Th23:
  for O being Ordinal,
      L being non empty ZeroStr,
      perm being Permutation of O,
      s being Series of O,L holds
    card Support s = card Support (s permuted_by perm)
proof
  let O be Ordinal, L be non empty ZeroStr,
    perm be Permutation of O,s be Series of O,L;
  set P = s permuted_by perm;
  defpred R[bag of O,bag of O] means $2 = $1*perm;
A1:for x be Element of Bags O ex y be Element of Bags O st R[x,y]
  proof
    let x be Element of Bags O;
    x*perm in Bags O by PRE_POLY:def 12;
    hence thesis;
  end;
  consider f be Function of Bags O,Bags O such that
A2:for x be Element of Bags O holds R[x,f.x] from FUNCT_2:sch 3(A1);
A3:dom f= Bags O by FUNCT_2:52;
  rng perm = O =dom perm by FUNCT_2:52,def 3;
  then
A4: perm*perm" = id O = perm"*perm by FUNCT_1:39;
A5:f is one-to-one
  proof
    let x1,x2 be object such that
A6:x1 in dom f & x2 in dom f & f.x1=f.x2;
    reconsider x1,x2 as Element of Bags O by A6;
A7: f.x1 = x1*perm & f.x2 = x2*perm by A2;
A8:dom x1=O =dom x2 by PARTFUN1:def 2;
A9:(x1*perm)*perm" = x1*(id O) by A4,RELAT_1:36
    .= x1 by A8,RELAT_1:51;
    (x2*perm)*perm" = x2*(id O) by A4,RELAT_1:36
    .= x2 by A8,RELAT_1:51;
    hence thesis by A6,A7,A9;
  end;
A10:f.:(Support P) c= Support s
  proof
    let y be object such that
A11:y in f.:(Support P);
    consider x be object such that
A12:x in dom f & x in Support P & f.x=y by A11,FUNCT_1:def 6;
    reconsider x as Element of Bags O by A12;
    f.x = x*perm in Support s by A2,Th21,A12;
    hence thesis by A12;
  end;
  Support s c= f.:(Support P)
  proof
    let y be object such that
A13:y in Support s;
    reconsider y as Element of Bags O by A13;
A14:y*perm" in Support P by A13,Th22;
A15:dom y=O by PARTFUN1:def 2;
    y*perm" in Bags O by PRE_POLY:def 12;
    then
    f.(y*perm") = (y*perm")*perm by A2
    .= y*(id O) by A4,RELAT_1:36
    .= y by A15,RELAT_1:51;
    hence thesis by A3,FUNCT_1:def 6,A14;
  end;
  then f.:(Support P) = Support s by A10,XBOOLE_0:def 10;
  hence thesis by CARD_1:5,A5,A3,CARD_1:33;
end;
