LIBRARY LINK SYMBOL

MTensor_getRank


gets the rank of an MTensor.

DetailsDetails

  • Used in C/C++ code in a library function called from Mathematica.
  • The rank shows the number of indices that are needed to reference each element.

ExamplesExamplesopen allclose all

Basic Examples (1)Basic Examples (1)

This gets the rank of an MTensor:

MTensor T0;
mint rank;
...
rank = libData->MTensor_getRank( T0);
New to Mathematica? Find your learning path »
Have a question? Ask support »