
theorem bag2:
for R being domRing
for B1 being bag of the carrier of R
holds card B1 = 1 iff ex a being Element of R st B1 = Bag{a}
proof
let F be domRing, B1 be bag of the carrier of F;
A: now assume B: card B1 = 1;
   then C: support B1 <> {} by RING_5:23;
   set a = the Element of support B1;
   G: a in support B1 by C; then
   reconsider a as Element of F;
   B1.a <> 0 by C,PRE_POLY:def 7; then
   E: B1.a >= 1 & B1.a <= 1 by B,bag2a,NAT_1:14;
   now let o be object;
     assume o in support B1;
     then B1.o <> 0 by PRE_POLY:def 7;
     then o = a by B,E,bag2b,XXREAL_0:1;
     hence o in {a} by TARSKI:def 1;
     end; then
   F: support B1 c= {a};
   {a} c= support B1 by G,TARSKI:def 1; then
   D: support B1 = {a} by F;
   card {a} = 1 by CARD_2:42;
   then B1 = ({a},1)-bag by B,D,UPROOTS:13 .= Bag{a} by RING_5:def 1;
   hence ex a being Element of F st B1 = Bag{a};
   end;
now assume ex a being Element of F st B1 = Bag{a}; then
  consider a being Element of F such that A: B1 = Bag{a};
  B1 = ({a},1)-bag by A,RING_5:def 1;
  then card B1 = card {a} by UPROOTS:13;
  hence card B1 = 1 by CARD_2:42;
  end;
hence thesis by A;
end;
