"NumericArray" (Compiled Type)
"NumericArray"::[type,rank]
represents a numeric array composite type with elements of specified type and rank.
Details
- "NumericArray" can be used in Typed and related constructs to specify a type.
Constructors
- NumericArray[{…},type] creates a numeric array with the specified element type.
- CreateTypeInstance["NumericArray"::[type,rank],array] constructs a copy of array.
- CreateTypeInstance["NumericArray"::[type,1],carr,len] constructs a numeric array from a "CArray" carr with length len. carr can optionally be wrapped in "Managed".
Properties
- Information[array,"ElementType"] for array of type "NumericArray"::[type,rank] gives type .
Conversions
- "NumericArray" objects can be converted to and from NumericArray expressions.
- "NumericArray" objects can be converted to and from "ListVector" objects.
Expressions
"ListVector"
Examples
open allclose allBasic Examples (2)
"NumericArray" can be used as an input and output from a CompiledCodeFunction.
Compile a function that returns a "NumericArray":
Use Normal to convert the "NumericArray" to a list: