matlab运行结果每次都不一样,请问是怎么回事 15
p1=[0.820.790.80.840.820.810.820.790.80.84;0.770.660.650.760.810.880.610.740.860.63;0...
p1=[0.82 0.79 0.8 0.84 0.82 0.81 0.82 0.79 0.8 0.84;0.77 0.66 0.65 0.76 0.81 0.88 0.61 0.74 0.86 0.63;0.17 0.18 0.22 0.2 0.21 0.19 0.18 0.2 0.18 0.21];
t1=[1150 1121 1131 1190 1165 1150 1198 1123 1159 1170;23.5 23.6 28.9 24.9 27.8 23.7 23.1 29.7 23.1 25.7;8.31 8.93 9.27 8.29 9.38 9.16 7.37 9.94 9.87 7.05];
p=p1*10;
t=t1/1000;
w1 =[-0.7051 -0.0241 -4.7339;2.2988 -0.6850 -1.9896;2.3258 -0.7526 -0.9992;-3.8001 -0.2423 2.6024;-2.8089 0.5635 -2.4033];
w2 =[0.5225 0.5984 -0.2497 0.9389 0.1698;0.7675 -0.7318 -0.2530 -0.3159 0.0474;-0.0852 -0.8694 -0.0320 -0.4946 -0.6732];
b1 =[15.1771 -9.8670 -11.8173 27.4138 24.3063];
b2 =[-0.0272 -0.0079 0.6864]
net=newff(minmax(p),[12,3],{'tansig','purelin'},'traingda');
net.trainParam.show=100;
net.trainParam.lr=0.3;
net.trainParam.mc=0.5;
net.trainParam.epochs=500;
net.trainParam.goal=1e-3;
net=init(net);
[net,tr]=train(net,p,t);
figure(1);
a=sim(net,p);
[m,b,r]=postreg(a,t);
plot(p,t,p,a,'o');
这个程序运行结果每次都不一样,不清楚是什么原因,各位高手帮忙解决一下。 展开
t1=[1150 1121 1131 1190 1165 1150 1198 1123 1159 1170;23.5 23.6 28.9 24.9 27.8 23.7 23.1 29.7 23.1 25.7;8.31 8.93 9.27 8.29 9.38 9.16 7.37 9.94 9.87 7.05];
p=p1*10;
t=t1/1000;
w1 =[-0.7051 -0.0241 -4.7339;2.2988 -0.6850 -1.9896;2.3258 -0.7526 -0.9992;-3.8001 -0.2423 2.6024;-2.8089 0.5635 -2.4033];
w2 =[0.5225 0.5984 -0.2497 0.9389 0.1698;0.7675 -0.7318 -0.2530 -0.3159 0.0474;-0.0852 -0.8694 -0.0320 -0.4946 -0.6732];
b1 =[15.1771 -9.8670 -11.8173 27.4138 24.3063];
b2 =[-0.0272 -0.0079 0.6864]
net=newff(minmax(p),[12,3],{'tansig','purelin'},'traingda');
net.trainParam.show=100;
net.trainParam.lr=0.3;
net.trainParam.mc=0.5;
net.trainParam.epochs=500;
net.trainParam.goal=1e-3;
net=init(net);
[net,tr]=train(net,p,t);
figure(1);
a=sim(net,p);
[m,b,r]=postreg(a,t);
plot(p,t,p,a,'o');
这个程序运行结果每次都不一样,不清楚是什么原因,各位高手帮忙解决一下。 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询