BaseMat

abstract class BaseMat<M : Mat<M, V>, V : Vec>(dimension: Int) : Mat<M, V>

Base implementation of a square matrix with a given dimension.

Constructors

BaseMat
Link copied to clipboard
common
fun BaseMat(dimension: Int)

Functions

adj
Link copied to clipboard
common
abstract fun adj(): M
Returns an adjugate of this matrix.
det
Link copied to clipboard
common
abstract fun det(): Float
Returns a determinant of this matrix.
get
Link copied to clipboard
common
open operator override fun get(row: Int, col: Int): Float
Returns element of this matrix at a given row and a given column.
inverse
Link copied to clipboard
common
open override fun inverse(): M
Returns an inverse of this matrix.
times
Link copied to clipboard
common
open operator override fun times(other: M): M
Multiplies this matrix by the other matrix of the same size.
open operator override fun times(vector: V): V
Multiplies this matrix by a given vector.
open operator override fun times(number: Float): M
Multiplies this matrix by a given number.
toFloatArray
Link copied to clipboard
common
open override fun toFloatArray(): FloatArray
Returns an array of elements of this matrix.
transpose
Link copied to clipboard
common
open override fun transpose(): M
Returns a transpose of this matrix.

Inheritors

Mat2
Link copied to clipboard
Mat3
Link copied to clipboard
Mat4
Link copied to clipboard