How can i make program for method of iteration ...please help me out .. equation is X^3-2x=1
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
How can i make program for method of iteration ...please help me out .. equation is X^3-2x=1 I am learning Numerical method.
1 Kommentar
Akzeptierte Antwort
Yona
am 5 Okt. 2016
you need to find a function of X from your equation for your example X^3-2X=1
you get X(X^2-2)=1 and then X=1/(X^2-2)
so build a function that calculate f(x)=1/(X^2-2)
in loop you can do
x=0.5;
for i=1:n
x=1/(x^2-2)
end
It better to put better rule then do N iteration (for example, the change in x is lower then eps)
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu MATLAB Coder finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!