You stated there are 40 permanent magnets mounted on the rotor, which I assume have alternating orientations, so that the magnetic field goes through 20 cycles in one pass around the rotor. I then counted 30 positions for coils on the stator. Since this is a 3 phase synchronous machine, the magnetic field will then only go through 10 cycles once around the stator. How do you account for this topological discrepancy? Perhaps the coils' orientation is reversed for every other set of three?