科学计算科学计算 (40).pdf
《科学计算科学计算 (40).pdf》由会员分享,可在线阅读,更多相关《科学计算科学计算 (40).pdf(21页珍藏版)》请在淘文阁 - 分享文档赚钱的网站上搜索。
1、6.66.6 Application Application Examples Examples of of Ordinary Ordinary Differential EquationsDifferential EquationsLotka-Volterra model Improved Lotka-Volterra model1 1LotkaLotka-Volterra Volterra MModel odel The first-order nonlinear differential equations:In this,t for time,r(t)for the number of
2、 rabbits,f(t)for the number of foxes,and is a positive number.This system is cyclical.The period depends on the initial conditions.In other words,for any number of r(0)and f(0),there is always a time,t=tp,which can return the numbers of these two populations to their initial values.=+=drdtrrf rrdfdt
3、frf ff2,(0),(0)00 Under the condition of r0=300、f0=150、=0.01,find the solution of the system,and you will find that tpis close to.Create the curves of the r(t)and f(t)functions as well as the phase plane plot taking r and f as coordinate axis.Under the condition of r0=102、f0=198、=0.01,solve and draw
4、 the graph,and determine the cycle tp.Point(r0,f0)=(1/,2/)is a stable equilibrium point.If this is used as the initial value,the population will not change.If the initial value is close to this equilibrium point,then the quantity will not change significantly.Try drawing to verify.(1)Analyze the sys
5、tem modelx1(t)the number of rabbits at moment t x2(t)the number of foxes at moment tr1the growth rate when the rabbits live on their own r2the mortality rate when foxes live alone1the foxs ability to prey on rabbits 2the support ability of rabbits for foxes=dxdtx r11 1=dxdtx rx11112()=dxdtx r222=+dx
6、dtxrx22221()=dxdtx rx11112()=+dxdtxrx22221()It is assumed here that r1=2,r2=1,1=2=0.01,that is,the system model is as follows:=dxdtxx112(20.01)=+dxdtxx221(10.01)Solve the first question:The initial number of rabbits x1(0)=300,and the initial number of foxes x2(0)=150.rabbitFox=(t,x)x(1)*(2-0.01*x(2)
7、;x(2)*(-1+0.01*x(1);t,x=ode45(rabbitFox,0,30,300,150)subplot(1,2,1);plot(t,x(:,1),-,t,x(:,2),-*);legend(x1(t),x2(t);xlabel(Time);ylabel(Number of species);grid onsubplot(1,2,2);plot(x(:,1),x(:,2)grid onWe can see that the rabbit and the fox are mutually restrictive.When the fox gradually increases,t
8、he rabbit gradually decreases.When the fox increases to a certain number,due to the fierce internal competition in the population,the number of the fox is reduced,which reduces the natural enemies of the rabbit,which in turn leads to the number of rabbits increases.When the number of rabbits increas
9、es to a certain number,competition among species intensifies,which in turn leads to a decrease in the number of rabbits.This cycle restricts each others development.Solve the second question:The initial number of rabbits x1(0)=15,and the initial number of foxes x2(0)=22.Solve the third question:The
10、initial number of rabbits x1(0)=102,and the initial number of foxes x2(0)=198.Solve the fourth question:Verify(1/,2/)is the stable equilibrium point.Take=0.01,so the stable equilibrium point(1/,2/)is(100,200),using this pointas the initial value to draw the image.rabbitFox=(t,x)x(1)*(2-0.01*x(2);.x(
11、2)*(-1+0.01*x(1);t,x=ode45(rabbitFox,0,30,100,200);plot(t,x(:,1),-o,t,x(:,2),-*);legend(x1(t)-Rabbit,x2(t)-Fox);xlabel(Time);ylabel(Number of species);When the initial values are changed to(98,195),which is to get very close to the equilibriumpoint downward,its graph is drawn.rabbitFox=(t,x)x(1)*(2-
12、0.01*x(2);.x(2)*(-1+0.01*x(1);t,x=ode45(rabbitFox,0,30,98,195);plot(t,x(:,1),-o,t,x(:,2),-*);legend(x1(t)-Rabbit,x2(t)-Fox);xlabel(Time);ylabel(Number of species);We finnd no intersection between the two graphs.The numbers of rabbits and foxes experience periodic fluctuations at their equilibrium po
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 科学计算科学计算 40 科学 计算 40
限制150内