But I don't understand your suggestion about "divide the left hand side by mass since on the right you have acceleration and on the left forces". Isn't mass in the M vector enough? And isn't force the same than (or equivalent to) acceleration?
Oops, I have confused left side with a right side (it sometimes happens to me). What I meant is that on the left side of the equation you have an acceleration and on the right side sum of forces. Now, force and acceleration are related to each other - force equals acceleration multiplied by mass, but they are different quantities with different units. So to have an exact equation You need to insert mass into the equation, either by multiplying acceleration (lhs) or dividing forces (rhs).

Btw. If you have an equation and and units of the lhs and rhs are not the same, then the equation is wrong.