In a coal-fired power plant, operating on Carnot Cycle, it is possible to set any value for the
temperature of boiler in which heat is added to water at high temperature (T) and any value for
the temperature of condenser in which heat is rejected from steam at low temperature (TO), from
the following temperature list
T - [500 320 1000 775 385 670 845 1245 410 300 627 514)ⓇK
Being an operator of power plant you have to select T and Te from the above temperature list so
that power plant operates at its highest efficiency
Write a generalized MATLAB program to select two temperature values Th, and Te for above
condition, without using min and max built-in function
Print the maximum efficiency of cycle and the temperatures at which it occurs.
% List of possible temperatures
T = [500 320 1000 775 385 670 845 1245 410 300 627 514];
Th_best = T(1); % The best temperature of boiler
Te_best = T(1); % The best temperature of condenser
eff_best = 1 - Te_best/Th_best; % The best efficency
n = length(T);
for i=2:n
Th = T(i);
for j = 2:n
Te = T(j);
eff = 1 - Te / Th;
if eff > eff_best
eff_best = eff;
Th_best = Th;
Te_best = Te;
end
end
end
fprintf('The maximum efficency is %.1f%%\n', eff_best*100);
fprintf('at boiler temperature %dK and condenser temperature %dK\n', ...
Th_best, Te_best);
Comments
Leave a comment