
theorem
  for L being right_zeroed add-associative right_complementable Abelian
  well-unital distributive associative non trivial non trivial doubleLoopStr
  holds Polynom-Ring({},L) is_ringisomorph_to L
proof
  set n = {};
  let L be right_zeroed add-associative right_complementable Abelian
  well-unital distributive associative non trivial non trivial doubleLoopStr;
  set PL = Polynom-Ring(n,L);
  defpred P[set,set] means ex p being Polynomial of n,L st p = $1 & p.{} = $2;
A1: dom 0_(n,L) = Bags n by FUNCT_2:def 1;
A2: EmptyBag n in dom(EmptyBag n .--> 1_L) by TARSKI:def 1;
A3: for b being bag of {} holds b = {}
  proof
    let b be bag of {};
    b in Bags {} by PRE_POLY:def 12;
    hence thesis by PRE_POLY:51,TARSKI:def 1;
  end;
  then
A4: EmptyBag n = {};
  then reconsider i = {} as bag of n;
A5: for x being Element of PL ex y being Element of L st P[x,y]
  proof
    let x be Element of PL;
    reconsider p = x as Polynomial of n,L by POLYNOM1:def 11;
    take p.{};
    dom p = Bags n by FUNCT_2:def 1;
    then
A6: p.{} in rng p by A4,FUNCT_1:3;
    rng p c= the carrier of L by RELAT_1:def 19;
    hence thesis by A6;
  end;
  consider f being Function of the carrier of PL,the carrier of L such that
A7: for x being Element of PL holds P[x,f.x] from FUNCT_2:sch 3(A5);
A8: dom f = the carrier of PL by FUNCT_2:def 1;
  reconsider f as Function of PL,L;
  consider p being Polynomial of n,L such that
A9: p = 1_PL and
A10: p.{} = f.(1.PL) by A7;
A11: p = 1_(n,L) by A9,POLYNOM1:31
    .= 0_(n,L)+*(EmptyBag n,1_L) by POLYNOM1:def 9;
  for x,y being Element of PL holds f.(x*y) = f.x * f.y
  proof
    let x,y be Element of PL;
    consider p being Polynomial of n,L such that
A12: p = x & p.{} = f.x by A7;
    consider q being Polynomial of n,L such that
