Professional Documents
Culture Documents
Departament of Mathematics, Federal University of Gois, Av. Lamartine P. Avelar, 1120, Catalo, GO
ZIP CODE 75704-020, Brazil
Laboratory of Modeling, Simulation, Control and Optimization of Process, School of Chemical Engineering,
3
Federal University of Uberlndia, Av. Joo Naves de vila, 2121, Uberlndia, MG, ZIP CODE 38400-902, Brazil
1
kvtborges@gmail.com, 2fslobato@feq.ufu.br, 3vsteffen@mecanica.ufu.br
1. Abstract
This paper presents both the modeling and optimal design of an auto-thermal ammonia synthesis reactor. The main objective of the
optimal design of an auto-thermal ammonia synthesis reactor is the estimation of the optimal length of the reactor for different top
temperatures with the constraints of energy and mass balance of reaction and feed gas temperature and mass flow rate of nitrogen for
ammonia production. Ammonia production depends on the temperature of the feeding gas at the top of the reactor (top temperature),
the partial pressures of the reactants and the reactor length. The optimal problem requires the maximization of an objective function
subject to a number of equality constraints involving the solution of coupled differential equations. To solve this optimization
problem, the Gravitational Search Algorithm is used. This evolutionary algorithm is based on the Newtonian gravity and the laws of
motion. The preliminary results are compared with other approaches available and indicate that the proposed methodology
characterizes a promising alternative for dealing with this type of problem.
2. Keywords: auto-thermal ammonia synthesis reactor, Gravitational Search Algorithm, optimal design.
3. Introduction
The ammonia synthesis system is an important chemical process used in the manufacture of fertilizers, chemicals, explosives, fibers,
plastics, refrigeration, pharmaceuticals, pulp, paper, mining, metallurgy, and cleaning. It is produced from the exothermic reversible
reaction of hydrogen and nitrogen (N2+3H2NH3-92 KJ/mol) at high temperature and high pressures in the existence of a catalyst
[1-3]. Due to the high pressure used, more electric power is needed to drive the compressor, and makes more stringent the
requirements to be met by the plant. The wall of the reactor has special design and it needs certain alloys to withstand these higher
pressures. The feed gas temperature Tf, reacting gas temperature Tg, nitrogen flow rate NN2, they are all functions of the reactor length
and they are related to the optimization of the ammonia reactor [1-7].
In the literature, many works approaching the modeling, simulation and optimization of an auto-thermal ammonia synthesis reactor
can be found. Murase [1] used the maximum principle to design a variable heat transfer coefficient ammonia synthesis reactor.
Annable [6] compared the performance of an auto-thermal ammonia synthesis reactor with the maximum yield that could be obtained
if one had direct control of the temperature profile. Dyson [7] considered the general problem of determining the heat transfer
coefficient versus length function that would maximize the yield of auto-thermal reactor. Edgar and Himmelblau [2] used the
Lasdon's generalized reduced-gradient (LGRG) method to arrive at an optimal reactor length corresponding to a particular reactor top
temperature of 694 K; however, they ignored a term mentioned in the Murase's formulation [1], pertaining to the cost of ammonia
already present in the feed gas in the expression of the objective function. Also the expressions of the partial pressures of nitrogen,
hydrogen, and ammonia, used to simulate the temperature and flow rate profiles across the length of the reactor were not correct.
Upreti and Deb [3] presented an optimal procedure of an ammonia synthesis reactor by using genetic algorithm. They used the
correct objective function and correct stoichiometric expression of the partial pressures of N2, H2, NH3. The authors used simple GA
in combination with Gear package of NAG library subroutine, D02EBF, for the optimization of the ammonia synthesis reactor. They
obtained mass flow rate of nitrogen, feed gas temperature and reaction gas temperature at every 0.01 m of a 10 m reactor length.
Moreover there is a contradiction in the temperatures and gas flow rate profiles obtained. They reported the profiles that were not
smooth as those found in earlier literature. Also, they reported reverse reaction condition at the top temperature of 664K, which was
not found in the previous literature. Babu and Angira [4] and Babu et al. [5] used a correct objective function and correct
stoichometeric expression of pressures of N2, H2, NH3 but there is a contradiction in the temperatures and gas flow rate profiles that
they obtained. Hence, our research effort is dedicated to improve the formulation of the problem and also the computation performed.
Recently, Yusup et al [8] and Ksasy et al. [9] presented corrections in the model (stoichometeric expression, energy balance) and also
in the simulation algorithm used, thus demonstrating that the results previously obtained do not represent the operation optimal
condition.
Traditionally, the solution of optimization problems has been obtained by using deterministic approaches (using information about
the gradient of the objective function and constraint functions). Recently, a new non-deterministic approach has been proposed by
Rashedi [10], the so-called Gravitational Search Algorithm (GSA), as motivated by the gravitational law and the laws of motion. This
approach was applied successfully in solving various nonlinear optimization problems [10-12]. The obtained results confirm the high
performance and efficiently of the proposed method. GSA has a flexible and well-balanced mechanism to enhance exploration and
exploitation abilities [12]. In the literature, various other applications can be found, such as mathematical function optimization [10],
multi-objective optimization with ranking ordering operator [13], comparative study involving the GSA and the PSO (particle swarm
optimization) [14], applications in economic dispatch problems with valve-point effects [15], and a hybrid approach involving GSA
and neural networks to solve the Wessinger equation [16], to cite only a few.
In the present contribution the GSA is used for the optimal design of an auto-thermal ammonia synthesis reactor. Consequently, the
goal is the estimation of the optimal length of the reactor for different top temperatures with the constraints of energy and mass
balance of reaction and feed gas temperature and mass flow rate of nitrogen for ammonia production. The results obtained by using
the present methodology are compared with other optimization strategies. This work is organized as follows. The process description
and the mathematical formulation are presented in section 3. A review of the GSA is presented in section 5. The results and
discussion are both described in Section 6. Finally, the conclusions and suggestions for future work conclude the paper.
4. Auto-Thermal Ammonia Synthesis Reactor
Figure 1 shows the schematic diagram of the ammonia reactor studied. The feed gas with nitrogen (21.75 mole %), hydrogen (62.25
mole %), ammonia (5 mole %), methane (4 mole %), and argon (4 mole %) enters the bottom of the reactor and is preheated by the
counter-current flowing reaction gas before reversing its flow to undergo reversible exothermic reaction in the catalyst basket where
ammonia is produced. The reacted gas that consists of unconverted nitrogen and hydrogen, ammonia and inert will react with the
entering feed gas before leaving at the bottom of the reactor.
421 oC
Tube wall
Heat Flow
Q
Catalyst
Zone
Cooling
Zone
x
Reacting
Gas
Feed
Gas
Heat Exchanger
Product gas
(NH3 17-22%)
Feed gas
(200-350 atm)
(
)
( 3.45663 10 + 1.98365 10 x )
0.5
(1)
It is clear from the above expression that the objective function depends on four variables: the reactor length x, the proportion of
nitrogen NN2, the reacting gas temperature Tg, and the feed gas temperature Tf, for a given top temperature T0. The model below can
be derived by using the mass and energy balance [8,9]
dT f
dx
dTg
dx
US1
(Tg T f
WC pf
( H ) S
US1
(Tg T f ) + WC 2
WC pg
pg
(2)
dN N 2
dx
(3)
p N p1H.52
pNH
= f a k1 2
k2 1.53
dx
p
pH 2
NH 3
dN N 2
(4)
20800
k1 = 1.79954 104 exp
RTg
(5)
47400
k2 = 2.5714 1016 exp
RTg
(6)
pN 2 =
286 N N 2
(7)
2.598 N N 20 + 2 N N2
pH 2 = 3 p N 2
pNH3 =
(8)
286 2.23 N N 20 2 N N2
(9)
2.598 N N 20 + 2 N N 2
(10)
where U is the overall heat transfer coefficient (500 kcal/m2hK); S1 is the surface area of cooling tubes per unit length of reactor (10
m); W is the total mass flow rate (26400 kg/h); Cpf is the heat capacity of feed gas (0.707 kcal/kgK); H is the heat of reaction (26000 kcal/kg mole of N2); S2 is the cross-sectional area of the catalyst zone (0.78 m2); -dNN2/dx is the reaction rate (kg moles of
N2/hm3); Cpg is the heat capacity of the reacting gas (0.719 kcal/kgK); fa is the catalyst activity (1); pN2 , pH2 and pNH3 are the partial
pressures of N2, H2 and NH3, respectively; k1 and k2 are the rate constants; R is the ideal gas constant (1.987 kcal/(kg molK); and T0 is
the reference temperature (K). The boundary conditions are: Tf(x=0)=T0, Tg(x=0)=Tf, NN2(x=0)=701.2 kmol/m2h.
5. Gravitational Search Algorithm
Gravitational Search Algorithm (GSA) is a new meta-heuristic optimization algorithm motivated by the Newtons laws of gravity
and motion as proposed by Rashedi in 2007 [10]. According to this algorithm, agents are considered as objects and their performance
is measured by their masses. Every object attracts every other object with gravitational force, as showed in Fig. 2.
M4
M1
F12
F14
a1
F13
M2
F1
M3
(11)
(12)
(13)
j{1,..,N }
j{1,..,N }
where fitj(t) is the fitness of the jth agent at the time t, best(t) and worst(t) are the best (minimum) and worst (maximum) fitnesses of
all agents.
5.3. Compute the Gravitational Constant (G(t))
In this step, the gravitational constant at time t (G(t)) is computed as follows.
G ( t ) = G0 exp
T
(14)
where G0 is the initial value of the gravitational constant chosen randomly, is a constant, t is the current epoch and T is the total
iteration number.
5.4. Update the Gravitational and Inertial Masses
In this step, the gravitational and inertial masses are updated as follows.
mg i ( t ) =
fiti ( t ) worst ( t )
(15)
mg i ( t )
(16)
best ( t ) worst ( t )
Mg i ( t ) =
mg j ( t )
j =1
Fi d ( t ) =
rand j Fijd ( t )
(17)
jkbest j i
where randj is a random number between interval [0,1] and kbest is the set of first K agents with the best fitness value and the biggest
mass. The force acting on the ith mass (Mi(t)) from the jth mass (Mj(t)) at the specific t time is described according to the gravitational
theory as follows.
Fijd ( t ) = G ( t )
M i (t ) M j (t )
Rij ( t ) +
( x (t ) x (t ))
d
j
d
i
(18)
where Rij(t) is the Euclidian distance between ith and jth agents ( x dj ( t ) xid ( t ) ) and is the small constant.
2
aid ( t ) =
Fi d ( t )
Mgid ( t )
(19)
vid ( t + 1) = randi v dj ( t ) + a dj ( t )
(20)
(21)
5.8. Repeat
In this step, steps from 5.2 to 5.7 are repeated until the iterations reach the proposed criteria. In the final iteration, the algorithm
returns the position of the corresponding agent at specified dimensions. This value is the global solution of the optimization problem.
The flowchart below, Fig. 3, shows the various steps of GSA.
Define the GSA parameters (population size,
generation number, etc.)
Create an initial population, randomly distributed
throughout the design space
Evaluate the objective function and take it as a
fitness measure of each agent
Compute G(t), best(t), worst(t) of the population
Calculate Mi(t) and ai(t) for each agent
Update vi(t) and xi(t)
Stopping criterion
Results
The design variables considered: 0.01 m x 10 m, 0 NN2 3220 kmol/m2h, 400 Tf 800 K.
To solve the optimization problem the following heuristics are used: Genetic Algorithm (GA) parameters [17]: population
size (25), type of selection (normal geometric in the range [0 0.08]), type of crossover Arithmetic, 2), type of mutation
(non-uniform [2 100 3]); Differential Evolution (DE) parameters [18]: population size (25), perturbation rate and crossover
probability both equal to 0.8 and DE/rand/1/bin strategy; Particle Swarm Optimization (PS) parameters [19]: population
size (25), maximum velocity (100), upper limits (2.0), and a linearly decreasing inertia weight starting at 0.7 and ending at
0.4 was used; Simulated Annealing (SA) parameters [20]: initial design (generated randomly in the design space), initial
temperature (5.0), cooling rate (0.75), number of temperatures (20), number of times the procedure is repeated before the
temperature is reduced (25), and tolerance (10-6) and Gravitational Search Algorithm parameters [10]: population size (25),
constant (1).
Stopping criterion: homogeneity of population (difference between the best and worst individual smaller than 10-6) or until
the maximum number of objective function evaluations equal to 5000.
Each algorithm was run 20 times by using 20 different seeds for the random generation of the initial population.
To solve the differential equation system, the Runge Kutta algorithm is used.
Table 1 present the results obtained by GSA and by other evolutionary strategies for comparison purposes. In this table it is possible
to observe that all evolutionary strategies considered in the present contribution (ED, GA, PSO, SA and GSA) are able to estimate
satisfactorily the reactor length when compared with the results obtained by other references. In addition, the optimal solution
obtained by using GSA led to a similar number of objective function evaluations (Neval) as found by other techniques, thus
characterizing an interesting alternative to solve the problem addressed in this paper.
It is evident from the figure that the profiles are smooth and there are no spikes as reported by Upreti and Deb [3]. According to these
authors the reverse reaction predominated the forward reaction at the top temperature of 664 K. In the present study, however, there
is no such a trend observed in the profiles obtained (for which Upreti and Deb [3]) gave a very good physical explanation). This same
conclusion can be observed in [4]. In addition, Upreti and Deb [3] reported that the three differential equations become unstable at
the top temperature of 706 K. However, using the above proposed numerical method, it was found that the equations are not unstable
even at a top temperature as high as 800K. It is important to observe that the modeling considered by Edgar et al. [2] and by Upreti
and Deb [3] are not consistent, as proved by Babu and Angira [4] and by Yusup et al. [8] and by Ksasy et al. [9].
Figures 4 to 6 present the reactor profiles by considering various top temperatures (694, 706 and 800 K).
Table 1. Results obtained considering various evolutionary strategies.
Tf (K)
Tg (K)
x (m)
NN2 (kmol/m2h)
T0 (K)
Objective Function
(Top
(Feed Gas
(Reacting Gas
(Reactor
(Nitrogen Flow
Algorithm
(million $/year)
Temperature)
Temperature)
Temperature)
Rate)
Length)
[1]
694
5.18
LGRG [2]
694
2.58
1.29106
GA [3]
694
5.33
4.23106
NAG [4]
694
6.58
5.00106
SQP [8]
694
400
629.65
6.695
490.84
5.015106
694
400
629.65
6.695
490.84
5.015106
ED
706
400
630.06
6.776
490.64
5.018106
800
400
631.28
9.515
490.96
4.991106
694
400
629.65
6.695
490.84
5.015106
GA
706
400
630.06
6.776
490.64
5.017106
800
400
631.28
9.515
490.96
4.991106
694
400
629.65
6.695
490.84
5.015106
PSO
706
400
630.06
6.776
490.64
5.017106
800
400
631.28
9.515
490.95
4.991106
694
400
629.65
6.695
490.84
5.015106
SA
706
400
630.06
6.776
490.64
5.018106
800
400
631.28
9.515
490.95
4.990106
694
400
629.65
6.695
490.84
5.015106
GSA
706
400
630.06
6.776
490.64
5.018106
800
400
631.28
9.515
490.96
4.991106
NAG Numerical Algorithms Group and SQP Sequential Quadratic Programming.
800
750
700
Tf
650
Tg
600
NN
550
500
450
850
400
350
0
3
4
5
Reactor Lengh (m)
Figure 4. Reactor profiles (mass flow rate and temperatures) at a top temperature of 664 K.
Neval
2650
2600
2700
3150
3300
2900
2580
2720
2910
2950
3010
2890
2440
2420
2610
850
800
750
700
Tf
650
Tg
600
NN
550
500
450
400
350
0
3
4
5
Reactor Length (m)
Figure 5. Reactor profiles (mass flow rate and temperatures) at a top temperature of 706 K.
900
850
800
750
700
650
600
550
500
Tf
450
400
NN
Tg
2
3
4
5
6
7
Reactor Length (m)
10
Figure 6. Reactor profiles (mass flow rate and temperatures) at a top temperature of 800 K.
7. Conclusion
In the present work the Gravitational Search Algorithm was used to determine the optimal design of an auto-thermal ammonia
synthesis reactor through the estimation of the optimal length by taking into account constraints of energy and mass balance of
reaction and feed gas temperature and mass flow rate of nitrogen for ammonia production. A number of test cases, considering
different top temperatures, were studied. It is possible to conclude that the methodology proposed led to good results at a low
computation cost (an acceptable number of objective function evaluations) as compared with other evolutionary strategies.
Further research work will be focused on the extension of the proposed approach to the multi-objective optimization context.
8. Acknowledgements
The authors acknowledge the financial support provided by FAPEMIG, Fundao de Amparo Pesquisa de Minas Gerais. Dr.
Steffen Jr is thankful to the financial support provided by FAPEMIG and CNPq through the INCT-EIE.
9. References
1. Murase A., Roberts H. L., and Converse A. O. Optimal Thermal Design of an Auto-thermal Ammonia Synthesis Reactor,
Industrial & Engineering Chemistry Research, 9, 503-513, 1970.
2. Edgar T. F., Himmelblau D. M. and Lasdon L. S. Optimization of Chemical Processes. New York, McGraw-Hill, 2001.
3. Upreti S. R. and Deb K. Optimal Design of an Ammonia Synthesis Reactor using Genetic Algorithms Computers & Chemical
Engineering, 21, 87-92, 1997.
4. Babu B. V. and Angira R., Optimal Design of an Auto-thermal Ammonia Synthesis Reactor, Computers and Chemical
Engineering Journal, 2005.
5. Babu B.V., Angira R. and Nilekar A., Optimal Design of an Auto-Thermal Ammonia Synthesis Reactor Using Differential
Evolution, Proceedings of The Eighth World Multi-Conference on Systemics, Cybernetics and Informatics (SCI-2004), Orlando,