How to find the base of union of 2 subspaces

Suppose we have 2 subspaces V,W. What is the base and the dimention of: V U W ?

Its clear to me that V U W is not always a subspace!

I was thinking about taking the base of U and the base of W and try to Gaussian elimination but that doesnt goes well becouse for example:

$V={(a,0,0)|a \text{ from } R}$. The base of V: $(1,0,0)$

$W={(0,b,0)|b \text{ from } R}$. The base of V: $(0,1,0)$

While doing Gaussian elimination to the matrix : $(1,0,0),(0,1,0)$ , we get that the base from the union of V with W is : ${(1,0,0),(0,1,0)}$ and this is not true becouse we create from this base the vector $(1,1,0)$ that doesnt exist in the uniton of V with W.

Thanks alot!

Stav

• we cant accept the answer in the first 7 min so after that I forget. You can see in stackoverflow I do accept all answers and thank each person who helped. Thanks for the reminder. Sep 3, 2016 at 15:40

I'm assuming that by "base", you mean "basis". What do you mean by a "basis of $V \cup W$"? As you noted, $V \cup W$ is not always a vector space; the definition of "basis" only applies to vector spaces. Usually people would talk about the basis of the span of $V \cup W$, in which case your method works fine.
Note that if $V \cup W$ did have a basis in the traditional sense (i.e., there existed linearly independent $v_1, \dots, v_n$ whose span was equal to $V \cup W$), then $V \cup W$ would certainly be a vector space, though this only happens when $V \subseteq W$ or $W \subseteq V$.