indices on the right incompatible
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
% am trying to run this my program with the function script and the input
% data given below. please have a look to know what am doing wrong
%%
function[PB,Ybub]=PB_VLE_NRTL(x,C,T,BIP)
% this is a function that calculates the bubble point using the wilson
% activity coeefficient model.
c=length(x);
for i=1:c
Psi=exp((C(i,1))+(C(i,2)/T)+(C(i,3)*log(T))+(C(i,4)*T^C(i,5)));
[gamma,~]=ACTIVITY_NRTL(BIP,alpha,T,x);
PB=sum(Psi.*x*gamma);
Ybub=Psi.*gamma/PB;
end
%% problem 2
% in order to determine the state of aggregation of the system
T=353.15;
P=101325;
i=1:2;
x=[0.5 0.5];
BIP=[196.250 386.133];
C(i)=[88.134 -8498.6 -9.0766 8.330e18 6];
C(i)=[153.23 -10055 -19.488 1.6426e5 2];
3 Commenti
madhan ravi
il 17 Mag 2019
Modificato: madhan ravi
il 17 Mag 2019
Probably you’re not aware of how to call a function.
Google : How to a call a function? MATLAB
Risposte (0)
Vedere anche
Categorie
Scopri di più su Environment and Settings in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!