24小时热门版块排行榜    

CyRhmU.jpeg
南方科技大学公共卫生及应急管理学院2025级博士研究生招生报考通知
查看: 2641  |  回复: 10
当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖

yanyl09

禁虫 (初入文坛)

本帖内容被屏蔽

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

已阅   关注TA 给TA发消息 送TA红花 TA的回帖

yanyl09

禁虫 (初入文坛)

本帖内容被屏蔽

4楼2011-12-06 15:58:49
已阅   关注TA 给TA发消息 送TA红花 TA的回帖
查看全部 11 个回答

dingd

铁杆木虫 (职业作家)

【答案】应助回帖

微分方程拟合推荐使用1stOpt,更强大方便些。
2楼2011-12-05 17:01:18
已阅   关注TA 给TA发消息 送TA红花 TA的回帖

yanyl09

禁虫 (初入文坛)

本帖内容被屏蔽

3楼2011-12-06 09:02:08
已阅   关注TA 给TA发消息 送TA红花 TA的回帖

dbb627

荣誉版主 (著名写手)

【答案】应助回帖

yanyl09(金币+10): 非常感谢,公式的修改对我启发很大,我再试试,谢谢!!! 2011-12-06 22:37:09
我觉得你的模型不太对
我该了下,你试试,其实第一个生物量还是有问题,你没有考虑死亡率,估计改后会好些
CODE:
function AA
k0=[0.1 2 2];
x0=[0.01 54.026 0.2435];
t1=0:6:48;
tspan=0:6:48;
yexp=load('sample_file.txt')';
lb=[-10 -10 -10];ub=[10 10 10];
[k,resnorm,resid,exitflag,output,lambda,jacobian]=lsqnonlin(@ObjFunc4LNL8,k0,[0 0 0],[],[],x0,yexp);
ci=nlparci(k,resid,jacobian);
y1=[yexp(:,1)]';
y2=[yexp(:,2)]';
y3=[yexp(:,3)]';
[t4plot x4plot]=ode45(@kineticseqs8,[tspan(1) tspan(end)],x0,[],k);
plot(t1,y1,'bo',t1,y2,'g+',t1,y3,'r*',t4plot,x4plot,'k-'),
legend('Exp-biomass','Exp-glucose','Exp-butanol','Model'),
xlabel('time(h)'),ylabel('biomass dry weight(g/l),glucose(g/l),butanol(g/l)')
fprintf('Estimated Parameter\n'),
fprintf('\tk=%.4f %.4f\n',k(1),ci(1,2)-k(1))
fprintf('\tk=%.4f %.4f\n',k(2),ci(2,2)-k(2))
fprintf('\tk=%.4f %.4f\n',k(3),ci(3,2)-k(3))
[t,x]=ode45(@kineticseqs8,tspan,x0,[],k);
figure,plot(x,resid,'*')
xlabel('biomass dry wight(g/l)、glucose(g/l)、butanol(u/ml)'),
ylabel('Residuals(g/l,u/ml)')

function dxdt=kineticseqs8(t,x,k)
% dxdt=[k(1)*(1-x(2)./12)*x(1)
%    -k(2)*x(1).^2
%     k(3)*k(1)*(1-x(2)./12)*x(1)];
dxdt=[k(1)*x(1)*(1-x(1)/3)
   -k(2)*x(1)*x(2)
    k(3)*x(2)*x(1)];

function f=ObjFunc4LNL8(k,x0,yexp)
x0=[0.01 54.026 0.2435];
tspan=[0:6:48]';
[t1 x]=ode45(@kineticseqs8,tspan,x0,[],k);
y(:,1)=x(:,1);y(:,2)=x(:,2);y(:,3)=x(:,3);
f1=y(:,1)-yexp(:,1);f2=y(:,2)-yexp(:,2);f3=y(:,3)-yexp(:,3);
f=[f1 f2 f3];

» 本帖已获得的红花(最新10朵)

The more you learn, the more you know, the more you know, and the more you forget. The more you forget, the less you know. So why bother to learn.
5楼2011-12-06 17:55:00
已阅   关注TA 给TA发消息 送TA红花 TA的回帖
信息提示
请填处理意见