Maximizing signal-to-noise and contrast-to-noise ratios in FLASH imaging