Matrix & Vector
Geometry
For small, fixed size vectors & matrices,
as typically used in geometry (i.e. 2D, 3D, 4D).
Vector<Int size, T = Float>Vector2<T = Float>Vector3<T = Float>Vector4<T = Float>
Matrix<Int rows, Int columns, T = Float>Matrix22<T = Float>Matrix33<T = Float>Matrix44<T = Float>
Linear Algebra
For large, dynamically sized vectors & matrices,
as typically used in linear algebra (i.e. BLAS – Basic Linear Algebra Subprograms).
Vector<T = Float>Matrix<T = Float>- Stored column-major, like:
0 3 6 1 4 7 2 5 8
- Stored column-major, like:
MDArray<Int dimensions, T = Float>- also see
MDSpan
- also see
VectorView,MatrixView
Datatype & Precision
The default datatype is Float (64-bit precision), which is better suited for scientific calculations.
Feel free to use your own type aliases:
using Vec3 = cilia::Vector3<Float32>using RGB = cilia::Vector3<UInt8>