Labfans是一个针对大学生、工程师和科研工作者的技术社区。 | 论坛首页 | 联系我们(Contact Us) |
![]() |
![]() |
#1 |
初级会员
注册日期: 2009-05-25
帖子: 4
声望力: 0 ![]() |
![]()
clc;clear;
x=[-500 -480 -450 -400 -350 -300 -200 -180 -150 -100 -75 -50 -25 0 50 100 125 150 200 220 230 300 350 400 500 600]; y=[0 4 6 10 50 120 150 180 200 400 600 800 1200 1400 1600 1500 1000 800 400 390 300 180 150 50 25 0]; myfunc=inline('0.5*beta(1)*sqrt(3)*erf(sqrt(pi)*beta(2)*x/200)-beta(1)*sqrt(3)*0.5*erf(sqrt(pi)*beta(2)/200*(100-beta(3)-beta(4))','beta','x'); beta=nlinfit(x,y,myfunc,[0.5 1 20 20]); q=beta(1),tanβ=beta(2),s3=beta(3),s4=beta(4) %test the model xx=min(x):max(x); yy=q*sqrt(3)*0.5*erf(sqrt(pi)*tanβ*x/200)-q*sqrt(3)*0.5*erf(sqrt(pi)*tanβ/200*(100-beta(3)-beta(4)); plot(x,y,'o',x,yy,'r') 帮忙怎样修改呢?初学者 baidu的用户可进http://zhidao.baidu.com/question/99432374.html 有加分 |
![]() |
![]() |