正在加载图片...
§2 Bisection method Lab 02. bisection method Use the Bisection method to find on m given intervals the m real roots of a given polynomial of degree5≥n≥m,p(x)=cnx+cn-1x+…+c1x+Co Input There are severalsets ofinputs. For each set The 1st line contains an integer n which is the degree of a polynomial. n=-l signals the end of file. The 2nd line contains n+l real numbers cn. C Co which are the coefficients of the polynomial. The numbers are separated by spaces. The 3rd line contains an integer Max and two real numbers epsl and eps2, where Max is the maximum number of iterations, eps l is the accuracy bound for x and eps 2 is the accuracy bound forp(x). The 4th line contains an integer m(n2 m20), followed by m pairs of real numbers a bi...am bm which are the end points of the intervals Ia1,b1l…Iam,bml,§2 Bisection Method Lab 02. Bisection Method Use the Bisection method to find on m given intervals the m real roots of a given polynomial of degree 5  n  m, . Input There are severalsets of inputs. For each set: The 1 st line contains an integer n which is the degree of a polynomial. n = −1 signalsthe end of file. The 2 nd line contains n+1 real numbers which are the coefficients of the polynomial. The numbers are separated by spaces. The 3 rd line contains an integer Max and two real numbers eps1 and eps2, where Max is the maximum number of iterations, eps1 is the accuracy bound for x and eps2 is the accuracy bound for p(x). The 4 th line contains an integer m (n  m  0), followed by m pairs of real numbers a1 b1 …am bm which are the end points of the intervals [ a1 , b1 ] …[ am , bm ]. 1 0 1 1 p(x) c x c x ... c x c n n n = n + + + + − − 1 0 c ... c c n
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有