Sample questions on tensors (incl. solutions)

advertisement
Sample questions on tensors
1. Let a tensor X be given by
X = I 2 ×1 A ×2 B ×3 C
where I 2 is the 2 × 2 × 2 identity tensor (with elements [I 2 ](1,1,1)
elements zero) and A, B, C are the loading matrices given by
1 1
1 1
3
A=
B=
C=
1 1
1 −1
0
= [I 2 ](2,2,2) = 1 and all other
0
2
(a) What is the (tensor) rank r = rank{X }?
(b) Demonstrate a) by explicitly computing r rank-one tensors X 1 . . . X r such that X =
r
X
X i.
i=1
(c) Compute the unfoldings [X ](1) , [X ](2) , [X ](3) in forward (MATLAB) column ordering.
(d) What are the n-ranks of X for n = 1, 2, 3?
(e) Find a basis for the space spanned by the one-mode vectors of X , i.e., the column space of [X ](1) .
(f) Show that for an arbitrary tensor X ∈ CM1 ×M2 ×M3 and matrices A ∈ CN1 ×M1 , B ∈ CP1 ×N1 , the
following identity holds: X ×1 A ×1 B = X ×1 (B · A). Hint: Use a suitable n-mode unfolding.
2. We are given the one-mode unfolding of a 2 × 2 × 2 tensor X in forward (MATLAB) column ordering
3 3 3 3
[X ](1) =
(1)
−1 3 −1 3
(a) Find the two-mode and the three-mode unfoldings [X ](2) , [X ](3) in forward (MATLAB) column
ordering.
(b) What are the n-ranks of X for n = 1, 2, 3?
Now we compute a new tensor Y via Y = X ×1 U , where the matrix U is given by


2 −1
U = −2 1 
2 −1
(2)
(c) Compute the one-mode unfolding [Y](1) of Y in forward (MATLAB) column ordering.
(d) Using the previous result, find the two-mode and the three-mode unfoldings [Y](2) , [Y](3) in forward (MATLAB) column ordering.
(e) What are the new n-ranks of Y for n = 1, 2, 3?
1
Solutions
1. Let a tensor X be given by
X = I 2 ×1 A ×2 B ×3 C
where I 2 is the 2 × 2 × 2 identity tensor (with elements [I 2 ](1,1,1)
elements zero) and A, B, C are the loading matrices given by
1 1
1 1
3
A=
B=
C=
1 1
1 −1
0
= [I 2 ](2,2,2) = 1 and all other
0
2
(a) rank{X } = 2
(b)
(c)
(d)
(e)
(f)
2.
(a)
(b)
(c)
(d)
(e)
1
1
3
1
1
0
◦
◦
X = a 1 ◦ b 1 ◦ c1 + a 2 ◦ b 2 ◦ c2 =
+
◦
◦
|
{z
} |
{z
}
1
1
0
1
−1
2
X1
X2
2 −2
2 −2
0 0
2 −2
2 −2 = 0 0 + = 3 3
0 0
3 3
3 3
0 0
3 3
3 3 2 −2
3 3 2
2
3 3 3
3
[X ](1) =
[X ](2) =
[X ](3) =
3 3 2 −2
3 3 −2 −2
2 2 −2 −2
1-rank(X ) = rank([X ](1) ) = 1
2-rank(X ) = rank([X ](2) ) = 2
3-rank(X ) = rank([X ](3) ) = 2
1
range([X ](1) ) = range(A) = span({a1 }) = span
.
1
Let Y = X ×1 A.
Via the definition of 1-mode products, we have [X ×1 A](1) = A · [X ](1) and [Y ×1 B](1) =
B · [Y](1) .
Now we consider [X ×1 A ×1 B](1) :
[X ×1 A ×1 B](1) = [Y ×1 B](1) = B · [Y](1) = B · [X ×1 A](1) = B · A · [X ](1) .
On the other hand, we have for [X ×1 (B · A)](1) :
[X ×1 (B · A)](1) = (B · A) · [X ](1) . Hence both sides are equal.
3 −1 3 −1
[X ](2) =
3 3 3 3
3 −1 3 3
[X ](3) =
3 −1 3 3
1-rank(X ) = rank([X ](1) ) = 2
2-rank(X ) = rank([X ](2) ) = 2
3-rank(X ) = rank([X ](3) ) = 1


7
3
7
3
[Y](1) = U · [X ](1) = −7 −3 −7 −3.
7
3
7
3
7 −7 7 7 −7 7
7 −7 7 3 −3 3
[Y](2) =
[Y](3) =
3 −3 3 3 −3 3
7 −7 7 3 −3 3
1-rank(Y) = rank([Y](1) ) = 1
2-rank(Y) = rank([Y](2) ) = 1
3-rank(Y) = rank([Y](3) ) = 1
2
Download