Extension of the M-Quality factor definition to laser diode arrays