Newton raphson Method implemented