下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
本文格式为Word版,下载可任意编辑——偏微分方程上机试验报告doc
上机试验2:五点差分格式法偏微分方程(Matlab)试验报告
——五点差分格式法一、试验题目
设G是形如下图的十字形域,由五个相等的单位正方形组成,用五点差分格式求以下边值问题的数值解:
?u?u?2??1,于G2?x?yu=0,于?G二、试验原理
22G1G取定沿X轴和Y轴方向的步长h1和h2,h??h?h221122?,作两族与坐
标轴平行的直线:x=ih1,y=jh2,i,j?0,?1,?2,?
若(xi,yj)为正则内点,沿x,y方向分别用二阶中心差商代替
uxx和uyy则得
?[ui?1,j?2uij?ui?1,jh12?ui,j?1?2uij?ui,j?12h2]?fij
特别取正方形网格:h1?h2?h,则原差分方程可简化为
1h2uij?(ui?1,j?ui,j?1?ui?1,j?ui,j?1)?fij
44三、试验程序
1)functionuxy=EllIni2Uxl(x,y)
formatlong;
uxy=0;
2)functionuxy=EllIni2Uxr(x,y)formatlong;uxy=y*(2-y);
3)functionuxy=EllIni2Uyl(x,y)formatlong;uxy=0;
4)functionuxy=EllIni2Uyr(x,y)formatlong;ifx1A(i,i+nx-2)=1;A(i,i+1)=1;b(i)=-u0(1,i+1);elseifi>(ny-3)*(nx-2)A(i,i-nx+2)=1;A(i,i+1)=1;b(i)=-u0(ny,mod(i,(nx-2))+1);elseA(i,i-1)=1;A(i,i+1)=1;A(i,i+nx-2)=1;A(i,i-nx+2)=1;end
endendendend
ul=A\\b;
fori=1:(ny-2)forj=1:(nx-2)
u(i,j)=ul((i-1)*(nx-2)+j);endend
formatshort;
四、试验结果
>>u=peEllip5(25,0,3,25,0,3)u=
Columns1through6
1.14482.28963.26712.28964.74666.70363.26706.70359.50504.07498.295511.80644.73709.597313.69905.275910.657615.24655.708911.510816.49516.049012.181617.47876.305512.688018.22216.485113.042618.74326.592213.254219.05436.629413.327819.16236.597713.265119.07006.496413.064818.77546.323112.722518.27206.073612.229817.54865.741511.574716.58795.317510.739515.36594.78919.700013.84924.13898.422111.99233.34456.85729.73182.38204.93036.97621.25322.50583.5896
Columns7through12
4.07508.295711.806614.726217.145719.134320.744422.015922.978523.654024.057324.197324.077123.694623.041722.104720.862619.286817.338514.966212.10148.65304.50164.73729.597713.699417.146020.023322.400524.332425.861927.022027.836928.323728.492428.346727.884127.095725.965724.471022.580320.251917.432614.054610.03305.26375.276310.658315.247419.135122.401125.112027.322829.077530.410631.348131.908232.101931.933231.399530.491129.191327.475625.311322.656219.457715.651511.16075.8950
5.70956.04996.30686.48696.59466.632711.511912.183312.690513.046113.259013.334116.496617.481018.225618.748219.061019.171320.746122.018622.982623.660024.065624.208524.333925.864727.026427.843528.333028.505127.323829.079830.414831.354731.917832.115329.769331.716033.198234.242634.868435.087131.714633.816835.419336.549237.226037.461533.194735.417237.112934.236636.544538.306234.859137.217839.018635.073737.449139.262134.884837.242739.041134.289636.595938.352933.278035.498537.187231.832833.932935.526529.928931.873933.345427.533129.288530.611224.603926.135827.283821.090422.367123.315616.932917.926618.652612.063312.753713.23516.40586.78986.9996
Columns13through18
6.60206.50196.330213.273313.075512.736119.081818.790618.291524.091823.713523.066028.363527.905927.123431.951231.423030.521134.903134.313733.309037.260336.619635.529439.057138.375137.216740.320139.607038.398141.068840.334739.092841.315240.570439.312941.064040.318539.063240.312439.576638.340939.050338.334437.136337.260036.574535.431834.916534.271633.2024
38.309039.548940.288440.539540.306739.587338.371136.640334.369831.527228.072523.959019.132913.53477.09856.082612.247317.573422.135426.000729.229131.871933.972135.564436.675737.325437.525437.280336.587735.438033.814031.690939.024940.292041.046541.300741.059040.318739.069537.293834.966532.055228.520224.314819.385413.67237.10965.753011.597016.619520.901424.515027.522729.977531.922633.393034.415135.007835.182934.945034.291733.213931.695129.711239.272840.547541.305141.557741.309940.558839.294437.498835.147232.207028.638424.394519.421613.65967.04275.332510.768215.406119.335822.635025.369427.592629.348030.669831.583732.107832.253432.024931.420330.430929.041427.2288
31.987131.393130.415329.036227.230024.962328.431827.898527.029525.808424.210522.202324.203223.739622.995921.957520.601618.896619.246818.860718.257117.423916.342014.983813.501813.199312.748012.139011.358610.38596.90166.68686.39646.02575.56745.0103
Columns19through23
4.80879.737313.900917.400520.320022.727124.675426.207127.354628.142128.586428.698028.480927.933627.048125.810624.202322.188519.737716.799313.31079.19114.3378
>>
4.16518.471412.059715.045417.517519.543621.174922.450423.399524.043624.397824.471124.267323.784923.017421.952820.573218.853716.761314.252311.26857.72993.52473.38016.92369
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 二零二五年度畜禽养殖场地租赁及管理服务协议3篇
- 二零二五年度公司股权转让与员工安置保障合同3篇
- 2025年度年度合伙开设甜品店合同3篇
- 二零二五年度农业科技公司聘用兼职农业技术员合同书3篇
- 2025年度农村土地租赁与农业产业化项目合作协议2篇
- 2025年度超市绿色环保供应链合作协议书3篇
- 2025年度农村保洁员工作绩效评估合同2篇
- 2025年常用食品供货合同模板范文
- 2025年度国有土地租赁协议合同(科技孵化器)3篇
- 二零二五年度智能硬件内部股东股权转让合同模板3篇
- 2023年开封粮食产业集团有限公司招聘笔试真题
- 2024年全国“纪检监察”业务相关知识考试题库(附含答案)
- 2025年社区工作者考试试题库及答案
- 期末检测卷(三)2024-2025学年人教PEP版英语四年级上册(含答案无听力原文无听力音频)
- 2024-2030年中国儿童内衣行业运营状况及投资前景预测报告
- 吉首大学《高等数学》2023-2024学年第一学期期末试卷
- 人教版(2024新版)八年级上册物理期末必刷多项选择题50题(含答案解析)
- PAS 2050:2011-商品和服务在生命周期内的温室气体排放评价规范(中文)
- 手术分级目录(2023年修订)
- 山东省青岛市2023-2024学年高一上学期1月期末物理试题 含解析
- 2024年山东济南轨道交通集团运营有限公司招聘笔试参考题库含答案解析
评论
0/150
提交评论