Fernando Alonso wins Singapore grand prix after Lewis Hamilton retires