例1用二分法求x2+4x2-10=0 在(1,2)内的根,要求绝对误差不超过1×10-2 解 f(1)=5<0有根区间 中点xn f(2)=14>0-(1,2)+ 15 f(15)>01,1.5) 2 1.25 f(125)<0(1.25,15) 3 1.375 f(1.375)>0(1.25,1375) x4≈1313 f(1313)<0(1.313,1.375) x=1344 f(1344)<0(134,1.375)x6≈1.360 f(1360)<0(1.360,1375)x,≈1,368 f(1368)>0(1.360,1.368) 8=1364
例1 用二分法求 在(1,2)内的根,要求绝对误差不超过 解: f(1)=-5<0 有根区间 中点 f(2)=14>0 -(1,2)+ f(1.25)<0 (1.25,1.5) f(1.375)>0 (1.25,1.375) f(1.313)<0 (1.313,1.375) f(1.344)<0 (1.344,1.375) f(1.360)<0 (1.360,1.375) f(1.368)>0 (1.360,1.368) 4 10 0 3 2 x + x − = 2 10 2 1 − f(1.5)>0 (1,1.5) xn x1 = 1.5 1.364 1.368 1.360 1.344 1.313 1.375 1.25 8 7 6 5 4 3 2 = = = = x x x x x x x
例2,求方程x)=x3-ex=的一个实根。 因为f(0)<0,f1)>0。故fx)在(0,1)内有根 用二分法解之,(ab)=(0,1)3计算结果如表: f(x)符号 0.5000 k0123456789 0.5000 0.7500 0.7500 0.8750 0.8750 0.8125 0.8125 0.7812 0.7812 0.7656 十++一 0.7656 0.7734 0.7734 0.7695 0.7695 0.7714 0.7714 0.7724 100.7724 0.7729 取x10=0.7729,误差为x*-X10=1/21
12 例2,求方程f(x)= x 3 –e -x =0的一个实根。 因为 f(0)<0,f(1)>0。 故f(x)在(0,1)内有根 用二分法解之,(a,b)=(0,1)’计算结果如表: k a bk xk f(xk )符号 0 0 1 0.5000 - 1 0.5000 - 0.7500 - 2 0.7500 - 0.8750 + 3 - 0.8750 0.8125 + 4 - 0.8125 0.7812 + 5 - 0.7812 0.7656 - 6 0.7656 - 0.7734 + 7 - 0.7734 0.7695 - 8 0.7695 - 0.7714 - 9 0.7714 - 0.7724 - 10 0.7724 - 0.7729 + 取x10 =0.7729,误差为| x* -x10|<=1/2 11
Remark1:求奇数个根 Find solutions to the equation 0=3-6x+10 x-4 on the intervals o, 4], use the bisection method to compute a solution with an accuracy of 107. Determine the number of iterations to use
Remark1:求奇数个根 Find solutions to the equation on the intervals [0, 4],Use the bisection method to compute a solution with an accuracy of 10-7 . Determine the number of iterations to use
+1一4 卫ot[I[x]x{xrD,4}1 0,1],[1.5,25]and[3,4] 利用前面的公式可计算 迭代次数为k=23
[0,1], [1.5, 2.5] and [3,4], 利用前面的公式可计算 迭代次数为k=23
Remark2:要区别根与奇异点 Consider f(x)= tan(x)on the interval (0, 3). Use the 20 iterations of the bisection me thod and see what happens. Explain the results that you obtained (如下图)
Remark2:要区别根与奇异点 Consider f(x) = tan(x) on the interval (0,3).Use the 20 iterations of the bisection method and see what happens. Explain the results that you obtained. (如下图)