({{, (RefLink[TensorProduct, paclet:ref/TensorProduct])[(Subscript[tensor, 1]),(Subscript[tensor, 2]),…] 
represents the tensor product of the (Subscript[tensor, i]).}})

OpenersNotesSection(Spacer1)Details

(RefLink[TensorProduct, paclet:ref/TensorProduct])[a,b] can be input as a⊗b. The character ⊗ is entered as (Key0[esc]) t* (Key0[esc]) or (RefLink[\[TensorProduct], paclet:ref/character/TensorProduct]).

(RefLink[TensorProduct, paclet:ref/TensorProduct])[] returns 1. (RefLink[TensorProduct, paclet:ref/TensorProduct])[x] returns x.

OpenersPrimaryExamplesSection(Spacer1)Examples  (17)

OpenersExampleSection0(Spacer1)Basic Examples  (2)

Tensor product of arrays:

TensorProduct[{2,3},{{a,b},{c,d}},{x,y}]

Tensor product of symbolic expressions:

TensorProduct[a+2b,c]

Expand linearly:

%//TensorExpand

Compute properties of tensorial expressions:

Assuming[(a|b|c)∈Vectors[dim],TensorDimensions[%]]

OpenersExampleSection1(Spacer1)Scope  (4)

Tensor product of arrays of any depth and dimensions:

array1=RandomInteger[10,{2,5}]

array2=RandomInteger[10,{3,4}]

array1⊗array2

%//Dimensions

Product of symmetrized arrays, with the result also in symmetrized form:

A=SymmetrizedArray[{{a,b},{b,c}}]

TensorSymmetry[A]

A⊗A

The fact that both arrays are the same adds more symmetry:

TensorSymmetry[%]

There are only six nonzero independent components:

SymmetrizedArrayRules[%%]

Tensor product of symbolic expressions:

$Assumptions={T∈Arrays[{4,4,3},Reals,Antisymmetric[{1,2}]]}

T⊗T⊗T⊗T

TensorRank[%]

Tensor product of objects of different types. Contiguous arrays are multiplied:

A⊗{a,b}⊗{x,y}⊗A⊗A

OpenersExampleSection3(Spacer1)Properties & Relations  (11)

The tensor product is not commutative:

TensorProduct[{a,b},{x,y}]

TensorProduct[{x,y},{a,b}]

The difference is always some transposition:

%%===Transpose[%]

The tensor product of arrays is equivalent to the use of (RefLink[Outer, paclet:ref/Outer]):

array1=RandomInteger[10,{2,5}]

array2=RandomInteger[10,{3,4}]

array1⊗array2⊗array1===Outer[Times,array1,array2,array1]

The (RefLink[KroneckerProduct, paclet:ref/KroneckerProduct]) of vectors is equivalent to their (RefLink[TensorProduct, paclet:ref/TensorProduct]):

vec1={x,y,z};
vec2={a,b};
KroneckerProduct[vec1,vec2]===TensorProduct[vec1,vec2]

The (RefLink[KroneckerProduct, paclet:ref/KroneckerProduct]) of matrices is equivalent to the flattening of their (RefLink[TensorProduct, paclet:ref/TensorProduct]) to another matrix:

mat1=Array[a,{2,3}];
mat2=Array[b,{4,5}];
KroneckerProduct[mat1,mat2]===ArrayFlatten[TensorProduct[mat1,mat2]]

The (RefLink[KroneckerProduct, paclet:ref/KroneckerProduct]) of any two arrays is also equivalent to a flattening of their (RefLink[TensorProduct, paclet:ref/TensorProduct]):

arr1=Array[a,{2,3,4,5}];
arr2=Array[b,{4,6}];
KroneckerProduct[arr1,arr2]===ArrayFlatten[TensorProduct[arr1,arr2],3]

The rank of a tensor product is the sum of ranks of the factors:

TensorProduct[a,b,c]

TensorRank[%]

The tensor product of a tensor with itself gives a result with added symmetry:

$Assumptions=A∈Arrays[{3,3}];

TensorProduct[A,A]//TensorSymmetry

(RefLink[TensorProduct, paclet:ref/TensorProduct])[x] returns x irrespectively of what x is:

TensorProduct[I]

(RefLink[TensorProduct, paclet:ref/TensorProduct])[] is 1:

TensorProduct[]

Obvious scalars are extracted from a tensor product:

TensorProduct[3,v,-2,w]

Symbolic scalars need to be specified with assumptions:

Assuming[x∈Reals,v⊗x⊗w]

(RefLink[TensorProduct, paclet:ref/TensorProduct]) has (RefLink[Flat, paclet:ref/Flat]) attribute:

TensorProduct[a,TensorProduct[b,c]]//FullForm

TensorProduct[a,b,c,d]/.TensorProduct[b,c]->e

(RefLink[TensorProduct, paclet:ref/TensorProduct]), in combination with (RefLink[TensorContract, paclet:ref/TensorContract]), can be used to implement (RefLink[Dot, paclet:ref/Dot]):

v = Array[x,{3}];
a= Array[y, {3,3,3}];
m = Array[z,{3,3}];

v.a.m==TensorContract[v⊗a⊗m,{{1,2},{4,5}}]//Simplify

Antisymmetrization of (RefLink[TensorProduct, paclet:ref/TensorProduct]) is proportional to (RefLink[TensorWedge, paclet:ref/TensorWedge]):

v=RandomInteger[10,3]

w=RandomInteger[10,3]

Symmetrize[v⊗w,Antisymmetric[{1,2}]]

2%===v\[TensorWedge]w

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[Outer, paclet:ref/Outer])  ▪  (RefLink[TensorWedge, paclet:ref/TensorWedge])  ▪  (RefLink[KroneckerProduct, paclet:ref/KroneckerProduct])  ▪  (RefLink[Inner, paclet:ref/Inner])  ▪  (RefLink[Dot, paclet:ref/Dot])}})}})

({{DocumentationFooterIconsRelatedTutorial.png, ({{Tutorials}, {▪(RefLinkPlain[Symbolic Tensors, paclet:tutorial/SymbolicTensors])}, {▪(RefLinkPlain[Tensor Symmetries, paclet:tutorial/TensorSymmetries])}, {▪(RefLinkPlain[Symmetrized Arrays, paclet:tutorial/SymmetrizedArrays])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Symbolic Tensors, paclet:guide/SymbolicTensors])}})}})