MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   MATLAB论坛 (https://www.labfans.com/bbs/forumdisplay.php?f=6)
-   -   [MATLAB数学相关] 显示欧拉法的问题 (https://www.labfans.com/bbs/showthread.php?t=12356)

swwnj 2010-12-07 21:30

显示欧拉法的问题
 
题目:dy=-y+x+1 y(0)=1 h=0.1
用显示欧拉法 【y(i+1)=y(i)+h*(-y(i)+x(i)+1)】 求解
我的结果如下:为什么误差不一直增大??
X Y 精解 误差
0 1.0000 1.0000 0
0.1000 1.0000 1.0048 0.0048
0.2000 1.0100 1.0187 0.0087
0.3000 1.0290 1.0408 0.0118
0.4000 1.0561 1.0703 0.0142
0.5000 1.0905 1.1065 0.0160
0.6000 1.1314 1.1488 0.0174
0.7000 1.1783 1.1966 0.0183
0.8000 1.2305 1.2493 0.0189
0.9000 1.2874 1.3066 0.0191
1.0000 1.3487 1.3679 0.0192
1.1000 1.4138 1.4329 0.0191
1.2000 1.4824 1.5012 0.0188
1.3000 1.5542 1.5725 0.0183
1.4000 1.6288 1.6466 0.0178
1.5000 1.7059 1.7231 0.0172
1.6000 1.7853 1.8019 0.0166
1.7000 1.8668 1.8827 0.0159
1.8000 1.9501 1.9653 0.0152
1.9000 2.0351 2.0496 0.0145
2.0000 2.1216 2.1353 0.0138
2.1000 2.2094 2.2225 0.0130
2.2000 2.2985 2.3108 0.0123
2.3000 2.3886 2.4003 0.0116
2.4000 2.4798 2.4907 0.0110
2.5000 2.5718 2.5821 0.0103
2.6000 2.6646 2.6743 0.0097
2.7000 2.7581 2.7672 0.0091
2.8000 2.8523 2.8608 0.0085
2.9000 2.9471 2.9550 0.0079
3.0000 3.0424 3.0498 0.0074


所有时间均为北京时间。现在的时间是 12:53

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.