Inverse Design and Optimization Methods for Thermophotovoltaic Emitters made of Tungsten Gratings