Oddiy iteratsiya usulining yaqinlashish sharti Oddiy iteratsiya usulini amalga oshirish algoritmi Oddiy iteratsiya usuliga doir masalalar yechish


Download 306.12 Kb.
bet4/4
Sana17.06.2023
Hajmi306.12 Kb.
#1531169
1   2   3   4
Bog'liq
5-ma\'ruza

Iteratsiya usuli blok sxemasi



Tenglamarni oddiy iteratsiya usulida yechishning dasturi
#include
#include
using namespace std;
double fi(double x)
{
return cos(x)*cos(x)/3;
}
int main()
{
double a,b,c,e;
cin>>a>>b;
cout<<" e ning qiymatini kiriting:";
cin>>e;
double x1,x2;
x1=a;
x2=b;
while (fabs(a-x2)>=e)
{
x2=fi(x1);
a=x1;
x1=x2;
}
cout<<"x ning qiymati "<Download 306.12 Kb.
Do'stlaringiz bilan baham:
1   2   3   4




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling