 reserve R for Ring;
 reserve x, y, y1 for set;
 reserve a, b for Element of R;
 reserve V for LeftMod of R;
 reserve v, w for Vector of V;
 reserve u,v,w for Vector of V;
 reserve F,G,H,I for FinSequence of V;
 reserve j,k,n for Nat;
 reserve f,f9,g for sequence of V;
 reserve R for Ring;
 reserve V, X, Y for LeftMod of R;
 reserve u, u1, u2, v, v1, v2 for Vector of V;
 reserve a for Element of R;
 reserve V1, V2, V3 for Subset of V;
 reserve x for set;
 reserve W, W1, W2 for Submodule of V;
 reserve w, w1, w2 for Vector of W;
 reserve D for non empty set;
 reserve d1 for Element of D;
 reserve A for BinOp of D;
 reserve M for Function of [:the carrier of R,D:],D;

theorem Th40:
  V1 = D & d1 = 0.V & A = (the addF of V) || V1 &
  M = (the lmult of V) | [:the carrier of R,V1:] implies
    ModuleStr (# D,A,d1,M #) is Submodule of V
  proof
    assume that
    A1: V1 = D and
    A2: d1 = 0.V and
    A3: A = (the addF of V) || V1 and
    A4: M = (the lmult of V) | [:the carrier of R,V1:];
    reconsider W = ModuleStr (# D,A,d1,M #) as non empty
      ModuleStr over R;
A5: for a being Element of R
    for x being Vector of W holds a * x = (the lmult of V).(a,x)
    proof
      let a be Element of R;
      let x be Vector of W;
      thus a * x = (the lmult of V).[a,x] by A1,A4,FUNCT_1:49
      .= (the lmult of V).(a,x);
    end;
A6: for x, y being Vector of W holds x + y = (the addF of V).(x,y)
    proof
      let x, y be Vector of W;
      thus x + y = (the addF of V) . [x,y] by A1,A3,FUNCT_1:49
      .= (the addF of V).(x,y);
    end;
A7: W is Abelian add-associative right_zeroed right_complementable
    vector-distributive scalar-distributive scalar-associative scalar-unital
    proof
      set MV = the lmult of V;
      set AV = the addF of V;
      thus W is Abelian
      proof
        let x, y be Vector of W;
        reconsider x1 = x, y1 = y as Vector of V by A1,TARSKI:def 3;
        thus x + y = x1 + y1 by A6
        .= y1 + x1
        .= y + x by A6;
      end;
      thus W is add-associative
      proof
        let x, y, z be Vector of W;
        reconsider x1 = x, y1 = y, z1 = z as Vector of V by A1,TARSKI:def 3;
        thus (x + y) + z = AV.(x + y,z1) by A6
        .= (x1 + y1) + z1 by A6
        .= x1 + (y1 + z1) by RLVECT_1:def 3
        .= AV.(x1,y + z) by A6
        .= x + (y + z) by A6;
      end;
      thus W is right_zeroed
      proof
        let x be Vector of W;
        reconsider y = x as Vector of V by A1,TARSKI:def 3;
        thus x + 0.W = y + 0.V by A2,A6
        .= x by RLVECT_1:4;
      end;
      thus W is right_complementable
      proof
        let x be Vector of W;
        reconsider x1 = x as Vector of V by A1,TARSKI:def 3;
        consider v such that
A8:     x1 + v = 0.V by ALGSTR_0:def 11;
        v = - x1 by A8,RLVECT_1:def 10
        .= (- (1.R)) * x1 by Th2
        .= (the lmult of V).((- (1.R)),x1)
        .= (- (1.R)) * x by A5;
        then reconsider y = v as Vector of W;
        take y;
        thus thesis by A2,A6,A8;
      end;
      thus for a being Element of R for x, y being Vector of W
      holds a * (x + y) = a * x + a * y
      proof
        let a be Element of R;
        let x, y be Vector of W;
        reconsider x1 = x, y1 = y as Vector of V by A1,TARSKI:def 3;
        a * (x + y) = MV.(a,x + y) by A5
        .= a * (x1 + y1) by A6
        .= a * x1 + a * y1 by VECTSP_1:def 14
        .= AV.(MV.(a,x1),a * y) by A5
        .= AV.(a * x, a * y) by A5
        .= a * x + a * y by A6;
        hence thesis;
      end;
      thus for a, b being Element of R
      for x being Vector of W holds (a + b) * x = a * x + b * x
      proof
        let a, b be Element of R;
        let x be Vector of W;
        reconsider y = x as Vector of V by A1,TARSKI:def 3;
        (a + b) * x = (a + b) * y by A5
        .= a * y + b * y by VECTSP_1:def 15
        .= AV.(MV.(a,y),b * x) by A5
        .= AV.(a * x,b * x) by A5
        .= a * x + b * x by A6;
        hence thesis;
      end;
      thus for a, b being Element of R
      for x being Vector of W holds (a * b) * x = a * (b * x)
      proof
        let a, b be Element of R;
        let x be Vector of W;
        reconsider y = x as Vector of V by A1,TARSKI:def 3;
        reconsider a, b as Element of R;
        (a * b) * x = (a * b) * y by A5
        .= a * (b * y) by VECTSP_1:def 16
        .= MV.(a,b * x) by A5
        .= a * (b * x) by A5;
        hence thesis;
      end;
      let x be Vector of W;
      reconsider y = x as Vector of V by A1,TARSKI:def 3;
      thus (1.R) * x = (the lmult of V).(1.R,y) by A5
      .= (1.R) * y
      .= x;
    end;
    0.W = 0.V by A2;
    hence thesis by A1,A3,A4,A7,VECTSP_4:def 2;
  end;
