| 查看: 597 | 回复: 0 | ||
[求助]
求助如下的Matlab拟合函数怎样在cftool中使用
|
|
关于一个衰减的拟合函数,最后拟合出衰减寿命tau1,tau2,求教各位,怎样在matlab中正确使用该拟合函数? function y =expfit_gekoppelt(x,A,t0,C,tau1,tau2,B,FWHM) %y=0*x; %for i = 1:length(x) % if x(i) < t0, % y(i) = A; % else % y(i) = A+C*exp(-(x(i)-t0)/tau1)-B*exp(-(x(i)-t0)/tau2); % end %end % initialize return variable: %z = 0*x; y = 0*x; % prepare for convolution: gaussian on a time window twin = [-1:0.01:1] * 3*(FWHM/(2*sqrt(2*log(2)))); g = 1/sqrt(2*pi) * 1/(FWHM/(2*sqrt(2*log(2)))) * exp(-twin.^2/2/(FWHM/(2*sqrt(2*log(2))))^2); g=g/sum(g); %Normierung? %A=1.012; for nt = 1:length(x) % time window centered at t(nt): tc = x(nt) + twin; % the initial signal on the time window: %s = A .* (tc < t0) + (A+C*exp(-(tc-t0)/tau1)-B*exp(-(tc-t0)/tau2)) .*(tc >= t0); %s = A * (tc < t0) + (B + (A-B) * exp(-(tc-t0)/tau1) +(B-C) * exp(-(tc-t0)/tau2)) .* (tc >= t0); s = A * (tc < t0) + (B + (A-B) * exp(-(tc-t0)/tau1) +abs(B-C)+(B-C) * exp(-(tc-t0)/tau2)) .* (tc >= t0); % measured signal: initial folded with gaussian: y(nt) = sum(s .* g); end end |
» 猜你喜欢
生命口C13面上会评时间
已经有11人回复
内心匮乏
已经有16人回复
生命口面上会评结束了吗大家有知道结果吗?现在还没有结果正常不?
已经有9人回复
投英文期刊如何查重
已经有6人回复
不要再数国自然申请书的 filecode 的分隔符个数了
已经有21人回复
伯胺上甲基求助
已经有7人回复
跨出版社商投稿
已经有5人回复
5个%2F,非固定段22个字母
已经有7人回复
生生命学部会评
已经有4人回复
H口,面上,时间戳7月7日。
已经有3人回复











回复此楼