  A robust and efficient field-only nonsingular surface integral method to
solve Maxwell's equations for the components of the electric field on the
surface of a dielectric scatterer is introduced. In this method, both the
vector Helmholtz equation and the divergence-free constraint are satisfied
inside and outside the scatterer. The divergence-free condition is replaced by
an equivalent boundary condition that relates the normal derivatives of the
electric field across the surface of the scatterer. Also, the continuity and
jump conditions on the electric and magnetic fields are expressed in terms of
the electric field across the surface of the scatterer. Together with these
boundary conditions, the scalar Helmholtz equation for the components of the
electric field inside and outside the scatterer is solved by a fully
desingularized surface integral method. Comparing with the most popular surface
integral methods based on the Stratton-Chu formulation or the PMCHWT
formulation, our method is conceptually simpler and numerically straightforward
because there is no need to introduce intermediate quantities such as surface
currents and the use of complicated vector basis functions can be avoided
altogether. Also, our method is not affected by numerical issues such as the
zero frequency catastrophe and does not contain integrals with (strong)
singularities. To illustrate the robustness and versatility of our method, we
show examples in the Rayleigh, Mie, and geometrical optics scattering regimes.
Given the symmetry between the electric field and the magnetic field, our
theoretical framework can also be used to solve for the magnetic field.
