收藏 分享(赏)

通过MATLAB求二阶全微分方程解析解.pdf

上传人:精品资料 文档编号:9955814 上传时间:2019-09-22 格式:PDF 页数:12 大小:601.11KB
下载 相关 举报
通过MATLAB求二阶全微分方程解析解.pdf_第1页
第1页 / 共12页
通过MATLAB求二阶全微分方程解析解.pdf_第2页
第2页 / 共12页
通过MATLAB求二阶全微分方程解析解.pdf_第3页
第3页 / 共12页
通过MATLAB求二阶全微分方程解析解.pdf_第4页
第4页 / 共12页
通过MATLAB求二阶全微分方程解析解.pdf_第5页
第5页 / 共12页
点击查看更多>>
资源描述

1、1 . 对 于 二 阶 全 微 分 方 程 a , 不 同 的 a,b,c 取 值 会 求 出 不 同 的 解 析解 , 解 析 解 又 是 由 齐 次 解 和 特 解 组 成 。 其 中 , 齐 次 解 由 特 征 方 程 决 定 , 而 特 解 的 决 定 因素 则 比 较 复 杂 。2 . 对 于 二 阶 全 微 分 方 程 的 分 析 , 我 们 大 致 分 为 三 种 情 况 :b2 -4 ac0 (两 个 不 同 的 实 根 )b2 -4 ac=0 ( 两 个 相 同 的 重 根 )b2 -4 ac0 的 情 况STEP1 : 求 解 析 解s1=dsolve(D2y+3*Dy+2

2、*y=0,y(0)=2,Dy(0)=0,t);s2=dsolve(D2y+3*Dy+2*y=sin(t),y(0)=2,Dy(0)=0,t);s3=dsolve(D2y+3*Dy+2*y=sin(2*t),y(0)=2,Dy(0)=0,t);s4=dsolve(D2y+3*Dy+2*y=sin(5*t),y(0)=2,Dy(0)=0,t);s5=dsolve(D2y+3*Dy+2*y=sin(13*t),y(0)=2,Dy(0)=0,t);s6=dsolve(D2y+3*Dy+2*y=sin(25*t),y(0)=2,Dy(0)=0,t);STEP2 : 绘 制 图 形( 1 ) 求 w=1

