Ma · Mathematics

Direct Sum vs. Direct Product vs. Tensor Product

Published By the 9to5Science editorial team

At a glance

  1. 1. Check the index set

    For finitely many spaces, direct sum and direct product agree; for infinitely many, their allowed tuples differ.

  2. 2. Compare tuple support

    A direct sum allows only finitely many nonzero coordinates, while a direct product allows any coordinates.

  3. 3. Read the tensor operation

    A tensor product combines two spaces through bilinear combinations; it is not a space of coordinate tuples.

  4. 4. Use dimensions as a check

    For finite-dimensional vector spaces, direct sums add dimensions and tensor products multiply them.

Direct sums, direct products, and tensor products all combine mathematical structures, but they do different jobs. The key distinction is that a direct sum or product collects vectors into tuples, whereas a tensor product combines vectors from two spaces according to bilinearity.

The difference between a direct sum and a direct product matters most for an infinite family. The difference between either of those and a tensor product is already visible in finite dimensions.

Direct product: all coordinate choices are allowed

Let (Vi)i∈I(V_i)_{i\in I} be a family of vector spaces over the same field. Their direct product is

∏i∈IVi={(vi)i∈I:vi∈Vi for every i}.\prod_{i\in I} V_i = \{(v_i)_{i\in I} : v_i\in V_i\text{ for every }i\}.

There is no restriction on how many coordinates are nonzero. Addition and scalar multiplication are performed coordinate by coordinate.

For example, if every Vi=RV_i=\mathbb{R} and I=NI=\mathbb{N}, then the sequence (1,1/2,1/3,…)(1,1/2,1/3,\ldots) belongs to the product. So does any other real sequence, including an unbounded one.

Direct sum: only finitely many nonzero coordinates

The (algebraic) direct sum is the subset of the product consisting of tuples with finite support:

⨁i∈IVi={(vi)∈∏i∈IVi:vi=0 for all but finitely many i}.\bigoplus_{i\in I} V_i =\{(v_i)\in\prod_{i\in I}V_i : v_i=0\text{ for all but finitely many }i\}.

“Finite support” means that only finitely many entries are nonzero. Thus (1,1/2,1/3,…)(1,1/2,1/3,\ldots) is in ∏i∈NR\prod_{i\in\mathbb{N}}\mathbb{R} but not in ⨁i∈NR\bigoplus_{i\in\mathbb{N}}\mathbb{R}. The tuple (1,0,0,…)(1,0,0,\ldots) belongs to both.

For a finite index set, every tuple automatically has finite support. Therefore the direct sum and direct product are canonically isomorphic:

V1⊕⋯⊕Vn≅V1×⋯×Vn.V_1\oplus\cdots\oplus V_n \cong V_1\times\cdots\times V_n.

For example, R2⊕R3\mathbb{R}^2\oplus\mathbb{R}^3 and R2×R3\mathbb{R}^2\times\mathbb{R}^3 both consist of pairs (x,y)(x,y) with x∈R2x\in\mathbb{R}^2 and y∈R3y\in\mathbb{R}^3. In either case the resulting space has dimension 2+3=52+3=5.

The direct sum also appears as an internal direct sum: a space is the direct sum of subspaces when each vector can be written uniquely as a sum of vectors from those subspaces. This describes how the subspaces fit together inside a larger space.

Tensor product: bilinear combinations

For vector spaces VV and WW over a field F\mathbb{F}, the tensor product V⊗FWV\otimes_{\mathbb{F}}W is a vector space built to represent bilinear operations on pairs (v,w)(v,w). The notation v⊗wv\otimes w denotes a pure tensor, and the construction enforces relations such as

(v1+v2)⊗w=v1⊗w+v2⊗w,v⊗(w1+w2)=v⊗w1+v⊗w2.(v_1+v_2)\otimes w=v_1\otimes w+v_2\otimes w, \qquad v\otimes(w_1+w_2)=v\otimes w_1+v\otimes w_2.

