reserve GF for add-associative right_zeroed right_complementable Abelian
  associative well-unital distributive non empty doubleLoopStr;
reserve M for Abelian add-associative right_zeroed right_complementable
  vector-distributive scalar-distributive scalar-associative scalar-unital
   non empty ModuleStr over GF;
reserve W,W1,W2,W3 for Subspace of M;
reserve u,u1,u2,v,v1,v2 for Element of M;
reserve X,Y for set, x,y,y1,y2 for object;
reserve F for Field;
reserve V for VectSp of F;
reserve W for Subspace of V;
reserve W,W1,W2 for Subspace of V;
reserve W1,W2 for Subspace of M;
reserve W for Subspace of V;
reserve W1,W2 for Subspace of M;
reserve u,u1,u2,v for Element of M;
reserve C1 for Coset of W1;
reserve C2 for Coset of W2;

theorem Th46:
  M is_the_direct_sum_of W1,W2 iff for C1 being Coset of W1, C2
  being Coset of W2 ex v being Element of M st C1 /\ C2 = {v}
proof
  set VW1 = the carrier of W1;
  set VW2 = the carrier of W2;
A1: W1 + W2 is Subspace of (Omega).M by Lm6;
  thus M is_the_direct_sum_of W1,W2 implies for C1 being Coset of W1, C2 being
  Coset of W2 ex v being Element of M st C1 /\ C2 = {v}
  proof
    assume
A2: M is_the_direct_sum_of W1,W2;
    then
A3: the ModuleStr of M = W1 + W2;
    let C1 be Coset of W1, C2 be Coset of W2;
    consider v1 being Element of M such that
A4: C1 = v1 + W1 by VECTSP_4:def 6;
    v1 in (Omega).M by RLVECT_1:1;
    then consider v11,v12 being Element of M such that
A5: v11 in W1 and
A6: v12 in W2 and
A7: v1 = v11 + v12 by A3,Th1;
    consider v2 being Element of M such that
A8: C2 = v2 + W2 by VECTSP_4:def 6;
    v2 in (Omega).M by RLVECT_1:1;
    then consider v21,v22 being Element of M such that
A9: v21 in W1 and
A10: v22 in W2 and
A11: v2 = v21 + v22 by A3,Th1;
    take v = v12 + v21;
    {v} = C1 /\ C2
    proof
      thus
A12:  {v} c= C1 /\ C2
      proof
        let x be object;
        assume x in {v};
        then
A13:    x = v by TARSKI:def 1;
        v21 = v2 - v22 by A11,VECTSP_2:2;
        then v21 in C2 by A8,A10,VECTSP_4:62;
        then C2 = v21 + W2 by VECTSP_4:77;
        then
A14:    x in C2 by A6,A13;
        v12 = v1 - v11 by A7,VECTSP_2:2;
        then v12 in C1 by A4,A5,VECTSP_4:62;
        then C1 = v12 + W1 by VECTSP_4:77;
        then x in C1 by A9,A13;
        hence thesis by A14,XBOOLE_0:def 4;
      end;
      let x be object;
      assume
A15:  x in C1 /\ C2;
      then C1 meets C2;
      then reconsider C = C1 /\ C2 as Coset of W1 /\ W2 by Th45;
A16:  v in {v} by TARSKI:def 1;
      W1 /\ W2 = (0).M by A2;
      then ex u being Element of M st C = {u} by VECTSP_4:72;
      hence thesis by A12,A15,A16,TARSKI:def 1;
    end;
    hence thesis;
  end;
  assume
A17: for C1 being Coset of W1, C2 being Coset of W2 ex v being Element
  of M st C1 /\ C2 = {v};
A18: VW2 is Coset of W2 by VECTSP_4:73;
A19: the carrier of M c= the carrier of W1 + W2
  proof
    let x be object;
    assume x in the carrier of M;
    then reconsider u = x as Element of M;
    consider C1 being Coset of W1 such that
A20: u in C1 by VECTSP_4:68;
    consider v being Element of M such that
A21: C1 /\ VW2 = {v} by A18,A17;
A22: v in {v} by TARSKI:def 1;
    then v in C1 by A21,XBOOLE_0:def 4;
    then consider v1 being Element of M such that
A23: v1 in W1 and
A24: u - v1 = v by A20,VECTSP_4:79;
    v in VW2 by A21,A22,XBOOLE_0:def 4;
    then
A25: v in W2 by STRUCT_0:def 5;
    u = v1 + v by A24,VECTSP_2:2;
    then x in W1 + W2 by A25,A23,Th1;
    hence thesis by STRUCT_0:def 5;
  end;
  VW1 is Coset of W1 by VECTSP_4:73;
  then consider v being Element of M such that
A26: VW1 /\ VW2 = {v} by A18,A17;
  the carrier of W1 + W2 c= the carrier of M by VECTSP_4:def 2;
  then the carrier of M = the carrier of W1 + W2 by A19;
  hence the ModuleStr of M = W1 + W2 by A1,VECTSP_4:31;
  0.M in W2 by VECTSP_4:17;
  then
A27: 0.M in VW2 by STRUCT_0:def 5;
  0.M in W1 by VECTSP_4:17;
  then 0.M in VW1 by STRUCT_0:def 5;
  then
A28: 0.M in {v} by A26,A27,XBOOLE_0:def 4;
  the carrier of (0).M = {0.M} by VECTSP_4:def 3
    .= VW1 /\ VW2 by A26,A28,TARSKI:def 1
    .= the carrier of W1 /\ W2 by Def2;
  hence thesis by VECTSP_4:29;
end;
