2.1.3 First Order Irreversible Series Reactions 

Consider the first order series reactions[4](Image).  The governing equations for this reaction scheme can be written as 

 

= `+`(`-`(Typesetting:-delayDotProduct(`*`(k, `*`(`1`, `*`(C))), A, true))) 

                                                                                                                          (2.8)  

= `+`(`-`(Typesetting:-delayDotProduct(`*`(k, `*`(`1`, `*`(C))), A, true)), `-`(`*`(k, `*`(`2`, `*`(C, `*`(B)))))) 

 

where k1 and k2 are rate constants and the initial conditions are CA(0) = 1 mol/l, CB(0) = 0, and  CC(0) = 0.  The concentration of species C (CC(t)) at any time is given by the material balance: 

 

                                                        CC (t) = 1 mol/1 - CA(t) - CB(t)                                 (2.9)                     

   

A Maple procedure for solving equations subject to the initial conditions is presented below.  This procedure is useful for developing the correct coefficient matrix A to avoid “by hand” errors. 

 

Procedure 

1.    Start the Maple program with a 'restart' command to clear all variables. 

2.    Call Maple's linear algebra package by using the 'with(linalg)' command. 

3.    Call Maple's plotting package by using the 'with(plots)' command. 

4.    Use Maple to enter the governing equations. 

5.    Name the variable vars. 

6.    Name the right hand side of the equations eqs. 

7.    Next, use Maple to generate the coefficient matrix (A) using Maple's genmatrix command. 

8.    Store the initial conditions for the dependent variables in the vector Y0.  The first row of Y0 corresponds to the initial condition for the first dependent variable (CA).  The second row of Y0 corresponds to the initial condition for the second variable (CB). 

9.    Find the matrix exponential of A (i.e., exp(At)) as a function of the parameters (rate constants) and the independent variable (t) using the Maple command 'exponential(A,t)'.  Call this matrix mat. 

10.  Next, find the solution (sol) by multiplying mat by Y0 using Maple's 'evalm' command. 

11.  The first row of the sol vector corresponds to CA(t) and the second row corresponds to CB(t). 

12.  Note that the analytical solutions for CA and CB are obtained as functions of the parameters (rate constants) and the independent variable, t.  Lower case letters are used for these variables with k1 and k2 as parameters. 

13.  For a given set of rate constants, plot the concentration profiles. 

Example 2.1 Irreversible Series Reactions 

> restart:
 

> with(linalg):
 

> with(plots):
 

Enter the governing equations as follows: 

> eq[1]:=diff(C[A](t),t)=-k1*C[A](t);
 

diff(C[A](t), t) = `+`(`-`(`*`(k1, `*`(C[A](t))))) (1)
 

> eq[2]:=diff(C[B](t),t)=k1*C[A](t)-k2*C[B](t);
 

Store the variables in vars: 

diff(C[B](t), t) = `+`(`*`(k1, `*`(C[A](t))), `-`(`*`(k2, `*`(C[B](t))))) (2)
 

> vars:=[C[A](t),C[B](t)];
 

[C[A](t), C[B](t)] (3)
 

Next, store the right hand sides of equations 1 and 2 in eqs. 

> eqs:=[rhs(eq[1]),rhs(eq[2])];
 

[`+`(`-`(`*`(k1, `*`(C[A](t))))), `+`(`*`(k1, `*`(C[A](t))), `-`(`*`(k2, `*`(C[B](t)))))] (4)
 

Now use the 'genmatrix' Maple command to produce the coefficient matrix A. 

> A:=genmatrix(eqs,vars);
 

array( 1 .. 2, 1 .. 2, [( 1, 2 ) = 0, ( 2, 2 ) = `+`(`-`(k2)), ( 1, 1 ) = `+`(`-`(k1)), ( 2, 1 ) = k1 ] ) (5)
 

Specify the initial conditions. 

> Y0:=matrix(2,1,[1,0]);
 

array( 1 .. 2, 1 .. 1, [( 1, 1 ) = 1, ( 2, 1 ) = 0 ] ) (6)
 

