这个迭代错了吗?运行不了。

for tcl=(0:0.1:45)
if 2.38*(tcl-12.2)^0.25>=12.1*0.1^0.5
hc=2.38*(tcl-12.2)^0.25
else
hc=2.38*0.1^0.5
end
Tcl=(61.97-0.3485*10^(-8)*(tcl+273)^4+0.088*hc*12.2)/(1+0.88*hc)
while abs(Tcl-tcl)>=0.01
tcl=Tcl
if 2.38*(tcl-12.2)^0.25>=12.1*0.1^0.5
hc=2.38*(tcl-12.2)^0.25
else
hc=12.1*0.1^0.5
end
Tcl=(61.97-0.3485*10^(-8)*(tcl+273)^4+0.088*hc*12.2)/(1+0.88*hc)
end
Tcl

 Accepted Answer

tajid
tajid on 22 Nov 2022

0 votes

for tcl=(0:0.1:45)
if 2.38*(tcl-12.2)^0.25>=12.1*0.1^0.5
hc=2.38*(tcl-12.2)^0.25
else
hc=2.38*0.1^0.5
end
end
Tcl=(61.97-0.3485*10^(-8)*(tcl+273)^4+0.088*hc*12.2)/(1+0.88*hc)
while abs(Tcl-tcl)>=0.01
tcl=Tcl
if 2.38*(tcl-12.2)^0.25>=12.1*0.1^0.5
hc=2.38*(tcl-12.2)^0.25
else
hc=12.1*0.1^0.5
end
Tcl=(61.97-0.3485*10^(-8)*(tcl+273)^4+0.088*hc*12.2)/(1+0.88*hc)
end
Tcl

More Answers (0)

Categories

Find more on MATLAB 快速入门 in Help Center and File Exchange

Tags

Asked:

on 22 Nov 2022

Answered:

on 22 Nov 2022

Community Treasure Hunt

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

Start Hunting!