Perform matrix operations: addition, subtraction, multiplication, scalar multiply, transpose, determinant, and inverse. Supports matrices up to 6×6.