The paper presents an accurate analytical subdomain model for computation of the open-circuit magnetic field in surface-mounted permanent-magnet machines with any pole and slot combinations, including fractional slot machines, accounting for stator slotting effect. It is derived by solving the field governing equations in each simple and regular subdomain, i.e., magnet, air-gap and stator slots, and applying the boundary conditions to the interfaces between these subdomains. The model accurately accounts for the influence of interaction between slots, radial/parallel magnetization, internal/external rotor topologies, relative recoil permeability of magnets, and odd/even periodic boundary conditions. The back-electromotive force, electromagnetic torque, cogging torque, and unbalanced magnetic force are obtained based on the field model. The relationship between this accurate subdomain model and the conventional subdomain model, which is based on the simplified one slot per pole machine model, is also discussed. The investigation shows that the proposed accurate subdomain model has better accuracy than the subdomain model based on one slot/pole machine model. The finite element and experimental results validate the analytical prediction.