Курсовая работа: по численным методам
cout<<"-------------------------------------------------"<<endl
<<"| Xn | f(Xn) | |f(Xn)|/m |"<<endl
<<"-------------------------------------------------"<<endl;
if (abs(Calc_Fun(minim))*abs(Calc_Second(minim))>0) x=minim;
else x=maxim;
if (Calc_First(minim)>Calc_First(maxim)) m=abs(Calc_First(maxim));
else m=abs(Calc_First(minim));
cout<<"|";
cout.width(15);cout.precision(10);
cout<<x;
cout<<"|";
cout.width(15);cout.precision(10);
cout<<Calc_Fun(x);
cout<<"|";
cout.width(15);cout.precision(10);
cout<<(fabs(Calc_Fun(x))/m);
cout<<"|\n";
while((fabs(Calc_Fun(x))/m)>prec)
{
x=(x-(Calc_Fun(x)/Calc_First(x)));
cout<<"|";
cout.width(15);cout.precision(10);
cout<<x;
cout<<"|";
cout.width(15);cout.precision(10);
cout<<Calc_Fun(x);
cout<<"|";
cout.width(15);cout.precision(10);
cout<<fabs(Calc_Fun(x))/m;