Difference between revisions of "Ttclass/size.m"

From Spinach Documentation Wiki
Jump to: navigation, search
(Add NOTOC to Spinach function page header)
m (Add missing Version/authors metadata and remove raw author emails)
Line 11: Line 11:
 
==See also==
 
==See also==
 
[[ttclass.m]], [[ttclass/sizes.m]], [[ttclass/nnz.m]], [[Tensor_train_module#Tensor_train_functions|Tensor train functions]]
 
[[ttclass.m]], [[ttclass/sizes.m]], [[ttclass/nnz.m]], [[Tensor_train_module#Tensor_train_functions|Tensor train functions]]
 +
 +
''Version 2.1, authors: [[Dmitry Savostyanov]], [[Ilya Kuprov]]''

Revision as of 17:26, 5 June 2026

Returns the size of the matrix represented by a tensor train. The output mimics Matlab's size function. Syntax:

    varargout=size(tt,dim)

If dim is omitted, the function returns the two-element row vector [m n]. If dim is 1 or 2, it returns the corresponding dimension.

For large tensor train matrices, m and n may be too large to fit into the maximum integer permitted by Matlab.

See also

ttclass.m, ttclass/sizes.m, ttclass/nnz.m, Tensor train functions

Version 2.1, authors: Dmitry Savostyanov, Ilya Kuprov