changed add/sub to compile only when matrices have the same size