function mcbt(p,n)
% mcbt - McCabe-Thiele Diagram for compounds defined with setnme
% function mcbt(p,n)
% p is the total pressure in kPa
% n is one minus the number of points on the curve.
% Example:
%    start301a and start301b
%    specify two compounds as toluene and benzene
%    mcbt(200,25)
global cnms
xs=0:(1/n):1;
for k=1:n+1
    [t,ys(k)]=bubpt2(p,xs(k));
end
plot(xs,ys)
c=sprintf('Vapor Liquid Equilibrium at %g kPa',p);
title(c)
xlabel(['Liquid mol fraction ',cnms(1,:)])
ylabel('Vapor mol fraction')
text(0.3,0.05,['Second Compound: ',cnms(2,:)])
hold on
plot([0 1],[0 1])
grid
axis('square')
hold off
