Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Sourav

ROLL NO. 20112069


EXPERIMENT -3
Objective-
Estimation of Molar Volume and compressibility factor for Redlich Kwong.

Problem statement-
Calculate the molar volume of saturated liquid water and saturated water vapour at 100
°C and 101.325 kPa using Redlich-Kwong equations of state. For water Tc = 647.1 K, Pc =
220.55 bar and w = 0.345.

Theory-
The molar volume of both the saturated vapour and saturated liquid can be calculated
using cubic equation of state. The cubic equations of state can have three real roots or
one real root and two complex roots.
When there is only one real root, then only one phase exists-liquid or vapour-and when
three real roots exist, then two there are two phases.
Then, smallest root is molar volume of saturated liquid, and the largest root is molar
volume of saturated vapour. The intermediate roof is of no physical significance.
To determine molar volume of liquid phase, the starting value taken is V=b. To determine
𝑅𝑇
molar volume of vapor phase, the starting value is taken as V = .
𝑃
𝑅𝑇 𝑎
The Van-der Waal’s equation of state is 𝑃=
𝑉−𝑏
=
𝑉2
.
The cubic form of Redlich-Kwong equation of state is given by
𝑅𝑇 2 𝑏𝑅𝑇 𝑎 𝑎𝑏
𝑉3 − ( ) 𝑉 − (𝑏 2 + − )𝑉 − = 0.
𝑃 𝑃 √𝑇𝑃 √𝑇𝑃
Where,
𝑅 2 𝑇𝑐 2.5 𝑅𝑇𝑐
𝑎 = 0.42748 and 𝑏 = 0.08664
𝑃𝑐 𝑃𝑐
Let us define a function as,
𝑅𝑇 𝑏𝑅𝑇 𝑎 𝑎𝑏
𝑓 = 𝑉 3 − ( ) 𝑉 2 − (𝑏 2 + − )𝑉 −
𝑃 𝑃 √𝑇𝑃 √𝑇𝑃
At the given temperature and pressure and given critical properties of the substance, the
only unknown in this equation is the molar volume V. The derivative of the function f
with respect to the molar volume is given as
𝑅𝑇 2 𝑏𝑅𝑇 𝑎
𝑓 ′ = 3𝑉 2 − 2 ( ) 𝑉 − (𝑏 + − )𝑉
𝑃 𝑃 √𝑇𝑃

A value of molar volume is assumed. At the assumed molar volume, the value of the
function f and its derivative f’ are determined and the new molar volume is determined
using Newton's method
𝑓
𝑉 𝑛+1 = 𝑉 𝑛 −
𝑓′

Thereafter, the new molar volume becomes the old molar volume, and f and f’ are
determined again at this molar volume. The procedure is repeated dill there is a very
small change between the new and old molar volume.

Code-
#include <iostream>
#include <math.h>
# define E 0.001
using namespace std;

double func (double P, double V, double R, double T, double a, double b)


{
double T1=pow(T,0.5);
double fx = V*V*V - ((R*T*V*V)/P) - ((b*b) + ((b*R*T1)/P) - (a/(T1*P))) *V - ((a*b)/(T1*P));
return fx;
}
double deriv (double P, double V, double R, double T, double a, double b)
{
double T1=pow(T,0.5);
double f1x = (3*V*V)-((2*R*T*V)/P)-(b*b+(b*R*T1)/P)-(a/(T1*P));
return f1x;
}
double Valueofa (double R, double Pc, double Tc)
{
double T2= pow(Tc,2.5);
double a= ((0.42748*R*R*T2)/Pc);
cout<<"Value of a = "<<a<<endl;
return a;
}
double Valueofb (double R, double Pc, double Tc)
{
double b = (0.08664*R*Tc)/Pc;
cout<<"value of b = "<< b<<endl;
return b;
}
int main()
{

double P ,T, Pc,Tc;

cout<<"value of temperature in kelvin= ";

cin>>T; cout<<endl;

cout<<"value of pressure in Pascal= ";

cin>>P; cout<<endl;

cout<<"value of critical temperature in kelvin= ";

cin>>Tc; cout<<endl;

cout<<"value of critical pressure in Pascal= ";

cin>>Pc; cout<<endl;
double R = 8.314;

double a = Valueofa (R,Pc,Tc);

double b = Valueofb (R,Pc,Tc);

double vliquid =b;

double vvapour=(R*T)/P;

// For Saturated liquid

double h1 = func(P,vliquid,R,T,a,b)/deriv(P,vliquid,R,T,a,b);

while(h1>=E)
{
h1= func(P, vliquid,R,T,a,b)/deriv(P,vliquid,R,T,a,b);
vliquid = vliquid -h1;
}
// For Saturated Vapor
double h2 = func(P,vvapour,R,T,a,b)/deriv(P,vvapour,R,T,a,b);
while(h2>=E)
{
h2= func(P, vvapour,R,T,a,b)/deriv(P,vvapour,R,T,a,b);
vvapour = vvapour -h2;
}
cout<<"Volume of saturated liquid by Redlich–Kwong equation is "<<vliquid<<"m^3/mol
"<<endl;
cout<<"Volume of saturated Vapour by Redlich–Kwong equation is "<<vvapour<<"m^3/mol
"<<endl;
return 0;
}
OUTPUT

You might also like