ass="codeinput">core = tensor(rand(3,2,1),[3 2 1]); <span class="comment">%&lt;-- The core tensor.</span>
U = {rand(5,3), rand(4,2), rand(3,1)}; <span class="comment">%&lt;-- The matrices.</span>
X = ttensor(core,U) <span class="comment">%&lt;-- Create the ttensor.</span>
</pre><pre class="codeoutput">X is a ttensor of size 5 x 4 x 3
	X.core is a tensor of size 3 x 2 x 1
		X.core(:,:,1) = 
	    0.6808    0.7942
	    0.4611    0.0592
	    0.5678    0.6029
	X.U{1} = 
		    0.0503    0.7680    0.4983
		    0.4