static double DevFunc1(double x)
return 4 * Math.Pow(x,3) - 2 * x;
static double DevFunc2(double x)
return 3 * Math.Pow(x,2) - 1;
public static void Main()
Console.WriteLine("C = " + Newton(x0,eps));
public static double Newton(double x0, double eps)
x1 = x0 - DevFunc1(x0)/ DevFunc2(x0);
if(Math.Abs(x1 - x0) > eps)
throw new Exception("Не найден экстремум");