Documentos de Académico
Documentos de Profesional
Documentos de Cultura
SCHOOL OF ENGINEERING
KATHMANDU UNIVERSITY
IN CHEMICAL ENGINEERING
ROLL: 06
Introduction
(K1)
2C6H6(B) C12H10(D) + H2(H)
(K2)
C6H6(B) C12H10(D) + C18H14(T) + H2(H)
Purpose of study:
1. Study the effect of varying space time on the fractional conversions X1 and X2
2. Study the value of composition over a wide range value of space time.
3. Show that the composition of Diphenyl passes through a maximum.
4. Plotting r1 and r2 vs. space time.
5. Study the effects of temperature.
Method:
PD PH 8440 )
r1 = -k 1 (P2B- ) where, k1=1.469*107 e(
K eq1 Tr
PB P H 8440 )
r2=−k 2( ) where, k2=8.67*106 e(
K eq 2 Tr
At steady-state conditions, the mass balance design equations for the ideal tubular reactor apply.
These equations may be expressed as:
d X1
V F=−∫ =τ
r1
d X2
V F=−∫ =τ
r2
Where X1 is the fractional conversion of benzene by reaction (1), X2 is the fractional conversion
of benzene by the reaction (2) and τ is the space time.
In differential form:
d X1
=−r 1
dτ
d X2
=−r 2
dτ
Expressing PB, PH, PT, PD in terms of X1 and X2
PB= (1-X1-X2)
X
PD= 1 −X 2
2
X1
PH= + X ❑2
2
PT=X2
Ptot=PB+PD+PH+PT
Substituting into the mass balance:
X1 X1
)( )
d X1
dτ ( 2
=k 1 ( 1−X 1−X 2 ) −
2 (
−X 2
K eq1
2
+X2
)
d X2
( X
=k 1 ( 1−X 1 −X 2)( 1 − X 2)−
(X )
1
( X2) 2 + X2
)
dτ 2 K eq2
Coding:
The coding for the given problem involves the use of various libraries and function such as
numpy, scipy, pylab and etc.
#for problem 1
X0=array([x10,x20])
def dX_dt(X,t=0):
return array([k1*((1-X[0]-X[1])**2-((X[0]/2-X[1])*(X[0]/2+X[1])/keq1)),
k2*((1-X[0]-X[1])*(X[0]/2-X[1])-((X[0]/2+X[1])*X[1])/keq2)])
print (dX_dt)
X,infodict=integrate.odeint(dX_dt, X0, t, full_output=True)
print(infodict['message'])
x1,x2=X.T
print(x1,x2)
plt.plot(t,x1,label="x1")
plt.plot(t,x2,label="x2")
plt.legend(loc="best")
plt.xlabel("Time")
plt.ylabel("Conversion")
#for problem 2
PB=(1-x1-x2)
PD=x1/2-x2
PH=x1/2+x2
PT=x2
Ptot=PB+PD+PH+PT
yb=PB/Ptot
yd=PD/Ptot
yh=PH/Ptot
yt=PT/Ptot
print(yb)
print(yd)
print(yt)
plt.figure()
plt.plot(t,yd,label="diphenyl")
plt.plot(t,yb,label="benzene")
plt.plot(t,yt,label="triphenyl")
plt.legend(loc="best")
plt.xlabel("Time")
plt.ylabel("Composition yb,yd,yt")
#for probelem 4
def AB(x,t=0):
A=x[0]
B=x[1]
T=1033
k1=1.496E7*exp(-15200/T)
k2=8.67E6*exp(-15200/T)
keq1=0.312
keq2=0.48
dAdt=k1*((1-A-B)**2-((A/2-B)*(A/2+B))/keq1)
dBdt=k2*((1-A-B)*(A/2-B)-(B*(A/2+B))/keq2)
return(dAdt,dBdt)
x0=[0,1]
t=np.linspace(0,1,50)
x=integrate.odeint(AB,x0,t,)
A=x[:,1]
B=x[:,0]
print(A)
plt.figure()
plt.plot(t,A,'g',label="r1")
plt.legend(loc="best")
plt.xlabel("Time")
plt.ylabel("rate")
print(B)
plt.plot(t,B,label="r2")
plt.legend(loc="best")
plt.xlabel("Time")
plt.ylabel("rate")
#for problem 5
tr=np.linspace(298,1033,20)
def dx1_dt(X):
k1=1.496e7*exp(-15200/X)
k2=8.670e6*exp(-15200/X)
return k1*((1-x1-x2)**2-((x1/2-x2)*(x1/2+x2)/keq1))
r1=-(1.496e7*exp(-15200/tr))*((1-x1-x2)**2-(((x1/2)-x2)*((x1/2)+x2)/keq1))
print(r1)
plt.figure()
plt.plot(tr,r1)
plt.xlabel("Temperature")
plt.ylabel("rate")
Discussion:
After successfully modeling the problem and coding the information in python programming,
several study were conducted regarding the effect of space time on the rate, conversion and
composition and effect of temperature on the rate of reaction. Library function used in each
section of the programming and its mechanism are discussed separately section-wise.
For problem 1:
Soon as the reaction proceeds the conversion of reactant species into corresponding product
starts. With the expense of time, more amount of reactant species is converted into the product.
At τ =0, the conversion value in both of the reaction is zero, and this value increases to a
maximum of 1. The range for space time is set using linspace(start, end, no. of interval) library
function. For space time in range 0≤ τ ≤1, following graph is obtained:
dX_dt is a function which stores and prints the result as array. X [*] denotes each array for
different conversion value for two different reaction.
For problem 2:
p yi
The composition( y i= ) of species being a function of conversion varies on varying the space
p
time. The equation for partial pressure is expressed in terms of conversion. A graph by plotting
between compositions of species over a range of space time is obtained as:
For problem 3:
In this part, we want to see if the composition of YB passes through a maximum value. Looking
at the graph shown above in Figure 3. , we can conclude that the composition of YB passes
through a maximum value of around 0.2
For problem 4:
The rate of a reaction is given as the negative derivative of conversion for the reaction with
respect to time.
For problem 5:
Now, we desire to see the effect of varying the temperature upon the rate of reaction. Since the
equilibrium constant for a reaction is a function of temperature. Thus, the rate of a reaction being
a function of equilibrium constant varies with varying in the temperature. The value of
temperature is taken in a range of 25-1500 using linspace() function and the rate of reaction over
this range of temperature is studied with the help of a graph. We have a relation relating the rate
of reaction with temperature.
Figure 5. rate of reaction vs. temperature
The library pylab is used as 'plt' to plot the graph of rate or conversion of each species vs. time or
temperature.