欢迎来到天天文库
浏览记录
ID:11863201
大小:59.65 KB
页数:20页
时间:2018-07-14
《微分方程数值解课程设计》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、利用五点差分格式求解拉普拉斯方程的混合边值问题要求:给出问题,计算格式,格式的矩阵形式,线性代数方程组求解的数值方法,稳定性,格式的截断误差;程序流程图;沿y=1画出计算结果与精确解的比较图形以及误差图形(在一个图上);分析两个迭代法的收敛速度。E=-1.10000.5000000000000.5000-2.10000.5000000000000.5000-2.10000.5000000000000.5000-2.10000.5000000000000.5000-2.10000.5000000000000.5000-2.10000.500
2、0000000000.5000-2.10000.5000000000000.5000-2.10000.5000000000000.5000-2.10000.5000000000000.5000-2.1000h=0.1Em=-2.10001.0000000000001.0000-4.00001.0000000000001.0000-4.00001.0000000000001.0000-4.00001.0000000000001.0000-4.00001.0000000000001.0000-4.00001.0000000000001.000
3、0-4.00001.0000000000001.0000-4.00001.0000000000001.0000-4.00001.0000000000001.0000-4.0000K=0.500000000000001.000000000000001.000000000000001.000000000000001.000000000000001.000000000000001.000000000000001.000000000000001.000000000000001.0000A=[EKzeros(10)zeros(10)zeros(10
4、)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(1
5、0)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)ze
6、ros(10)zeros(10)zeros(10)zeros(10)KEmKzeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)zeros(10)KEm]g=0-0.0100-0.0400-0.0900-0.1600-0.2500-0.3600-0.4900-0.6400-0.81000.010000000000-9.90000.040000000000-9.60000.090000000000-9.10000.160000000000-8.40000.250000
7、000000-7.50000.360000000000-6.40000.490000000000-5.10000.640000000000-3.60005.81009.90009.60009.10008.40007.50006.40005.10003.60001.9000U=zeros(100,1)nm=100;w=10^-2;jacobi(A,h*g,U,nm,w)迭代次数为n=44方程组的解为x=00.00870.03500.07950.14370.22900.33680.46800.62280.8006-0.008700.02600
8、.07020.13380.21870.32610.45720.61210.7902-0.0350-0.026000.04390.10720.19150.29840.42890.58320.76
此文档下载收益归作者所有