ConstantSizeMatrix
public protocol ConstantSizeMatrix : MatrixBase
A matrix whose dimensions are determined at compile time.
-
The dimensions of all instances of this type. The instance property dimensions must return this value.
Declaration
Swift
static var dimensions: IntSize { get } -
Initializes this instance with the specified elements. If elements does not contain enough values, the remaining elements should be initialized to
Self.zero. If elements contains too many elements, the extra values should be ignored.Declaration
Swift
init(elements: [ElementType])Return Value
a matrix initialized with the values of elements.
-
numberOfElementsDefault implementationThe number of elements in the matrix. Must be equal to
Self.dimensions.row * Self.dimensions.column.Default Implementation
Declaration
Swift
static var numberOfElements: Int { get }
ConstantSizeMatrix Protocol Reference