package
2.16.0
Repository: https://github.com/tawesoft/golib.git
Documentation: pkg.go.dev

# Packages

Package dimensions implements an interface and concrete types for indexing a matrix of values along an arbitrary number of dimensions.

# Functions

Const returns a read-only view of matrix m.
Copy clears dest and copies every value from src into dest at the same offsets.
Crop is a shortcut for NewView(parent, dimensions.Crop(...)) See [dimensions.Crop].
NewBit allocates and returns a [Bit] matrix implementing M.
NewBool allocates and returns a new [Bool] matrix implementing M.
NewDiagonal allocates and returns a [Diagonal] implementing M.
NewGrid allocates and returns a new grid matrix implementing M.
NewHashmap allocates and returns a [Hashmap] implementating M.
NewSharedDiagonal returns a new [Diagonal] matrix implementing M.
NewSharedGrid returns a new [Grid] matrix implementing M.
NewSharedHashmap returns a new [Hashmap] matrix implementing [M].
NewView returns a [View], implementing the matrix interface M, using the provided mapping.
Sample is a shortcut for NewView(parent, dimensions.Sampler(...).Bind(parent)).

# Structs

Bit is an implementation of the matrix interface [M] that stores data using a densely packed sequence of bits that are either 1 or 0.
Bool is an implementation of the matrix interface [M] that stores data using a densely packed sequence of bits that are either true or false.
Diagonal is an implementation of the matrix interface [M] that represents a diagonal matrix (one where entries outside the main diagonal are all zero) as a contiguous slice of only the diagonal values.
Grid is an implementation of the matrix interface [M] that stores data using a contiguous slice of values.
Hashmap is an implementation of the matrix interface [M] that stores data using a hashmap with element indexes as keys.
View is an implementation of the matrix interface [M] that represents a custom view of a parent matrix.

# Interfaces

M is the interface implemented by a matrix of Values.