change mat_t definition