Frequency Tripling via Sum-Frequency Generation at the Nanoscale