Matrix Matrix::operator^(const NumericValue& r) const { Matrix current(h,w); for (int a = 0; a < h; a++ ) { current(a,a) = NumericValue(1); } float f = r.val; while (f > 0 ) { current = current * (*this); f--; } return current; }
NumericValue NumericValue::operator/(NumericValue& other) { return NumericValue(other.m_value / m_value); }