Effects of the surface preparation and buffer layer on the morphology, electronic and optical properties of the GaN nanowires on Si