ILMath Functions for Array Initialization
While most functions of the
Initialization with single value
The following table lists common creation functions which give all elements the same value. Code examples (as always inside the Core documentation) assume, that the code is defined in the context of a class, derived from ILNumerics.ILMath
Create matrix, 5x4, double, 1.0 in ILNumerics:
Create row vector, 1x10, double, pi in ILNumerics:
Create column vector, 10x1, int32, -1 in ILNumerics:
Create array, 5x4x3, float, 0f in ILNumerics:
Create empty array, 0x1, double, {} in ILNumerics:
Initialization with multiple values
Create column vector, 4x1, values: 2.0, 4.0, 6.0, 8.0 in ILNumerics:
Create matrix, 2x3, values: 1.0 3.0 5.0 2.0 4.0 6.0 in ILNumerics:
Create array, 2x3x4, random numbers, uniform distr. in ILNumerics:
Create array, 2x3x4, random numbers, norm. distr. in ILNumerics:
Create identity matrix, 4x4, double in ILNumerics:
Create vector, 1x100, double, linearly spaced 0.0 -> 2pi in ILNumerics:
Create vector, 1x20, double, log. spaced 0.0 -> 1000.0 in ILNumerics:
Create array, 100x200, double, counting up, 1.0 -> 20000.0 in ILNumerics:
For more details on every function of the