Use Maple's 'exponential(A,t)' command to produce the exponential (At) matrix. 

> mat:=exponential(A,t);
 

array( 1 .. 2, 1 .. 2, [( 1, 2 ) = 0, ( 2, 2 ) = exp(`+`(`-`(`*`(k2, `*`(t))))), ( 1, 1 ) = exp(`+`(`-`(`*`(k1, `*`(t))))), ( 2, 1 ) = `+`(`-`(`/`(`*`(k1, `*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), ... (7)
 

Obtain the solution vector using Maple's 'evalm' command and matrix multiplication (&*). 

> sol:=evalm(mat&*Y0);
 

array( 1 .. 2, 1 .. 1, [( 1, 1 ) = exp(`+`(`-`(`*`(k1, `*`(t))))), ( 2, 1 ) = `+`(`-`(`/`(`*`(k1, `*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), exp(`+`(`-`(`*`(k1, `*`(t)))))))), `*`(`+`(`-`(k2), k1)))... (8)
 

The first row of 'sol' is the solution for the concentration of species A (CA) and the second row is for the concentration of species B (CB). 

> ca:=sol[1,1];
 

exp(`+`(`-`(`*`(k1, `*`(t))))) (9)
 

> cb:=sol[2,1];
 

`+`(`-`(`/`(`*`(k1, `*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), exp(`+`(`-`(`*`(k1, `*`(t)))))))), `*`(`+`(`-`(k2), k1))))) (10)
 

The concentration of species C is obtained from the material balance equation. 

> cc:=1-ca-cb;
 

`+`(1, `-`(exp(`+`(`-`(`*`(k1, `*`(t)))))), `/`(`*`(k1, `*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), exp(`+`(`-`(`*`(k1, `*`(t)))))))), `*`(`+`(`-`(k2), k1)))) (11)
 

Note that the concentrations of the species are obtained as functions of the rate constants (k1 and k2) and 

> pars:={k1=2,k2=1};
 

{k1 = 2, k2 = 1} (12)
 

Next, substitute these values for the rate constants into the concentrations store as CA, BB, and CC. 

> Ca:=subs(pars,ca);
 

exp(`+`(`-`(`*`(2, `*`(t))))) (13)
 

> Cb:=subs(pars,cb);
 

`+`(`*`(2, `*`(exp(`+`(`-`(t))))), `-`(`*`(2, `*`(exp(`+`(`-`(`*`(2, `*`(t))))))))) (14)
 

> Cc:=subs(pars,cc);
 

`+`(1, exp(`+`(`-`(`*`(2, `*`(t))))), `-`(`*`(2, `*`(exp(`+`(`-`(t))))))) (15)
 

Plot the concentration profiles for these values of the rate constants as shown in Figure Exp. 2.1.1. 

> p1:=plot(Ca,t=0..10,thickness=3,color=blue,labels=["t(min)","Concentration (mols/l)"],labeldirections=[horizontal, vertical],legend='C[A]'):
 

> p2:=plot(Cb,t=0..10,linestyle=1,thickness=3,labels=["t(min)","Concentration (mols/l)"],labeldirections=[horizontal, vertical],legend='C[B]'):
 

> p3:=plot(Cc,t=0..10,linestyle=1,thickness=3,color=green,labels=["t(min)","Concentration (mols/l)"],labeldirections=[horizontal, vertical],legend='C[C]'):
 

> p4:=textplot([6,.9,k1=2.0*Unit(min^(-1))]):
 

> p5:=textplot([6,.7,k2=1.0*Unit(min^(-1))]):
 

> display([p1,p2,p3,p4,p5],title="Figure Exp. 2.1.1 Concentrations of A, B, and C as functions of time.");
 

Plot_2d
 

 





 

 

 

> Ca:=subs(k1=1,ca);
 

exp(`+`(`-`(t))) (16)
 

> Cb:=subs(k1=1,cb);
 

