matlab二阶微分方程组解functionDy=dfun(-查字典问答网
分类选择

来自白岩的问题

  matlab二阶微分方程组解functionDy=dfun(t,y)D2y(1,1)=(0.0176*y(2)-960-23.85/(0.0088-0.0072*y(1)).^1.4-0.1*Dy(1,1))/96;Dy(2,1)=(-0.0176*Dy(1,1)-0.1*y(2)+2)/(2.4e7*y(1));t=linspace(0,0.15,100);ode113('dfun',t,[0,16e6]);这有什么问题

  matlab二阶微分方程组解

  functionDy=dfun(t,y)

  D2y(1,1)=(0.0176*y(2)-960-23.85/(0.0088-0.0072*y(1)).^1.4-0.1*Dy(1,1))/96;

  Dy(2,1)=(-0.0176*Dy(1,1)-0.1*y(2)+2)/(2.4e7*y(1));

  t=linspace(0,0.15,100);

  ode113('dfun',t,[0,16e6]);

  这有什么问题

2回答
2020-12-2712:34
我要回答
提示:回答问题需要登录哦!
孙作玉

  把原方程写出来看看,你这种写法比较非主流

2020-12-27 12:36:27
孙作玉

  你的初值有问题,再检查检查

  clc

  f=@(t,x)([x(2);-.0027/96*x(3)+10-9.5e-6/96/(.0088-.0072*x(1))^1.4-.1/96*x(2);(2-.0176*x(2)-.1*x(3))/x(1)/2.4e7]);

  [t,x]=ode45(f,[0.15],[1116e6]);

  subplot(1,2,1),plot(t,x(:,3))

  xlabel('t'),ylabel('p1')

  subplot(1,2,2),plot(t,x(:,1))

  xlabel('t'),ylabel('x')

2020-12-27 12:38:50
大家都在问
最新问答