Restored iteration order over momentsArray[c][m] so m is inner.