3、情 况 下 的 通 解 和 齐 次 解t=1:0.1:10;s1=4*exp(-t)-2*exp(-2*t)%generalsolutions2=-3/10*cos(t)+1/10*sin(t)-11/5*exp(-2*t)+9/2*exp(-t)%specialsolutionsubplot(2,1,1);plot(t,s2);xlabel(t)ylabel(y(t)title(generalsolution)subplot(2,1,2);plot(t,s1);xlabel(t)ylabel(y(t)title(specialsolution)Figure1 -1(2 )求 通 解 随 w

4、变 化 的 规 律.w在 (0,1) 之 间 的 全 微 分 方 程 通 解clcclearalls1=dsolve(D2y+3*Dy+2*y=0,y(0)=2,Dy(0)=0,t);l2=dsolve(D2y+3*Dy+2*y=sin(0.05*t),y(0)=2,Dy(0)=0,t);l3=dsolve(D2y+3*Dy+2*y=sin(0.15*t),y(0)=2,Dy(0)=0,t);l4=dsolve(D2y+3*Dy+2*y=sin(0.25*t),y(0)=2,Dy(0)=0,t);l5=dsolve(D2y+3*Dy+2*y=sin(0.5*t),y(0)=2,Dy(0)=0,

5、t);l6=dsolve(D2y+3*Dy+2*y=sin(0.75*t),y(0)=2,Dy(0)=0,t);t=1:0.1:10;s1_n=eval(s1);l2_n=eval(l2);l3_n=eval(l3);l4_n=eval(l4);l5_n=eval(l5);l6_n=eval(l6);holdonplot(t,s1_n);plot(t,l2_n,m*);plot(t,l3_n,rx);plot(t,l4_n,g);plot(t,l5_n,bp);plot(t,l6_n,ko);holdoff.w在 (1,+) 之 间 的 全 微 分 方 程 通 解t=1:0.1:10;s1=-

6、2*exp(-2*t)+4*exp(-t);s2=-3/10*cos(t)+1/10*sin(t)-11/5*exp(-2*t)+9/2*exp(-t);s3=-3/20*cos(2*t)-1/20*sin(2*t)-9/4*exp(-2*t)+22/5*exp(-t);s4=-15/754*cos(5*t)-23/754*sin(5*t)-63/29*exp(-2*t)+109/26*exp(-t);s5=693/170*exp(-t)-39/29410*cos(13*t)-359/173*exp(-2*t)-167/29410*sin(13*t);s6=-1283/629*exp(-2*t

7、)-75/393754*cos(25*t)+2529/626*exp(-t)-623/393754*sin(25*t);holdonplot(t,s1);plot(t,s2,m*);plot(t,s3,rx);plot(t,s4,g);plot(t,s5,bp);plot(t,s6,ko);holdoff结 论 : 在 b2 -4 ac0 的 情 况 下 , 特 解 的 形 式 是 C1 *sint+C2 *cost,齐 次 解 的 形 式 是C1 *EXP(R1 *t)+C2 *EXP(R2 *t).若 w 为 正 值 且 随 w 的 增 大 , 通 解 的 形 式 趋 近 于 齐次 解 。

8、5 .b2 -4 ac=0 的 情 况STEP1 : 求 解 析 解S1=dsolve(D2y+y=0,y(0)=2,Dy(0)=1,t)S2=dsolve(D2y+y=sin(t),y(0)=2,Dy(0)=1,t)s3=dsolve(D2y+y=sin(2*t),y(0)=2,Dy(0)=1,t)s4=dsolve(D2y+y=sin(6*t),y(0)=2,Dy(0)=1,t)s5=dsolve(D2y+y=sin(10*t),y(0)=2,Dy(0)=1,t)s6=dsolve(D2y+y=sin(100*t),y(0)=2,Dy(0)=1,t)l0=dsolve(D2y+y=sin(

9、0.05*t),y(0)=2,Dy(0)=1,t)l1=dsolve(D2y+y=sin(0.15*t),y(0)=2,Dy(0)=1,t)l2=dsolve(D2y+y=sin(0.25*t),y(0)=2,Dy(0)=1,t)l3=dsolve(D2y+y=sin(0.5*t),y(0)=2,Dy(0)=1,t)l4=dsolve(D2y+y=sin(0.75*t),y(0)=2,Dy(0)=1,t)STEP2 : 绘 制 图 形( 1 ) 求 w=1 情 况 下 的 通 解 和 齐 次 解t=1:0.1:10;s1=2*exp(-2*t)+5*exp(-2*t).*t;s2=54/25*

10、exp(-2*t)+26/5*exp(-2*t).*t-4/25*cos(t)+3/25*sin(t);subplot(2,1,1);plot(t,s1);xlabel(t)ylabel(y(t)title(homogenioussolution)subplot(2,1,2);plot(t,s2);xlabel(t)ylabel(y(t)title(generalsolution)( 2 ) (2 )求 通 解 随 w 变 化 的 规 律.w在 (0,1) 之 间 的 全 微 分 方 程 通 解t=1:0.1:10;s1=2*exp(-2*t)+5*exp(-2*t).*t;l2=515840

11、2/2563201*exp(-2*t)+8025/1601*exp(-2*t).*t-32000/2563201*cos(1/20*t)+639600/2563201*sin(1/20*t);l3=5273762/2588881*exp(-2*t)+8105/1609*exp(-2*t).*t-96000/2588881*cos(3/20*t)+636400/2588881*sin(3/20*t);l4=8706/4225*exp(-2*t)+329/65*exp(-2*t).*t-256/4225*cos(1/4*t)+1008/4225*sin(1/4*t);l5=610/289*exp(

12、-2*t)+87/17*exp(-2*t).*t-32/289*cos(1/2*t)+60/289*sin(1/2*t);l6=11426/5329*exp(-2*t)+377/73*exp(-2*t).*t-768/5329*cos(3/4*t)+880/5329*sin(3/4*t);holdonplot(t,s1);plot(t,l2,m*);plot(t,l3,rx);plot(t,l4,g);plot(t,l5,bp);plot(t,l6,ko);holdoff.w在 (1,+) 之 间 的 全 微 分 方 程 通 解t=1:0.1:10;s1=2*exp(-2*t)+5*exp(-

13、2*t).*t;s2=54/25*exp(-2*t)+26/5*exp(-2*t).*t-4/25*cos(t)+3/25*sin(t);s3=3522/1681*exp(-2*t)+215/41*exp(-2*t).*t-160/1681*cos(5/2*t)-36/1681*sin(5/2*t);s4=350/169*exp(-2*t)+68/13*exp(-2*t).*t-12/169*cos(3*t)-5/169*sin(3*t);s5=1702/841*exp(-2*t)+150/29*exp(-2*t).*t-20/841*cos(5*t)-21/841*sin(5*t);s6=1

14、04942/52441*exp(-2*t)+1160/229*exp(-2*t).*t-60/52441*cos(15*t)-221/52441*sin(15*t);holdonplot(t,s1);plot(t,s2,m*);plot(t,s3,rx);plot(t,s4,g);plot(t,s5,bp);plot(t,s6,ko);holdoff结 论 :W属 于 (0,1) 时 , 随w的 增 大 在 齐 次 解 的 旁 边 波 动 ;w属 于 (1,+) , 随w的增 大 逐 渐 趋 近 于 齐 次 解 。4 . b2 -4 ac0 s2=dsolve(D2y+Dy+y=sin(t),

15、y(0)=2,Dy(0)=1,t)s3=dsolve(D2y+Dy+y=sin(2*t),y(0)=2,Dy(0)=1,t)s4=dsolve(D2y+Dy+y=sin(2.5*t),y(0)=2,Dy(0)=1,t)s5=dsolve(D2y+Dy+y=sin(3*t),y(0)=2,Dy(0)=1,t)s6=dsolve(D2y+Dy+y=sin(3.5*t),y(0)=2,Dy(0)=1,t)s7=dsolve(D2y+Dy+y=sin(5*t),y(0)=2,Dy(0)=1,t).w在 (0,1) 之 间 的 全 微 分 方 程 通 解.w在 (1,+) 之 间 的 全 微 分 方 程

16、 通 解2 .b.w在 (0,1) 之 间 的 全 微 分 方 程 通 解.w在 (1,+) 之 间 的 全 微 分 方 程 通 解2 .b=0 STEP1 : 求 解 析 解S1=dsolve(D2y+y=0,y(0)=2,Dy(0)=1,t)S2=dsolve(D2y+y=sin(t),y(0)=2,Dy(0)=1,t)s3=dsolve(D2y+y=sin(2*t),y(0)=2,Dy(0)=1,t)s4=dsolve(D2y+y=sin(6*t),y(0)=2,Dy(0)=1,t)s5=dsolve(D2y+y=sin(10*t),y(0)=2,Dy(0)=1,t)s6=dsolve(

17、D2y+y=sin(100*t),y(0)=2,Dy(0)=1,t)l0=dsolve(D2y+y=sin(0.05*t),y(0)=2,Dy(0)=1,t)l1=dsolve(D2y+y=sin(0.15*t),y(0)=2,Dy(0)=1,t)l2=dsolve(D2y+y=sin(0.25*t),y(0)=2,Dy(0)=1,t)l3=dsolve(D2y+y=sin(0.5*t),y(0)=2,Dy(0)=1,t)l4=dsolve(D2y+y=sin(0.75*t),y(0)=2,Dy(0)=1,t)STEP2 : 绘 制 图 形( 3 ) 求 w=1 情 况 下 的 通 解 和 齐

18、 次 解t=1:0.1:10;s1=sin(t)+2*cos(t);s2=3/2*sin(t)+2*cos(t)-1/2.*cos(t).*t;subplot(2,1,1);plot(t,s1);xlabel(t)ylabel(y(t)title(homogenioussolution)subplot(2,1,2);plot(t,s2);xlabel(t)ylabel(y(t)title(generalsolution)(2 )求 通 解 随 w 变 化 的 规 律.w在 (0,1) 之 间 的 全 微 分 方 程 通 解t=1:0.1:10;l0=379/399*sin(t)+2*cos(t

19、)+400/399*sin(1/20*t);l1=331/391*sin(t)+2*cos(t)+400/391*sin(3/20*t);l2=11/15*sin(t)+2*cos(t)+16/15*sin(1/4*t);l3=1/3*sin(t)+2*cos(t)+4/3*sin(1/2*t);l4=-5/7*sin(t)+2*cos(t)+16/7*sin(3/4*t);s1=sin(t)+2*cos(t);holdonplot(t,s1);plot(t,l0,m*);plot(t,l1,rx);plot(t,l2,g);plot(t,l3,bp);plot(t,l4,ko);holdof

20、f.w在 (1,+) 之 间 的 全 微 分 方 程 通 解t=1:0.1:10;l2=11/15*sin(t)+2*cos(t)+16/15*sin(1/4*t);l3=1/3*sin(t)+2*cos(t)+4/3*sin(1/2*t);s1=sin(t)+2*cos(t);%s2=3/2*sin(t)+2*cos(t)-1/2*cos(t)*t;s3=5/3*sin(t)+2*cos(t)-1/3*sin(2*t);s4=41/35*sin(t)+2*cos(t)-1/35*sin(6*t);holdonplot(t,s1);plot(t,s3,rx);plot(t,s4,g);plot(t,l2,bp);plot(t,l3,ko);holdoff结 论 : w=1是 特 殊 情 况 ,s2=3/2*sin(t)+2*cos(t)-1/2*cos(t)*t( 见figure) ;W属 于 (0,1) 时 , 随w的 增 大 在 齐 次 解 的 旁 边 波 动 ;w属 于 (1,+) , 随w的 增大 逐 渐 趋 近 于 齐 次 解 。

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 企业管理 > 管理学资料

本站链接:文库   一言   我酷   合作


客服QQ:2549714901微博号:道客多多官方知乎号:道客多多

经营许可证编号: 粤ICP备2021046453号世界地图

道客多多©版权所有2020-2025营业执照举报