|
楼主 |
发表于 2006-12-12 00:12
|
显示全部楼层
谢谢!不过仍有不解
谢谢!
我把它改了,因为它还要和复杂一些的程序结合,不过对改后的程序进行计算,算出来的结果既然都不是实数,这不知道为什么,用excel迭代可以算出这个方程组的答案阿!请大虾帮小弟想想办法。
Ta=298.15;Tg=298.15;
Vw=5;
cps=3000;
cpf=1007;
Hc=200;
Hm=4;%collector 中间距离地面高度
R=122;Acoll=pi*R^2;
Rc=10.16;Ac=pi*Rc^2;
Ub2=0.117; %Ub=6.5; //1/(1/Ub+1/hg1) hg1 9.857956412/地面一层/注意:不能混淆
o=0.0000000567;%σ,Stefan-Boltzmann常数
g=9.81;
h1=24.13074832;
Vs=0.8;%可变
Hs=0.5;%可变
Ts0=353.15;%给定的,80
ep=0.94;%ep=εp
ec=0.9;%ec=εp
r=0.009753;
ra=0.0065;%ra=r∞
ms=2*pi*R*Hs*Vs;
ff=0.76-0.118*Vw+0.0066*power(Vw,2);
hw=2.8+3*Vw;
Tf=305.12;Ts=323;Tp=316.6;Tc=299.05;Vout=3.803;%事先给定的,25
for i=1:100
p=(1.1614-0.00353*(Tf-300));%p=ρ
u=(1.846+0.00472*(Tf-300))*0.00001;%u=μ
k=(0.0263+0.000074*(Tf-300));
Tout=2*Tf-Ta;
pout=(1.1614-0.00353*(Tout-300));%p=ρ
mf=pout*Ac*Vout;
Vm=mf/(pi*R*Hm*p);%事先给定:以R/2的速度来表示
h2=(0.2106+0.0026*Vm*power(p*(Tp+Tf)/2/(u*g*(Tp-Tf)),1/3))/power(u*(Tp+Tf)/2/(g*(Tp-Tf)*cpf*k*k*p*p),1/3);
h3=(0.2106+0.0026*Vm*power(p*(Tc+Tf)/2/(u*g*(Tf-Tc)),1/3))/power(u*(Tc+Tf)/2/(g*(Tf-Tc)*cpf*k*k*p*p),1/3);
h31=(0.2106+0.0026*Vm*power(p*(Tc+Tf)/2/(u*g*(Tf-Tc)),1/3));
h32=power(u*(Tc+Tf)/2/(g*(Tf-Tc)*cpf*k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