`+`(`-`(`/`(`*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), exp(`+`(`-`(t))))), `*`(`+`(`-`(k2), 1))))) (17)
 

> `:=`(Cc, subs(k1 = 1, cc)); 1
 

`+`(1, `-`(exp(`+`(`-`(t)))), `/`(`*`(`+`(`-`(exp(`+`(`-`(`*`(k2, `*`(t)))))), exp(`+`(`-`(t))))), `*`(`+`(`-`(k2), 1)))) (18)
 

Next, the 'limit' command is applied  for proc (`#msub(mi(:               

> Cb:=limit(Cb,k2=1);
 

`/`(`*`(t), `*`(exp(t))) (19)
 

> Cc:=limit(Cc,k2=1);
 

`/`(`*`(`+`(exp(t), `-`(1), `-`(t))), `*`(exp(t))) (20)
 

We can use these results to plot the concentration profiles for the case when k 

> p1:=plot(Ca,t=0..10,thickness=3,color=blue,labels=["t(min)","Concentration (mol/l)"],labeldirections=[horizontal, vertical],legend='C[B]'):
 

> p2:=plot(Cb,t=0..10,linestyle=1,thickness=3,color=red,labels=["t(min)","Concentration (mol/l)"],labeldirections=[horizontal, vertical],legend='C[B]'):
 

> p3:=plot(Cc,t=0..10,linestyle=1,thickness=3,color=green,labels=["t(min)","Concentration (mol/l)"],labeldirections=[horizontal, vertical],legend='C[C]'):
 

> p4:=textplot([6,.8,(k1=1.0*Unit(min^(-1)))]):
 

> p5:=textplot([6,.6,(k2=1.0*Unit(min^(-1)))]):
 

> display([p1,p2,p3,p4,p5],title="Figure Exp. 2.1.2 Concentrations of A, B, and C as functions of time.");
 

Plot_2d
 

We can solve for the time at which B is at its maximum by differentiating cb with respect to t: 

> Eqmax:=diff(cb,t);
 

`+`(`-`(`/`(`*`(k1, `*`(`+`(`*`(k2, `*`(exp(`+`(`-`(`*`(k2, `*`(t))))))), `-`(`*`(k1, `*`(exp(`+`(`-`(`*`(k1, `*`(t))))))))))), `*`(`+`(`-`(k2), k1))))) (21)
 

Next solve 'eqmax' to find the time at which cb is at a maximum in terms of the rate constants `and`(`#msub(mi( 

> tmax:=solve(Eqmax,t);
 

`+`(`-`(`/`(`*`(ln(`/`(`*`(k2), `*`(k1)))), `*`(`+`(`-`(k2), k1))))) (22)
 

Substitute this value for time into the concentration equation for B(cb(t)) to find the maximum value of Cb as a function of the rate constants  

> cbmax:=subs(t=tmax,cb);
 

`+`(`-`(`/`(`*`(k1, `*`(`+`(`-`(exp(`/`(`*`(k2, `*`(ln(`/`(`*`(k2), `*`(k1))))), `*`(`+`(`-`(k2), k1))))), exp(`/`(`*`(k1, `*`(ln(`/`(`*`(k2), `*`(k1))))), `*`(`+`(`-`(k2), k1))))))), `*`(`+`(`-`(k2),... (23)
 

The equation for 'cbmax' can be simplified further by using Maple's 'simplify' command. 

> cbmax:=simplify(cbmax);
 

`/`(`*`(k1, `*`(`+`(`^`(`/`(`*`(k2), `*`(k1)), `/`(`*`(k2), `*`(`+`(`-`(k2), k1)))), `-`(`^`(`/`(`*`(k2), `*`(k1)), `/`(`*`(k1), `*`(`+`(`-`(k2), k1)))))))), `*`(`+`(`-`(k2), k1))) (24)
 

A maximum for the concentration of B(cbmax) for the special case of `#msub(mi( 

> limit(cbmax, k2 = k1); 1
 

exp(-1) (25)
 

The time needed for the concentration of B to reach a maximum, for the case when k= k can be found as 

> limit(tmax,k2=k1);
 

`/`(1, `*`(k1)) (26)
 

Note that when k1 = k2, 'cbmax' is independent of the rate constants, the time taken to reach this maximum value e-1 is inversely proportional to the rate constant k1.