A13: q = y & q.{} = f.y by A7;
A14: (p*'q).{} = p.i * q.i
    proof
A15:  decomp EmptyBag n = <* <*EmptyBag n, EmptyBag n*> *> by PRE_POLY:73;
      then
A16:  len decomp EmptyBag n = 1 by FINSEQ_1:39;
      set z = p.i * q.i;
      consider s being FinSequence of the carrier of L such that
A17:  (p*'q).(EmptyBag n) = Sum s and
A18:  len s = len decomp EmptyBag n and
A19:  for k being Element of NAT st k in dom s ex b1, b2 being bag of
n st (decomp EmptyBag n)/.k = <*b1, b2*> & s/.k = p.b1*q.b2 by POLYNOM1:def 10;
      len s = 1 by A15,A18,FINSEQ_1:39;
      then Seg 1 = dom s by FINSEQ_1:def 3;
      then
A20:  1 in dom s by FINSEQ_1:2,TARSKI:def 1;
      then consider b1,b2 being bag of n such that
      (decomp EmptyBag n)/.1 = <*b1, b2*> and
A21:  s/.1 = p.b1*q.b2 by A19;
      s.1 = p.b1 * q.b2 by A20,A21,PARTFUN1:def 6
        .= p.i * q.b2 by A3
        .= p.i * q.i by A3;
      then s = <* z *> by A16,A18,FINSEQ_1:40;
      then Sum s = z by RLVECT_1:44;
      hence thesis by A3,A17;
    end;
    ex pq being Polynomial of n,L st pq = x * y & pq.{} = f.( x*y) by A7;
    hence thesis by A12,A13,A14,POLYNOM1:def 11;
  end;
  then
A22: f is multiplicative by GROUP_6:def 6;
  for x,y being Element of PL holds f.(x+y) = f.x + f.y
  proof
    let x,y be Element of PL;
    consider p being Polynomial of n,L such that
A23: p = x and
A24: p.{} = f.x by A7;
    consider q being Polynomial of n,L such that
A25: q = y and
A26: q.{} = f.y by A7;
    consider a being Element of L such that
A27: p = {EmptyBag n} --> a by Lm1;
A28: ex pq being Polynomial of n,L st pq = x + y & pq.{} = f.( x+y) by A7;
    consider b being Element of L such that
A29: q = {EmptyBag n} --> b by Lm1;
A30: p.{} = a by A4,A27;
A31: (p+q).{} = p.i + q.i by POLYNOM1:15
      .= a + b by A4,A30,A29;
    q.{} = b by A4,A29;
    then f.x + f.y = a + b by A4,A24,A26,A27;
    hence thesis by A23,A25,A28,A31,POLYNOM1:def 11;
  end;
  then
A32: f is additive by VECTSP_1:def 20;
  p.i = p.(EmptyBag n) by A3
    .= (0_(n,L)+*(EmptyBag n .--> 1_L)).(EmptyBag n) by A11,A1,FUNCT_7:def 3
    .= (EmptyBag n .--> 1_L).(EmptyBag n) by A2,FUNCT_4:13
    .= 1_L by FUNCOP_1:72;
  then f is unity-preserving by A9,A10,GROUP_1:def 13;
  then
A33: f is RingHomomorphism by A32,A22;
A34: for u being object holds u in the carrier of L implies u in rng f
  proof
    let u be object;
    assume u in the carrier of L;
    then reconsider u as Element of L;
    set p = EmptyBag n .--> u;
    reconsider p as Function;
    rng p = {u} & dom p = Bags n by FUNCOP_1:8,PRE_POLY:51,TARSKI:def 1;
    then reconsider p as Function of Bags n, the carrier of L by FUNCT_2:2;
    reconsider p as Function of Bags n, L;
    reconsider p as Series of n, L;
    now
      per cases;
      case
A35:    u = 0.L;
        Support p = {}
        proof
          set v = the Element of Support p;
          assume Support p <> {};
          then
A36:      v in Support p;
          then v is bag of n;
          then p.v = p.(EmptyBag n) by A3,A4
            .= u by FUNCOP_1:72;
          hence thesis by A35,A36,POLYNOM1:def 4;
        end;
        hence Support p is finite;
      end;
      case
A37:    u <> 0.L;
A38:    for v being object holds v in {EmptyBag n} implies v in Support p
        proof
          let v be object;
          assume
A39:      v in {EmptyBag n};
          then reconsider v as Element of Bags n;
          p.v = p.(EmptyBag n) by A39,TARSKI:def 1
            .= u by FUNCOP_1:72;
          hence thesis by A37,POLYNOM1:def 4;
        end;
        for v being object holds v in Support p implies v in {EmptyBag n}
        proof
          let v be object;
          assume v in Support p;
          then reconsider v as bag of n;
          v = EmptyBag n by A3,A4;
          hence thesis by TARSKI:def 1;
        end;
        hence Support p is finite by A38,TARSKI:2;
      end;
    end;
    then reconsider p as Polynomial of n,L by POLYNOM1:def 5;
    reconsider p9 = p as Element of PL by POLYNOM1:def 11;
    consider q being Polynomial of n,L such that
A40: q = p9 and
A41: q.{} = f.p9 by A7;
    q.{} = p.(EmptyBag n) by A3,A40
      .= u by FUNCOP_1:72;
    hence thesis by A8,A41,FUNCT_1:3;
  end;
  rng f c= the carrier of L by RELAT_1:def 19;
  then for u being object holds u in rng f implies u in the carrier of L;
  then rng f = the carrier of L by A34,TARSKI:2;
  then f is onto;
  then
A42: f is RingEpimorphism by A33;
  for x1,x2 being object st x1 in dom f & x2 in dom f & f.x1 = f.x2
holds x1 = x2
  proof
    let x1,x2 be object;
    assume that
A43: x1 in dom f & x2 in dom f and
A44: f.x1 = f.x2;
    reconsider x1,x2 as Element of PL by A43;
    consider p being Polynomial of n,L such that
A45: p = x1 & p.{} = f.x1 by A7;
    consider q being Polynomial of n,L such that
A46: q = x2 & q.{} = f.x2 by A7;
    consider a2 being Element of L such that
A47: q = {EmptyBag n} --> a2 by Lm1;
A48: q.(EmptyBag n) = a2 by A47;
A49: p.{} = p.(EmptyBag n) by A3;
    consider a1 being Element of L such that
A50: p = {EmptyBag n} --> a1 by Lm1;
    thus thesis by A3,A44,A45,A46,A50,A47,A48,A49;
  end;
  then f is one-to-one by FUNCT_1:def 4;
  then f is RingMonomorphism by A33;
  then f is RingIsomorphism by A42;
  hence thesis by QUOFIELD:def 23;
end;