A tensor product is not simply the set of pairs V×WV\times W. Its elements are finite sums of pure tensors, such as v1⊗w1+v2⊗w2v_1\otimes w_1+v_2\otimes w_2. Different sums can represent the same tensor because of the bilinearity relations. The field (or, more generally, the base ring) matters, so it is often written as a subscript.

For finite-dimensional vector spaces, dimensions multiply:

dim⁡(V⊗FW)=dim⁡(V) dim⁡(W).\dim(V\otimes_{\mathbb{F}}W)=\dim(V)\,\dim(W).

So if V=R2V=\mathbb{R}^2 and W=R3W=\mathbb{R}^3, their tensor product has dimension 2⋅3=62\cdot3=6, unlike their direct sum, which has dimension 2+3=52+3=5.

Worked example: a tensor as a matrix

Let e1,e2e_1,e_2 be the standard basis of R2\mathbb{R}^2, and let f1,f2,f3f_1,f_2,f_3 be the standard basis of R3\mathbb{R}^3. The six tensors ei⊗fje_i\otimes f_j form a basis of R2⊗R3\mathbb{R}^2\otimes\mathbb{R}^3.

For example, take x=(1,2)x=(1,2) and y=(3,4,5)y=(3,4,5). Expanding by bilinearity gives

x⊗y=(e1+2e2)⊗(3f1+4f2+5f3)=3e1⊗f1+4e1⊗f2+5e1⊗f3+6e2⊗f1+8e2⊗f2+10e2⊗f3.\begin{aligned} x\otimes y &=(e_1+2e_2)\otimes(3f_1+4f_2+5f_3)\\ &=3e_1\otimes f_1+4e_1\otimes f_2+5e_1\otimes f_3\\ &\quad+6e_2\otimes f_1+8e_2\otimes f_2+10e_2\otimes f_3. \end{aligned}

Using the ordered basis (e1⊗f1,e1⊗f2,e1⊗f3,e2⊗f1,e2⊗f2,e2⊗f3)(e_1\otimes f_1,e_1\otimes f_2,e_1\otimes f_3,e_2\otimes f_1,e_2\otimes f_2,e_2\otimes f_3), its coordinates are (3,4,5,6,8,10)(3,4,5,6,8,10). Equivalently, tensors in this example can be represented by 2×32\times3 matrices, with x⊗yx\otimes y corresponding to

xyT=(3456810).xy^{\mathsf T}=\begin{pmatrix}3&4&5\\6&8&10\end{pmatrix}.

Not every tensor must be a single pure tensor. For instance, e1⊗f1+e2⊗f2e_1\otimes f_1+e_2\otimes f_2 corresponds to a matrix of rank 22, so it cannot be written as x⊗yx\otimes y, which would give a rank-at-most-11 matrix.

Quick comparison

ConstructionWhat it containsFinite-dimensional size
V⊕WV\oplus WPairs (v,w)(v,w)Dimensions add
V×WV\times WThe same pairs when there are finitely many factorsDimensions add
V⊗WV\otimes WBilinear combinations of vectors from VV and WWDimensions multiply

For an infinite family, the direct sum is a subspace of the direct product: every finite-support tuple is a valid product tuple, but not every product tuple has finite support. Tensor products are not another version of either tuple construction.

Common mistakes

  • Treating infinite direct sums and products as interchangeable. They agree for finite index sets, but generally differ for infinite ones.
  • Thinking a tensor product consists only of pairs v⊗wv\otimes w. Pure tensors are building blocks; general tensors can be sums of them.
  • Adding dimensions for a tensor product. For finite-dimensional vector spaces over a field, use the product of the dimensions. A direct sum uses their sum.
  • Ignoring the setting. In functional analysis, “direct sum” may refer to a topological or Hilbert-space construction with extra conditions. The finite-support definition here is the algebraic direct sum.

References

  1. Serge Lang, Algebra
  2. David S. Dummit and Richard M. Foote, Abstract Algebra

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.