求大神解“y=x^3-3*x+2 的根”用牛顿法 ( matlab作业)怎么写?

学习 时间:2026-05-29 03:31:12 阅读:3543
求大神解“y=x^3-3*x+2 的根”用牛顿法 ( matlab作业)怎么写?具体的程序怎么写? 用书中的方法怎么不行?

最佳回答

孤独的板凳

雪白的鲜花

2026-05-29 03:31:12

程序:clcclearx=zeros(1,25);x(1)=2;format longfor i=1:24;x(i+1)=x(i)-(x(i)^3-3*x(i)+2)/(3*x(i)^2-3);enddisp(x)迭代结果Columns 1 through 52。000000000000000 1。555555555555556 1。297906602254428 1。155390199213767 1。079562210414361Columns 6 through 101。040288435171016 1。020276809786734 1。010172323431422 1。005094741093271 1。002549528082823Columns 11 through 151。001275305026235 1。000637787960349 1。000318927867230 1。000159472408678 1。000079738323303Columns 16 through 201。000039869691243 1。000019934977174 1。000009967523452 1。000004983765981 1。000002491890589Columns 21 through 251。000001245940288 1。000000622991949 1。000000311543435 1。000000155931967 1。000000077850191

最新回答共有2条回答

  • 内向的小丸子
    回复
    2026-05-29 03:31:12

    程序:clcclearx=zeros(1,25);x(1)=2;format longfor i=1:24;x(i+1)=x(i)-(x(i)^3-3*x(i)+2)/(3*x(i)^2-3);enddisp(x)迭代结果Columns 1 through 52。000000000000000 1。555555555555556 1。297906602254428 1。155390199213767 1。079562210414361Columns 6 through 101。040288435171016 1。020276809786734 1。010172323431422 1。005094741093271 1。002549528082823Columns 11 through 151。001275305026235 1。000637787960349 1。000318927867230 1。000159472408678 1。000079738323303Columns 16 through 201。000039869691243 1。000019934977174 1。000009967523452 1。000004983765981 1。000002491890589Columns 21 through 251。000001245940288 1。000000622991949 1。000000311543435 1。000000155931967 1。000000077850191

上一篇 very good 如何造句

下一篇 高一英语定语从句填空