Unrecognized function or variable

I am trying to solve for T2 when the equation is equal to zero but it doesn't work, can someone help please?
function assignment8
Hreaction=-802310;
T1=25+275.15;
T2=solve(-Hreaction-(integral(@(T)cpCO2(T),T2,T1)-2*integral(@(T)cpH2Og(T),T1,T2)-0.6*integral(@(T)cpCO2(T),T2,T1)==0)); %J/mol
return
function cp=cpH2Og(T)
% Ideal-gas heat capacity (J/(molK)) for H2O with T in K % Source: GVR
% Appendix 3
a=3.40471e1;
b=-9.65064e-3;
c=3.2998e-5;
d=-2.04467e-8;
e=4.30228e-12;
cp=a+b*T+c*T.^2+d*T.^3+e*T.^4;
return
function cp=cpCO2(T)
% Ideal-gas capacity (J/(molK)) for CO2 with T in K % Source: GVR
% Appendix 3
a=1.90223e1;
b=7.96291e-2;
c=-7.37067e-5;
d=3.74572e-6;
e=-8.13304e-12;
cp=a+b*(T)+c*(T).^2+d*(T).^3+e*T.^4;
return
function cp=cpO2(T)
% Ideal-gas capacity (J/(molK)) for CO2 with T in K % Source: GVR
% Appendix 3
a=2.98832e1;
b=-1.13842e-2;
c=4.33779e-5;
d=-3.70082e-8;
e=1.01006e-11;
cp=a+b*(T)+c*(T).^2+d*(T).^3+e*T.^4;
return

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Operators and Elementary Operations 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by