clone mat instead of copying