Tunnel Diode Oscillator algorithm