Newton Iteration
1
2
3
4
5
6
7
8
9
10
11
12
13
%2008.5.14
clear;
syms y x z;
y=x^2-1;
z=x-y/diff(y);
t=10^6
for i=1:30
i
t=subs(z,x,t)
if t==1
break;
end
end
1
2
3
4
5
6
7
8
9
10
11
12
13
%2008.5.14
clear;
syms y x z;
y=(x-1)^4;
z=x-y/diff(y);
t=10
for i=1:50
i
t=subs(z,x,t)
if t==1
break;
end
end