gradient descent for finite time snr