Added gradient method. Numerical solution for u squared is done