Tensor ; How can i recognize the type of tensor???

136 Views Asked by At

I want to use Matlab for my project. matlab has tensor toolbox and in it there are two types of tensor : Dens tensor and sparse tensor. my project is about " fiber orientation". how can i know what type is my tensor and use which one from tensor toolbox in Matlab. thanks for your attention

1

There are 1 best solutions below

0
On BEST ANSWER

In general a sparse tensor is a tensor with many zeros whereas a dense tensor has no (or hardly any zeros.

So you could check for the number of non-zeros (nnz(A)) and compare that to the size of the tensor