Main Content

MathWorks.MATLAB.NET.Arrays.MWNumericArray Class

Namespace: MathWorks.MATLAB.NET.Arrays

Managed representation of MATLAB numeric array types

Description

MWNumericArray is the managed representation of the MATLAB numeric array types. Like its MATLAB equivalent, it is the default array type used by most of the MATLAB math functions.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Properties

expand all

Public Properties

This property is read-only.

Syntax

public MWArrayType ArrayType { get; }
The derived type of the array, specified as an MWArrayType object.

This property is read-only.

Syntax

public virtual int[] Dimensions { get; }

This property is read-only.

Syntax

public static MWNumericArray Empty { get; }
See size.

This property is read-only.

Syntax

public static double FloatingPointAccuracy { get; }
See size.

This property is read-only.

Syntax

public bool IsCellArray { get; }
See iscell.

This property is read-only.

Syntax

public bool IsCharArray { get; }
See ischar.

This property is read-only.

Syntax

public virtual bool IsDisposed { get; }

This property is read-only.

Syntax

public virtual bool IsEmpty { get; }
See isempty.

This property is read-only.

Syntax

public bool IsLogicalArray { get; }
See islogical.

This property is read-only.

Syntax

public bool IsNumericArray { get; }
See isnumeric.

This property is read-only.

Syntax

public bool IsStringArray { get; }
See isstring.

This property is read-only.

Syntax

public bool IsStructArray { get; }
See isstruct.

Syntax

public MWArray this[
	params int[] indices
] { get; set; }
An index can be any number of integers corresponding to the array's dimensions. As with MATLAB, a single index will return the nth element in the array. NOTE: The generic array indexer supports numeric, logical, char, and cell array types. For complex numeric arrays, both the real and the imaginary components are returned.

Array indexing in this API, as in MATLAB®, is one-based rather than zero-based.

This property is read-only.

Syntax

public static long NativeGCBlockSize { get; }

Syntax

public static bool NativeGCEnabled { get; set; }
If the native array GC is enabled, a CLR garbage collection will take place transparently as required to remove instances of the MWArray class or one of its derived types that are no longer being referenced. This includes unmanaged memory allocated through explicit creation of MWArray types, as well as implicit instantiation of an MWArray via an implicit cast.

This property is read-only.

Syntax

public int NumberofDimensions { get; }
See ndims.

This property is read-only.

Syntax

public int NumberOfElements { get; }
Equivalent to prod(size(A)) for non-empty arrays. See numel.

Methods

expand all

Inheritance Hierarchy

System.Object

  • Mathworks.MATLAB.NET.Arrays.MWArray

    • Mathworks.MATLAB.NET.Arrays.MWIndexArray

      • Mathworks.MATLAB.NET.Arrays.MWLogicalArray

      • Mathworks.MATLAB.NET.Arrays.MWNumericArray

Version History

Introduced in R2006a