Optimum Fourier representations for stellarator magnetic flux surfaces