采纳的回答

Torsten
Torsten 2022-12-16
编辑:Torsten 2022-12-16
pr = 0.734;
n = 1.413e-5;
ts = 12;
l = 10;
w = 4;
k =0.02428;
V = 10:2:50;
To = 0:10;
for iv = 1:numel(V)
v = V(iv);
re = (v * 0.277778 * l) / n;
nu = (0.037 * re^0.8 - 871) * pr^0.333333;
h = (nu*k) / l;
%fprintf("\n\n(velocity : %f(km/h) )\t",v);
%fprintf(" (rynold : %f)\t",re);
%fprintf("(nusselt : %f)\t",nu);
%fprintf(" (h : %f(w/m^2*k))\n",h);
for ito = 1:numel(To)
to = To(ito);
if ts > to
q(iv,ito) = h * l * w * (ts-to);
else
q(iv,ito) = h * l * w * (to-ts);
end
%fprintf("\t\t\tthe heat loss from surface is : %f\n", q);
end
end
[V To] = ndgrid(V,To);
contourf(V,To,q)
surfc(V,To,q)
colorbar
or maybe
n = 1.413e-5;
ts = 12;
l = 10;
w = 4;
k = 0.02428;
v = (10:2:50).';
to = 0:10;
re = (v * 0.277778 * l) / n;
nu = (0.037 * re.^0.8 - 871) * pr^0.333333;
h = (nu*k) / l;
q = h .* l .* w .* abs(ts-to);
[V To] = ndgrid(v,to);
contourf(V,To,q)
surfc(V,To,q)
colorbar

2 个评论

It seems OP wants 3D contour. Perhaps surfc may be good option instead
Thank you very much.

请先登录,再进行评论。

更多回答(0 个)

类别

帮助中心File Exchange 中查找有关 Contour Plots 的更多信息

产品

标签

Community Treasure Hunt

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

Start Hunting!

Translated by