WBS=[0.43,8.09,0.54,18.550.42,0.67,0.51,1.960.38,0.21,0.51,1.310.42,0.39,0.51,0.660.45,0.35,0.56,0.610.47,0.35,0.58,0.660.46,0.19,0.58,0.280.51,0.16,0.64,0.190.52,0.13,0.66,0.30.53,0.1,0.68,0.350.59,0.16,0.78,0.280.57,0.17,0.74,0.390.61,0.15,0.85,0.360.63,0.22,0.89,0.250.68,0.27,0.98,0.330.79,0.12,1.1,0.440.8,0.24,0.95,0.520.8,0.28,0.78,0.630.87,0.4,0.74,0.590.73,0.24,0.58,0.950.65,0.13,0.53,0.820.67,0.31,0.52,0.780.7,0.31,0.54,0.920.86,0.27,0.62,0.620.76,0.23,0.56,0.80.74,0.32,0.57,1.120.81,0.36,0.57,0.650.8,0.2,0.57,0.910.77,0.21,0.54,0.880.85,0.36,0.61,1.160.88,0.41,0.65,0.860.95,0.3,0.74,1.021,0.47,0.77,1.311.03,0.44,0.82,1.291.06,0.47,0.86,1.251.13,0.45,0.98,1.211.04,0.59,0.92,1.51.13,0.79,1.03,1.490.87,0.7,0.87,1.290.99,0.77,0.97,1.571.02,0.72,0.97,1.421.01,0.9,0.91,1.741.21,0.85,1.04,1.380.87,1.08,0.82,1.980.5,1.28,0.45,1.80.65,1.32,0.55,2.240.58,1.69,0.5,2.350.74,1.4,0.67,2.530.81,2.14,0.78,2.970.74,1.58,0.74,3.140.78,2.3,0.8,3.50.78,2.21,0.77,3.190.69,2.64,0.74,3.670.7,2.88,0.74,3.870.59,3.65,0.63,4.550.58,3.58,0.63,4.250.56,3.97,0.59,5.630.48,4.41,0.52,5.590.47,4.28,0.51,6.70.43,5.74,0.47,7.610.4,6.42,0.46,8.440.37,6.24,0.41,8.840.35,8,0.39,10.10.35,7.79,0.37,11.520.34,7.77,0.36,12.740.36,9.77,0.38,13.60.3,8.93,0.3,15.860.33,12.35,0.33,16.910.31,14.71,0.32,18.020.31,15.59,0.32,22.650.31,16.52,0.33,24.850.27,17.63,0.29,24.930.27,20.88,0.3,31.720.23,24.65,0.26,35.490.2,24.35,0.24,35.810.21,29.3,0.25,41.210.17,32.96,0.2,46.710.17,37.02,0.2,49.670.15,41.72,0.18,56.380.12,47.67,0.15,66.390.12,56.08,0.16,67.870.1,58.44,0.13,74.280.09,62.81,0.11,85.120.08,69.85,0.1,95.390.07,86.93,0.08,107.10.06,83.58,0.07,120.520.04,91.58,0.05,118.080.03,111.83,0.04,139.250.03,113.52,0.03,130.750.02,132.44,0.03,157.340.07,232.71,0.08,237.02]
%WR矩阵存放的是2005年城镇和农村女性总人口
WR=[3791447,4606484]
%WS矩阵按列存放城镇女性生育率,农村女性生育率
WS=[0.010.07
0.14 0.43
0.65 2.03
2.08 6.31
6.79 16.96
18.7344.18
31.4570.14
36.3476.53
52.0077.73
52.7473.13
46.3963.69
44.3754.54
39.5846.68
30.2141.40
25.3537.40
20.5332.17
16.8630.44
13.7523.78
10.7919.02
8.51 14.22
6.65 10.52
4.63 7.91
4.15 5.67
2.29 3.97
1.61 2.84
1.35 1.73
0.70 1.18
0.73 0.88
0.67 0.63
0.34 0.78
0.40 0.44
0.29 0.45
0.23 0.32
0.33 0.39
0.32 0.37 ]
WS(:,1)=1.7374*WS(:,1)
WS(:,2)=1.0889*WS(:,2)%分别对城镇农村的生育率修正
t=T-2005
%构造Leslie矩阵
leslie1=zeros(91,91)
leslie2=zeros(91,91)
leslie1(1,16:50)=WS(1:35,1)/1000
leslie2(1,16:50)=WS(1:35,2)/1000
for i=1:90
leslie1(i+1,i)=1-WBS(i,2)/1000
leslie2(i+1,i)=1-WBS(i,4)/1000
end
leslie1(91,91)=1-WBS(91,2)/1000
leslie2(91,91)=1-WBS(91,4)/1000
d10=WR(1)/0.49788*WBS(1:91,1)/100
d20=WR(2)/0.49168*WBS(1:91,3)/100
%求2005-T年的人口情况
a=100000000
for i=1:t
d1=leslie1*d10
d2=leslie2*d20
d=[d1,d2]
Z(i)=sum(sum(d))
Z(i)=Z(i)*2.18/0.013/a%化总人口以亿人为单位
%进行城镇化分析
d10=d(:,1)+sum(0.01*d,2)
d20=d(:,2)-sum(0.01*d,2)
%对未来人口分布的分析
laonian60(i,:)=sum(d(61:91,:))*2.18/0.013/a%60岁以上的老年人口
laonian65(i,:)=sum(d(66:91,:))*2.18/0.013/a%65岁以上的老年人口
l60b(i,:)=sum(laonian60(i,:))/Z(i)%60岁以上的老年人口占总人口的比例
l65b(i,:)=sum(laonian65(i,:))/Z(i)%65岁以上的老年人口占总人口的比例
yulin(i,:)=sum(d(16:50,:))*2.18/0.012/a%育龄妇女人口
f=sum(d,2)
fuyangbi(i,1)=(sum(f(1:15))+sum(f(66:91)))/sum(f(16:65))%人口抚养比
z(i,:)=sum(d)*2.18/0.012/a%城镇总人口、农村总人口
end
这个基本没什核帆皮么办改差法了。 即使有的软件可以恢复几天前的数据,但是也不一定轿启可信了。而且一般这类软件恢复的是某个磁盘的文件、不是某一个具体文件,你希望把一个磁盘都恢复到几天前的状态吗?第一个貌似是leslie矩阵第二个才是你说的灰色模型
第二个的信烂用法也很简单
把整个函数扔到谈坦掘M文件中
在主程序的command window中调用即可含核
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)