Convergence is very fast!
0 5 101.9
1.95
2
1.9346xi
i
0 2 41
1.5
2
2yj
j
2 1.414213562373095048801688724209698078570=
2 1.4142135623731=
x
0
0
1
2
3
4
5
6
7
8
9
10
11
2
1.90929742682568
1.94325347008953
1.9314359910797
1.93567129497719
1.93416838388212
1.93470361617592
1.93451324569203
1.93458098701091
1.93455688586229
1.93456546111101
1.93456241007837
=y
1.5
1.41666666666667
1.41421568627451
1.41421356237469
1.41421356237309
1.41421356237309
=
yj 1+ 12 yj Xy
j
+
:=
xi 1+ sin xi( ) 1+:=j 0 4..:=y0 1.5:=X 2:=
Compute square root of X=2 i 0 10..:=x0 2:=
Solve equation x=sin(x)+1
0
2
1.9347
sin x( ) 1+
x
1.9347
x
2 0 2
2
2
2?
2
1
2
x 2
x
+
x
2? 2
x
Using iteration method solve equation x=f(x)
迭 代 法 求 方 程 的 根20 实 验
iteration f a,n,( )
xi a←
yi f xi( )←
a yi←
i 0 n 1?..∈for
augment x y,( )
:=
f x( ) 2.89 x? 1 x?( )?:=
iteration f 0.5,25,( )
0 1
0
1
2
3
4
5
6
7
8
0.5 0.723
0.723 0.579
0.579 0.704
0.704 0.602
0.602 0.692
0.692 0.615
0.615 0.684
0.684 0.625
0.625 0.678
= Y iteration f,1,18,( ):=
0 0.2 0.4 0.6 0.8 1
0.2
0.4
0.6
0.8
1
.2
y 0.8:=
root f y( ) y? y,( ) 0.654=
f x( ),5 cos x( ) sin x2( )+:=
iteration f 0,10,( )
0 1
0
1
2
3
4
5
6
7
8
0 0.5
0.5 0.686
0.686 0.84
0.84 0.983
0.983 1.1
1.1 1.162
1.162 1.175
1.175 1.175
1.175 1.175
=
Y iteration f 0,20,( ):=
0 0.5 1 1.5
0.5
1
1.5
Y 1
f t( )
t
Y 0 t,t,
x 1:=
root f x( ) x? x,( ) 1.1745=
0 5 101.9
1.95
2
1.9346xi
i
0 2 41
1.5
2
2yj
j
2 1.414213562373095048801688724209698078570=
2 1.4142135623731=
x
0
0
1
2
3
4
5
6
7
8
9
10
11
2
1.90929742682568
1.94325347008953
1.9314359910797
1.93567129497719
1.93416838388212
1.93470361617592
1.93451324569203
1.93458098701091
1.93455688586229
1.93456546111101
1.93456241007837
=y
1.5
1.41666666666667
1.41421568627451
1.41421356237469
1.41421356237309
1.41421356237309
=
yj 1+ 12 yj Xy
j
+
:=
xi 1+ sin xi( ) 1+:=j 0 4..:=y0 1.5:=X 2:=
Compute square root of X=2 i 0 10..:=x0 2:=
Solve equation x=sin(x)+1
0
2
1.9347
sin x( ) 1+
x
1.9347
x
2 0 2
2
2
2?
2
1
2
x 2
x
+
x
2? 2
x
Using iteration method solve equation x=f(x)
迭 代 法 求 方 程 的 根20 实 验
iteration f a,n,( )
xi a←
yi f xi( )←
a yi←
i 0 n 1?..∈for
augment x y,( )
:=
f x( ) 2.89 x? 1 x?( )?:=
iteration f 0.5,25,( )
0 1
0
1
2
3
4
5
6
7
8
0.5 0.723
0.723 0.579
0.579 0.704
0.704 0.602
0.602 0.692
0.692 0.615
0.615 0.684
0.684 0.625
0.625 0.678
= Y iteration f,1,18,( ):=
0 0.2 0.4 0.6 0.8 1
0.2
0.4
0.6
0.8
1
.2
y 0.8:=
root f y( ) y? y,( ) 0.654=
f x( ),5 cos x( ) sin x2( )+:=
iteration f 0,10,( )
0 1
0
1
2
3
4
5
6
7
8
0 0.5
0.5 0.686
0.686 0.84
0.84 0.983
0.983 1.1
1.1 1.162
1.162 1.175
1.175 1.175
1.175 1.175
=
Y iteration f 0,20,( ):=
0 0.5 1 1.5
0.5
1
1.5
Y 1
f t( )
t
Y 0 t,t,
x 1:=
root f x( ) x? x,( ) 1.1745=