資源描述:
《阻滯增長模型》由會員上傳分享,免費在線閱讀,更多相關(guān)內(nèi)容在工程資料-天天文庫。
1、阻滯增長模型Y=[84779867278876190409924209326794774962599754298705100072101654103008104357105851107507109300111026112704114333115823117171118517119850121121122389123626124761125786126743];T=[123456789101112131415161718192021222324252627282930];fort=1:30x(t)=exp(-t);y(t)=1/Y(t);endc=zer
2、os(30,1)+1;X=[c,x'];B=inv(X'*X)*X'*y'fori=1:30,z(i)=B(1,1)+B(2,1)*x(i);s(i)=y(i)-sum(y)/30;w(i)=z(i)-y(i);endS=s*s';Q=w*w';U=S-Q;F=28*U/Qforj=1:30,Y(j)=1/(B(1,1)+B(2,1)*exp(-j));endplot(T,Y)B=1.0e-005*0.93150.8670F=10.7066x=[197119721973197419751976197719781979198019811982198319
3、841985198619871988198919901991199219931994199519961997199819992000];y=[84779867278876190409924209326794774962599754298705100072101654103008104357105851107507109300111026112704114333115823117171118517119850121121122389123626124761125786126743];plot(x,y,'r.')xlabel('年份')ylabel('人口
4、')clearsymsab;c=[a,b]';A=[125786126743127627128453129227129988130756131448132129132802];B=cumsum(A);n=length(A);fori=1:(n-1)C(i)=(B(i)+B(i+1))/2;endD=A;D(1)=[];D=D';E=[-C;ones(1,n-1)];c=inv(E*E')*E*D;c=c';a=c(1);b=c(2);F=[];F(1)=A(1);fori=2:(n+10)F(i)=(A(1)-b/a)/exp(a*(i-1))+b/a
5、;endG=[];G(1)=A(1);fori=2:(n+10)G(i)=F(i)-F(i-1);endt1=1999:2008;t2=1999:2018;Gplot(t1,A,'*',t2,G)G=1.0e+005*Columns1through61.25791.26911.27651.28391.29141.2989Columns7through121.30651.31411.32171.32941.33721.3450Columns13through181.35281.36071.36861.37651.38461.3926Columns19th
6、rough201.40071.4089