Optimizing waveguide geometry for single-mode