Introduction

Recycling of the flare gas

In the world, approximately 150–170 m3 of flare gas is burnt or wasted annually which values around 30.6 billion $ and equivalent to 25% of the gas consumption in the USA, or 30% of gas consumption in the European Union [1,2,3]. Gas flaring in different industries is regarded as an integral process and a safety measure in the emergency circumstances, in which a huge volume of the waste gas is exhausted and conducted depressurization [4, 5]. Nevertheless, in the many industries, owing to improper function of existing units such as cooling units, this current is flowing continuously. Today, this process has led a lot of the environmental problems including emission of greenhouse gases (CH4 and CO2) into the environment and other pollutants involving SOx and NOx which not only induces air pollution and global warming, but also can result in dangerous diseases for various sorts of living species [2, 4, 6,7,8,9]. Also, from an economic prospective, this gas consists of different constituents similar to the natural gas which is a clean and high energy value source of energy [1].

According to the aforementioned economic and environmental issues, attempts are being made with the aim of reducing the amount of flare gas and its utilization in the various industries [2, 5, 10]. Actually, this gas mixture cannot be recycled directly since it contains unsuitable constituents that if recycled to the system can produce undesirable products and decrease the process efficiency [11]. In addition, it cannot be used in the production of chemical materials such as piped natural gas (PNG), liquefied natural gas (LPG), methanol, and ammonia owing to the fact that it is required to eliminate inert gases and separate gas species. In this regard, the various gas separation methods can be applied including cryogenic, membrane, separation with solvents/sorbents which are processed in one stage or multiple stages by considering the type of gas mixture [10, 12]. In this regard, Khanipoor et al. have evaluated separation of purge gas, which is burnt as the flare gas, in methanol synthesis unit through membrane process and its recovery to the steam methane reforming unit and methanol synthesis reactor. In addition, Agahzamin et al. have evaluated the recovery of the purge gas to the auto-thermal reformer (ATR). In both studies, results show that by the recovery of the purge gas not only CO2 emission into the environment is reduced, but also synthesis gas and methanol production enhance very well in terms of quality and quantity, and it is economical as well [13, 14]. A large portion of flare gas contains CO, H2 and CO2 which can be used in the production of methanol. One of the best methods to separate these species is separation with solvents/sorbents [12], which is explained in the following sections.

Separation with sorbents (adsorption)

In the industry, adsorption method has developed remarkably since the basis of this method is to select the proper adsorbent and currently it is observed that production of these materials is enhancing noticeably [15, 16]. This method of separation is mainly divided into pressure swing adsorption (PSA), temperature swing adsorption (TSA), vacuum swing adsorption (VSA) and electric swing adsorption (ESA) method [17]. The PSA method is a commercial one which has been studied comprehensively [18, 19] and it is used widely in the purification and separation of H2 from the flare gas as well as steam methane reforming (SMR) processes [20, 21]. Taking into account the first objective of this study, which is the separation of H2 from the flare gas through PSA process, investigations have been allocated to the evaluation of a gas mixture adsorption analogous to the initial flare gas on different adsorbents. Yang et al. have used a multi-layer bed of zeolite and activated carbon in the room temperature and the pressure of 1–8 atm to purify H2 from a gas mixture of CH4/H2/CO2/CO. In the study, H2 purity and recovery have reached 99.999 and 60%, respectively [22]. In the mixture of CH4/CO2/CO/H2/N2, the purification of H2 has been conducted through CuBTC adsorbent in a fixed-bed tower in four stages. Also, this adsorbent has compared to others and H2 purity has reached 99.9% [23]. A metal–organic framework, named UTSA-16, is used to eliminate CO2 and H2 purification from the gas mixture and in addition it has been compared to other adsorbents. In this regard, a four-bed PSA cycle for H2 purification from SMR flow is simulated and also this adsorbent is compared to Zeolite 5A and activated carbon BPL. The results show that Zeolite 5A has the highest adsorption rate while in the low pressure the isotherm slope is very sharp which has made the recovery process more difficult. Nevertheless, the activated carbon has the lowest adsorption capacity, but the regeneration process has performed more easily and the UTSA adsorbent has shown a behavior between the two mentioned ones. In this project, purity and recovery of H2 have reached 99.999 and 93–96%, respectively [24]. The performances of Zeolite CaX and 5A are compared in the separation of H2 from CO2/CO/CH4/N2 through the PSA method and by a simulation tool (PSASIM). The simulation results illustrate that with the pressure of 3 bar of the feed stream, the efficiency of CaX is higher than 5A to recover H2 with the aim of achieving purification of 99.7%. CaX is superior to 5A to eliminate N2 while CaX has lower operability to eliminate CO and CH4 [25]. Hajizadeh et al. [26] evaluated feasibility of three methods for FGR in a giant gas refinery in Iran. They studied liquefaction, LPG production and compression in their survey. They reported that the rate of return for liquefaction unit and LPG production unit is more than 200% for different scenarios and is higher than compression. In 2018, Shokroo applied a PSA pilot plant to simultaneously nitrogen, methane and ethane separation from a flare gas in a domestic industrial petrochemical unit [27]. His PSA unit consists of a 6-step cycle including steps as: pressurization with feed, adsorption, equalization to depressurization, blow down, purge and equalization to pressurization. The simulation results show that the designed system can produce nitrogen with the purity of 99.2%, recovery of 28.3% and productivity of 26.42 mol/(kgads h). These values are 19.59, 38.09, 6.5821 for methane and, also 40.74, 43.64, 3.9203 for ethane, respectively.

Separation with solvents (absorption)

This process is divided into chemical and physical methods [28, 29]. In the petroleum and chemical industries, chemical absorption through alkanolamines such as monoethanolamine (MEA), diethanolamine (DEA), diisopropanolamine (DIPA) and diglycolamine (DGA) has been used widely to separate or eliminate CO2 from the exhausted gas [29,30,31,32]. Amines have long been regarded as good candidates for the purpose of CO2 removal owing to high absorption capacity for CO2 and rapid reaction rates. Among the mentioned amines, MEA is one of the most suitable choices to absorb and recover CO2 [29]. According to the second objective in our investigation which is a separation of CO2 from the flare gas, evaluations are conducted in this regard. The practical processes are used to remove CO2 from the industrial gases and to reduce the emission of greenhouse gases. For this purpose, in mind, design and control of the MEA process are performed simultaneously as well as optimization of an economical process [33]. In the separation of CO2 through amines, specifically MEA, minimization of the energy consumption and improvement of the absorption efficiency have been investigated extensively [34]. A technical and economic method is presented to separate CO2 through the MEA process. Comparison between the cost of present and previous studies over economic and technical operability of the process illustrates that evaluation of this model is appropriate for the MEA process [35].

Methanol

Methanol is a simple molecule and a multifunctional chemical substance, which is produced generally from the natural gas [36]. Owing to methanol physical and chemical structures, it can be utilized as a clean source of energy, specifically as a suitable fuel for the automobile [37] due to its greater octane number than gasoline and also its easier transportation and storage [36]. It has a large variety of applications and it can be used as a solvent, raw chemical materials production such as formaldehyde and acetic acid in addition to the production of chemical intermediates such as dimethyl terephthalate (DMT) and methyl t-butyl [36, 38].

Considering the increase in energy cost and environmental issues, more attention has been paid to the methanol as an alternative source of energy owing to its specific characteristics. Methanol can be produced from CO, CO2 hydrogenation reactions and water gas shift (WGS) reaction as follows:

$${\text{CO}} + 2{\text{H}}_{2} \leftrightarrow {\text{CH}}_{3} {\text{OH}}\quad \Delta H_{298}^{^\circ } = - 90.55\;{\text{kJ}}/{\text{mol,}}$$
(1)
$${\text{CO}}_{2} + 3{\text{H}}_{2} \leftrightarrow {\text{CH}}_{3} {\text{OH}} + {\text{H}}_{2} {\text{O}}\quad \Delta H_{298}^{^\circ } = - 49.43\;{\text{kJ}}/{\text{mol,}}$$
(2)
$${\text{CO}}_{2} + {\text{H}}_{2} \leftrightarrow {\text{CO}} + {\text{H}}_{2} {\text{O}}\quad \Delta H_{298}^{^\circ } = + 41.12\;{\text{kJ}}/{\text{mol}} .$$
(3)

Reactions (1)–(3) are not independent in a way that one is a linear function of the other. In this study, rate expression is selected from Graf et al.’s investigation [39]. Reaction rate equations along with equilibrium rate constants [40] present sufficient information about methanol synthesis kinetics. Reaction rate equations over CuO/ZnO/Al2O3 catalysts are as follows:

$$R_{1} = \frac{{k_{1} \cdot K_{\text{CO}} }}{\Delta }\left[ {f_{\text{CO}} f_{{{\text{H}}_{2} }}^{{\frac{3}{2}}} - \frac{{f_{{{\text{CH}}_{3} {\text{OH}}}} }}{{K_{{{\text{p}}1}} \cdot f_{{{\text{H}}_{2} }}^{{\frac{1}{2}}} }}} \right],$$
(4)
$$R_{2} = \frac{{k_{2} \cdot K_{{{\text{CO}}_{2} }} }}{\Delta }\left[ {f_{{{\text{CO}}_{2} }} \cdot f_{{{\text{H}}_{2} }}^{{\frac{3}{2}}} - \frac{{f_{{{\text{CH}}_{3} {\text{OH}}}} \cdot f_{{{\text{H}}_{2} {\text{O}}}} }}{{K_{{{\text{p}}2}} \cdot f_{{{\text{H}}_{2} }}^{{\frac{3}{2}}} }}} \right],$$
(5)
$$R_{3} = \frac{{k_{3} \cdot K_{{{\text{CO}}_{2} }} }}{\Delta }\left[ {f_{{{\text{CO}}_{2} }} \cdot f_{{{\text{H}}_{2} }} - \frac{{f_{\text{CO}} \cdot f_{{{\text{H}}_{2} {\text{O}}}} }}{{K_{{{\text{p}}3}} }}} \right],$$
(6)
$$\Delta = \left[ {1 + K_{\text{CO}} \cdot f_{\text{CO}} + K_{{{\text{CO}}_{2} }} f_{{{\text{CO}}_{2} }} } \right]\left[ {f_{{{\text{H}}_{2} }}^{{\frac{1}{2}}} + \frac{{K_{{{\text{H}}_{2} {\text{O}}}} \cdot f_{{{\text{H}}_{2} {\text{O}}}} }}{{K_{{{\text{H}}_{2} }}^{{\frac{1}{2}}} }}} \right].$$
(7)

The rate constant, equilibrium constants, and adsorption constants are enlisted in Table 1, respectively.

Table 1 The rate, equilibrium, and adsorption/desorption constants of methanol synthesis reactions

Regarding dangers which are attributed to the gas burning as well as the probable advantages of valuable constituents recovery, firstly, the undesirable species in the flare gas of a methanol unit are separated. In this regard, H2 and CO2 recovery from the purge gas has been evaluated through a separation with sorbents/solvents, which is presented in two stages. In the first stage, according to the existing volume of H2 and also its easy separation through the PSA method, this method has been applied. In the second stage, CO2 is separated through a separation with sorbents/solvents. Then, methanol synthesis using CO2 is suggested and evaluated. For the mentioned goal, the required mathematics model along with its validation has been presented.

Process description

In this investigation, the purge gas stream of Zagros petrochemical company is evaluated, which contains dangerous species flowing to the torch. This gas stream with the flow rate of 910 kmol/h is mainly composed of CO2 and H2, which can be utilized in the methanol synthesis unit if CO2 and H2 have been recovered and returned to the unit after the undesirable products are removed. The purge gas stream, if burnt completely, can emit approximately 300 ton/day of CO2 into the environment. Also in the presence of O2 and high temperature, NOx can be produced and emitted into the environment since this stream contains nearly 10% N2.

Therefore, in dealing with the above environmental challenges, in this study, a sorbent/solvent separation process according to the previous studies is proposed, to reduce the amount of greenhouse gas emission as well as reusing CO2 and H2. The proposed process is composed of two stages including separation of H2 from the flare gas stream (stage 1) and then separation of CO2 from the mixture of CO2/CO/CH4/N2 (stage2). The whole separation process and methanol production by CO2 are depicted in Fig. 1.

Fig. 1
figure 1

The schematic diagram of proposed separation configuration and methanol process

As it was noted above, the goal in this project is to separate H2 and CO2 from the flare gas mixture. Firstly, regarding the volume of H2 in the stream, a two-bed system PSA process is applied. The simulated PSA process is a six-step process with the following sequence: (1) co-current feed pressurization (PR); (2) high-pressure adsorption (AD) step; (3) counter-current depressurizing pressure equalization (ED) step; (4) counter-current blow down (BD) step; (5) counter-current purge with a light product (PG) step; and (6) co-current pressurizing pressure equalization (EP) step.

The flow diagram of the PSA process is observed in Fig. 2. In each bed, two layers of activated carbon and zeolite 5A are placed to separate H2. The sequence time of the PSA process is also depicted in Table 2. Characteristics of the flare gas input feed stream to the PSA unit and the applied parameters for the simulation are tabulated in Tables 3 and 4, respectively.

Fig. 2
figure 2

The overall mechanism of PSA process

Table 2 Step sequence of the PSA process
Table 3 Characteristics of the flare gas input feed stream to the PSA unit [41]
Table 4 Parameters for simulation of PSA unit

The heavy species stream of the first stage is mainly composed of CO2, CO, CH4 and N2. Thus, in the second stage, CO2 separation from the mixture is analyzed with MEA solvent.

To explain the solvent separation process, in the first place, the gas stream is entered to the hollow fiber and the solvent is entered co-currently to the tube side. CO2 permeates to the solvent and then reacts. The retentate of this stage is composed of CH4, CO and N2. The rate equations for reaction between CO2 and MEA are as the following, and both equations are proportional to the concentrations with the first order:

$$R_{{{\text{CO}}_{2} {\text{-MEA}}}} = k_{{r{\text{-MEA}}}} \left[ {{\text{CO}}_{2} } \right]\left[ {\text{MEA}} \right],$$
(8)
$$R_{\text{MEA}} = 2k_{{r{\text{-MEA}}}} \left[ {{\text{co}}_{2} } \right]\left[ {\text{MEA}} \right].$$
(9)

Rate constants, kr, are presented in Table 5.

Table 5 Dimensions of the membrane contactor and model parameters

The overall mechanism of this process is shown in Fig. 3. Characteristics of the membrane, input feed stream and applied parameters for the simulation are enlisted in Table 5, respectively.

Fig. 3
figure 3

The overall mechanism of CO2 chemical absorption process

Modeling

In the separation with solvent, a heterogeneous steady-state two-dimensional model is used to predict the transfer of CO2 and its distribution in three parts of the tube, membrane and shell (according to Fig. 3). In the separation with the adsorbent (PSA) method, a heterogeneous one-dimensional unsteady-state model is used to predict the diffusion of different species into the adsorbent. In the methanol synthesis reactor, a developed heterogeneous one-dimensional model is applied to determine the concentration distribution and temperature for fluid and solid phases. These three models are simplified based on some of the fundamental presumptions.

Absorption process model (CO2–MEA)

Assumptions of this model are as follows:

  1. 1.

    The system is the steady state and the isothermal condition is estimated for that.

  2. 2.

    Ideal gas behavior is applied.

  3. 3.

    Henry’s law is applicable for the gas–liquid interface.

  4. 4.

    Fibers distribution is uniform in the shell side.

  5. 5.

    There is no axial diffusion, and mass transfer in the membrane is only taken place through radial diffusion.

  6. 6.

    Happel’s free surface theory is used to describe the gas velocity profile.

  7. 7.

    Gas and liquid flow are laminar.

  8. 8.

    CO2 in the liquid phase limits the reaction rate.

Tube side equations

According to the mentioned assumptions, continuity equation from the Fick’s law is presented for diffusion and reaction of component i in the tube side as follows:

$$D_{{i{\text{-tube}}}} \left[ {\frac{{\partial^{2} C_{{i{\text{-tube}}}} }}{{\partial r^{2} }} + \frac{1}{r}\frac{{\partial C_{{i{\text{-tube}}}} }}{\partial r} + \frac{{\partial^{2} C_{{i{\text{-tube}}}} }}{{\partial z^{2} }}} \right] + R_{i} = V_{{z{\text{-tube}}}} \frac{{\partial C_{{i{\text{-tube}}}} }}{\partial z},$$
(10)

where Vi-tube, Di-tube, Ci-tube and Ri are the axial velocity, diffusion coefficient, concentration and reaction rate of component i in the tube side, respectively.

If it is considered that the velocity distribution obeys the Newtonian laminar flow in the tube side, it is as follows [46, 47]:

$$V_{{z{\text{-tube}}}} = 2u_{1} \left[ {1 - \left( {\frac{r}{{r_{1} }}} \right)^{2} } \right].$$
(11)

In the above equation, u1 and r1 are the gas velocity in the tube side and the inner tube radius, respectively.

Membrane equations

The continuity equation for CO2 diffusion into the membrane regarding the non-wetting condition in the membrane is as follows:

$$D_{{i{\text{-membrane}}}} \left[ {\frac{{\partial^{2} C_{{i{\text{-membrane}}}} }}{{\partial r^{2} }} + \frac{1}{r}\frac{{\partial C_{{i{\text{-membrane}}}} }}{\partial r} + \frac{{\partial^{2} C_{{i{\text{-membrane}}}} }}{{\partial z^{2} }}} \right] = 0,$$
(12)

Di-membrane is the diffusion coefficient of component i in the membrane.

Shell side equation

The continuity equation in the shell side (where gas is flowing and there is no reaction) to estimate the diffusion flux of component i is presented as follows:

$$V_{{z{\text{-shell}}}} \frac{{\partial C_{{i{\text{-shell}}}} }}{\partial z} = D_{{i{\text{-shell}}}} \left[ {\frac{{\partial^{2} C_{{i{\text{-shell}}}} }}{{\partial r^{2} }} + \frac{1}{r}\frac{{\partial C_{{i{\text{-shell}}}} }}{\partial r} + \frac{{\partial^{2} C_{{i{\text{-shell}}}} }}{{\partial z^{2} }}} \right],$$
(13)

where Vz-shell and Di-shell are the axial velocity and diffusion coefficient of component i in the shell side, respectively. According to Happel’s free surface theory, the velocity profile in the shell side is as follows [48, 49]:

$$V_{{z{\text{-shell}}}} = 2u\left[ {1 - \left( {\frac{{r_{2} }}{{r_{3} }}} \right)^{2} } \right] \times \left[ {\frac{{\left( {\frac{{r_{2} }}{{r_{3} }}} \right)^{2} - \left( {\frac{{r_{2} }}{{r_{3} }}} \right)^{2} + 2\ln \left( {\frac{{r_{2} }}{r}} \right)}}{{3 + \left( {\frac{{r_{2} }}{{r_{3} }}} \right)^{4} - 4\left( {\frac{{r_{2} }}{{r_{3} }}} \right)^{2} + 4\ln \left( {\frac{{r_{2} }}{{r_{3} }}} \right)}}} \right].$$
(14)

In the above equation, u and r2 are the average gas velocity in the shell side and the outer tube radius, respectively. Also, the relation between r1 and r2 is defined through Eq. (15) [50]:

$$r_{3} = r_{2} \sqrt {1/\left( {1 - \varphi } \right)} ,$$
(15)

where \(\varphi\) is the volume fraction of the void space and it can be calculated through the following Eq. (16):

$$\varphi = 1 - \frac{{nr_{2}^{2} }}{{r_{3}^{2} }},$$
(16)

where n and r3 are the fiber number and the inner shell radius, respectively.

PSA process model

The assumptions that used for the PSA model are as follows:

  1. 1.

    Ideal gas behavior is used.

  2. 2.

    The total pressure during the adsorption and desorption steps remains constant with the time.

  3. 3.

    The total pressure changes non-linearly versus time during pressurization, pressure equalization to pressurization and blow down steps.

  4. 4.

    The flow pattern is assumed to be axially displaced plug-flow model.

  5. 5.

    Equilibrium relations for H2, CO2, CO, CH4 and N2 are stated by the multi-component Langmuir–Freundlich isotherm.

  6. 6.

    Linear driving force (LDF) relation is used for the rate of mass transfer.

According to the above statements, the dynamic behavior of the PSA process is presented in the basis of mass, energy and momentum balances as of the following.

Mass balance

The mass balance of ith component for the gas phase in the adsorption bed is presented through Eq. (17) [51, 52]:

$$\begin{aligned} & - D_{\text{L}} \frac{{\partial^{2} y_{i} }}{{\partial z^{2} }} + y_{i} \cdot \frac{\partial u}{\partial z} + u \cdot \left( {\frac{{\partial y_{i} }}{\partial z} + y_{i} \cdot \left( {\frac{1}{P} \cdot \frac{\partial P}{\partial z} - \frac{1}{T} \cdot \frac{\partial T}{\partial z}} \right)} \right) + \frac{{\partial y_{i} }}{\partial t} \\ & \quad + y_{i} \left( {\frac{1}{P} \cdot \frac{\partial P}{\partial t} - \frac{1}{T} \cdot \frac{\partial T}{\partial t}} \right) + \left( {\frac{{\rho_{\text{p}} \cdot R \cdot T}}{P}} \right) \cdot \left( {\frac{1 - \varepsilon }{\varepsilon }} \right) \cdot \frac{{\partial \bar{q}_{i} }}{\partial t} = 0, \\ \end{aligned}$$
(17)

where \(\partial \bar{q}_{i}\) in the above equations is described through LDF relation as follows:

$$\frac{{\partial \bar{q}_{i} }}{\partial t} = \omega_{i} \left( {\dot{q}_{i} - \bar{q}_{i} } \right).$$
(18)

In this equation, \(\omega_{i}\) is the LDF coefficient of ith component and \(\dot{q}_{i}\) is the concentration of ith component in the solid phase. The equilibrium concentration of ith adsorbed component in the solid phase relates to its gas phase concentration through the following Langmuir–Freundlich isotherm:

$$\dot{q}_{i} = \frac{{q_{m,i} \cdot B_{i} \cdot P_{i}^{ni} }}{{1 + \mathop \sum \nolimits_{j = 1}^{N} B_{j} \cdot P_{j}^{nj} }},$$
(19)

where \(q_{m,i}\) is the saturation concentration in the solid phase and defined as follows:

$$q_{m,i} = k_{1,i} + k_{2,i} T.$$
(20)

Also, Bi and ni are determined through the following relations:

$$B_{i} = k_{3,i} \cdot \exp \left( {k_{4,i} /T} \right),$$
(21)
$$n_{i} = k_{5,i} + \frac{{k_{6,i} }}{T},$$
(22)

where k1,i, k2,i, k3,i, k4,i, k5,i, and k6,i are the parameters of Langmuir–Freundlich equation and T is the system temperature.

According to relation (23), \(\omega_{i}\) is considered as a function of ith component concentration [53]

$$\omega_{i} = C_{i} .P_{r}^{0.5} .\left( {1 + B_{i} .P_{i} } \right)^{2}$$
(23)

In this equation, Ci is the diffusion time constant for the component i, Pi is the partial pressure of component i, and Bi is the parameter of Langmuir–Freundlich equation. The Langmuir–Freundlich parameters and the LDF Coefficients for Activated Carbon and Zeolite 5A are listed in Table 6. Table 7 shows the characteristics of the adsorbents.

Table 6 Langmuir–Freundlich parameters and LDF coefficients for activated carbon and zeolite 5A
Table 7 Characteristics of the adsorbents

Energy balance

The energy balance according to the mentioned assumptions is as follows [54, 55]:

$$\begin{aligned} & - K_{\text{L}} \frac{{\partial^{2} T}}{{\partial z^{2} }} + \varepsilon \cdot \rho_{\text{g}} \cdot c_{{{\text{p}},{\text{g}}}} \cdot \left( {u\frac{\partial T}{\partial z} + T\frac{\partial u}{\partial z}} \right) + \left( {\varepsilon_{\text{t}} \cdot \rho_{\text{g}} \cdot c_{{{\text{p}},{\text{g}}}} + \rho_{\text{B}} \cdot c_{{{\text{p}},{\text{s}}}} } \right) \cdot \frac{\partial T}{\partial t} \\ & \quad - \rho_{\text{B}} \cdot \mathop \sum \limits_{i = 1}^{N} \left( {\frac{{\partial \bar{q}_{i} }}{\partial t} \cdot \left( { - \Delta \bar{H}_{i} } \right)} \right) + \frac{{2h_{i} }}{{R_{{{\text{B}},{\text{i}}}} }}\left( {T - T_{\text{W}} } \right) = 0. \\ \end{aligned}$$
(24)

In this equation, KL is the axial thermal dispersion coefficient, ρg is the gas phase density, ρB is the bulk density, cp,g is the heat capacity of the gas, \(c_{{{\text{p}},{\text{s}}}}\) is the heat capacity of the solid phase (adsorbent), \(\Delta \bar{H}_{i}\) is the enthalpy change of adsorption for component i, εt is the total porosity coefficient, hi is the heat transfer coefficient in the adsorption bed, RB,i is the internal bed radius and Tw is the bed wall temperature.

The energy equation for heat transfer from the bed wall is as follows:

$$\frac{{\partial T_{\text{w}} }}{\partial t} = \left[ {\frac{{2\pi \cdot R_{{{\text{B}},{\text{i}}}} \cdot h_{i} }}{{\rho_{\text{w}} \cdot c_{{{\text{p}} \cdot {\text{w}}}} \cdot A_{\text{w}} }}} \right] \cdot \left( {T - T_{\text{w}} } \right) - \left[ {\frac{{2\pi \cdot R_{{{\text{B}},{\text{o}}}} \cdot h_{\text{o}} }}{{\rho_{\text{w}} \cdot c_{{{\text{p}} \cdot {\text{w}}}} \cdot A_{\text{w}} }}} \right] \cdot \left( {T_{\text{w}} - T_{\text{atm}} } \right).$$
(25)

In this equation Aw is the cross-sectional area of the bed, which is defined as follows:

$$A_{\text{w}} = \pi \cdot \left( {R_{{{\text{B}},{\text{o}}}}^{2} - R_{{{\text{B}},{\text{i}}}}^{2} } \right).$$
(26)

Momentum equation

The continuity equation or overall mass transfer of the gas phase is as follows:

$$\begin{aligned} & \frac{\partial P}{\partial t} - D_{\text{L}} \frac{{\partial^{2} P}}{{\partial z^{2} }} + P\frac{\partial u}{\partial z} + u\frac{\partial P}{\partial z} + PT \cdot \left( { - D_{\text{L}} \frac{{\partial^{2} }}{{\partial z^{2} }}\left( {\frac{1}{T}} \right) + \frac{\partial }{\partial t}\left( {\frac{1}{T}} \right) + u\frac{\partial }{\partial z}\left( {\frac{1}{T}} \right)} \right) \\ & \quad - z \cdot D_{\text{L}} \cdot T \cdot \frac{\partial P}{\partial z} \cdot \frac{\partial }{\partial z}\left( {\frac{1}{T}} \right) + \rho_{\text{p}} \cdot R \cdot t \cdot \left( {\frac{1 - \varepsilon }{\varepsilon }} \right) \cdot \mathop \sum \limits_{i = 1}^{N} \frac{{\partial \bar{q}_{i} }}{\partial t} = 0, \\ \end{aligned}$$
(27)

where the total pressure drop along the bed is calculated using the Ergun equation, and the total pressure drop versus time is estimated through a quadratic equation [56, 57].

$$- \frac{{{\text{d}}P}}{{{\text{d}}z}} = a \cdot \mu \cdot u + b \cdot \rho \cdot u \cdot \left| u \right|,$$
(28)
$$a = \frac{150}{{4R_{\text{p}}^{2} }} \cdot \frac{{\left( {1 - \varepsilon } \right)^{2} }}{{\varepsilon^{2} }};\quad b = 1.75\frac{{\left( {1 - \varepsilon } \right)}}{{2R_{\text{p}} \varepsilon }}$$
(29)
$$P\left( t \right) = A \cdot t^{2} + B \cdot t + C.$$
(30)

where A, B and C in Eq. (30) are calculated based on the initial and final pressures of each PSA step.

According to the PSA process, boundary conditions for each step are enlisted in Table 8.

Table 8 Boundary conditions for each stage of PSA unit

Methanol synthesis reactor model

This model is proposed through some assumptions which are summarized below:

  1. 1.

    Steady-state conditions are applied.

  2. 2.

    Ideal gas behavior is used.

  3. 3.

    Axial pressure drop is negligible and is calculated in the reaction side of the methanol reactor by the Ergun equation.

  4. 4.

    The flow pattern is described through axially dispersed plug-flow model.

  5. 5.

    In the methanol synthesis reactor, bed porosity is considered axial and radial and remains constant.

  6. 6.

    The reaction is considered over the catalyst bed, and reaction in the gas phase can be ignored.

  7. 7.

    The temperature gradient in the catalyst is ignored owing to the small size of the catalyst.

Mass and energy balances in the catalyst phase

$$a_{\text{v}} c_{j} k_{{{\text{g}},i}} \left( {y_{i}^{\text{g}} - y_{i}^{\text{s}} } \right) + \eta r_{i} \rho_{\text{b}} = 0,$$
(31)
$$a_{\text{v}} h_{\text{f}} \left( {T^{\text{g}} - T^{\text{s}} } \right) + \eta \rho_{\text{b}} \mathop \sum \limits_{i = 1}^{\text{NC}} r_{i} \left( { - {\Delta }H_{{{\text{f}},i}} } \right) = 0$$
(32)

where Ts and ysi are the surface temperature and mole fraction of component i in the solid phase, respectively. Tg and ygi are those in the fluid phase, and η is the effectiveness factor which could be obtained from the dusty gas model.

Mass and energy balances in the fluid phase

$$- \frac{{F_{\text{t}} }}{{A_{\text{c}} }}\frac{{{\text{d}}y_{i}^{\text{g}} }}{{{\text{d}}z}} + a_{\text{v}} c_{j} k_{{{\text{g}},i}} \left( {y_{i}^{\text{s}} - y_{i}^{\text{g}} } \right) - \varphi \frac{{J_{i} }}{{A_{\text{c}} }} = 0,$$
(33)
$${\text{d}}F_{\text{t}} = \mathop \sum \limits_{i = 1}^{\text{NC}} {\text{d}}F_{i} ,$$
(34)
$$\begin{aligned} & - \frac{{F_{\text{t}} \cdot C_{\text{p}}^{\text{g}} }}{{A_{\text{c}} }}\frac{{{\text{d}}T^{\text{g}} }}{{{\text{d}}z}} + a_{\text{v}} h_{\text{f}} \left( {T^{\text{s}} - T^{\text{g}} } \right) \pm \frac{{\pi D_{i} }}{{A_{\text{c}} }}U_{2 - 3} \left( {T_{3}^{\text{g}} - T_{2}^{\text{g}} } \right) \\ & \quad - \varphi \frac{{J_{i} }}{{A_{\text{c}} }}\mathop \smallint \limits_{{T^{\text{m}} }}^{{T^{\text{g}} }} C_{{{\text{p}},1}} {\text{d}}T \pm \frac{{\pi D_{i} }}{{A_{\text{c}} }}U_{2 - 1} \left( {T_{2}^{\text{g}} - T_{1}^{\text{g}} } \right) = 0. \\ \end{aligned}$$
(35)

Tg and \(y_{i}^{\text{g}}\) are the temperature and molar fraction of component i in the fluid phase, respectively. The energy Eq. (35) shows convectional heat transfer between the fluid and solid phases, and heat transfer between two sides of shell and tube.

Solution method

To simulate the separation with sorbents/solvents method and develop its mathematical model, a set of partial differential equations and algebraic equations are used. To solve the partial differential equations, firstly, the mentioned equations transformed into the algebraic equations through implicit finite difference scheme, and then in the PSA process the algebraic equations are solved through Newton–Raphson scheme for each given time. For the CO2–MEA process, the linearized algebraic equations in the radial direction that form a tridiagonal matrix are solved simultaneously by the Thomas algorithm. In the synthesis methanol reactor, Guess–Newton method is applied to solve the attained equations using finite difference approximation. In this regard, the reactor length is divided into 100 segments and the obtained results from each segment are used as the input condition for the next segment.

Base case

The first calculations are made on a reference case which is required to start the simulation and is followed by the evaluation of different parameters effects. Actually, this is called the base case. Operational conditions which are used for the PSA process in this study is based on Jee et al. [58] investigation, and in the second stage, that of the process of CO2–MEA is based on Marzouqi et al. [42] study, and that of methanol synthesis process is based on what is proposed in the industry (represented in Table 9).

Table 9 Characteristics of the methanol synthesis reactor and input feed stream to that [59]

Model validation

To validate the obtained results of numerical simulation, the results of the mathematical model are compared with the empirical data. In this regard, for the PSA process, the results of Jam’s H2 purification industrial unit are used [60]. Figure 4 illustrates H2 purity as a function of input feed flow rate to the PSA unit along with the industrial data. Besides, it can be observed that industrial results are in good agreement with that of the mathematical model and this confirmed in the results of other investigations [61, 62].

Fig. 4
figure 4

H2 purity as a function input feed flow rate

The validity of CO2–MEA process results is evaluated through the empirical study of Sujatha Karoort which is about CO2 separation from the mixture of CO2/N2 [63].

Figure 5 shows the CO2 concentration in the outlet liquid stream versus liquid flow rate for the model prediction results in this work as well as the empirical results from other projects. It is obviously observed that the proposed model is in good agreement with the empirical data.

Fig. 5
figure 5

The concentration of CO2 in the outlet liquid stream versus liquid flow rate

In addition, the validation of the results for the methanol synthesis reactor is performed using the empirical data from the industry. The obtained results from the proposed model and that of the plant are enlisted in Table 10. According to the presented error percentage, it can be understood that the difference between simulation results and empirical ones are reasonable. As a result, it can be concluded that in all the three cases, the simulation results are in good agreement with empirical ones.

Table 10 Validation of the mathematical model in the methanol synthesis reactor

Results

In this section, the results of simulation and mathematical modeling of the gas separation which is performed in two stages of absorption and adsorption are depicted. In addition, the simulation results of methanol synthesis from CO2 are presented.

H2 separation through adsorption method in the first stage

According to the simultaneous usage of two types of adsorbents, namely 5A and activated carbon, for the separation of hydrogen, the mole fraction of all existed components in flare gas against time on both activated carbon and 5A adsorbents has been plotted in Fig. 6a, b. In fact, Fig. 6 shows the breakthrough curves. The term “break-through” is originated from the response of initially cleaned bed per flow with a constant composition. As an initial condition, it is assumed that the adsorption bed is pressurized with a non-adsorptive gas. Regarding these two types of adsorbents, the adsorption capacity of components on two adsorbents can be determined. These two adsorbents have low adsorption capacity for hydrogen; hence, they are appropriate for implementing in hydrogen purification processes. It is worth mentioning that in prolonged time of the flare gas moving over the adsorption bed, activated carbon cannot remove all the carbon monoxide and carbon dioxide efficiently (because of the adsorption capacity of the adsorbents destroyed with along the time) and adsorption bed effluent will contain mentioned gases. Figure 7 shows the pressure variation in a six-stage 190-s cycle. In the first 30 s, considered as AD step, the pressure is constant. In the next 10 s which is known as ED step, bed pressure decreased from 8 to 4.5 bar. As a result of complete BD step in 55 s of the next stage, the bed faces an atmospheric pressure to be prepared for PG step. With the start of the PG step, the bed is maintained in this step for 30 s. Enhancement in pressure from 1 to 4.5 bar caused by an EP step in 10 s provides the situation for higher pressure increase to achieve adsorption pressure under PR step. Figure 8a, b presents variations in mole fraction of hydrogen and bed temperature during consecutive cycles on top of the beds, respectively. Sequential behavior of concentration, temperature and especially beds pressures is well presented in these figures. Due to the pressure variation of the bed during different adsorption process steps with the pressure swing, pressure curves are increasing and decreasing. These curves are ascending in PR and EP steps, while in BD and ED steps is falling. In both AD and PG steps, the pressure of the column will stay constant. As the beds are identical and perform similarly, the pressure curve is similar for each bed. Accordingly, hydrogen (volatile component) concentration increases on the top of the bed in high-pressure steps, while it is decreasing in low-pressure steps. It seems noteworthy that the adsorption process will reach a cyclic steady state (CSS) after several cycles. Hydrogen purity versus feed flow rate and purge-to-feed ration (P/F) of 0.1, 0.2 and 0.3 have been plotted in Fig. 9. As it is obvious from the figure, hydrogen purity diminishes in higher inlet flow rates. It is perceivable from the curves that lower P/F is desirable for lower flow rates while in higher flow rates; higher P/F is advisable. Hydrogen purity as a function of AD step pressure is depicted in Fig. 10. This figure illustrates that product purity increases by pressure rise and, subsequently, a more suitable product will be attained for methanol production. Based on the obtained results from this figure, the efficient hydrogen separation is possible in the pressures range of 6–8 bar. However, special attention should be devoted to the fact that the unit operating cost will escalate with pressure increment.

Fig. 6
figure 6

a Molar fraction of components on activated carbon adsorbent versus time. b Molar fraction of components on 5A adsorbent versus time

Fig. 7
figure 7

The pressure variation in a six-stage 190-s cycle

Fig. 8
figure 8

a Mole fraction of hydrogen during consecutive cycles on top of the all six beds. b Bed temperature during consecutive cycles on top of the all six beds

Fig. 9
figure 9

Hydrogen purity versus feed flow rate and P/F of 0.1, 0.2 and 0.3

Fig. 10
figure 10

Hydrogen purity as a function of adsorption stage pressure

CO2 separation through absorption through MEA solvent in the second stage

CO2 concentration profile in the radial direction is shown in Fig. 11 for the different liquid flow rates in three sections of tube, membrane and shell. In this figure, the gas flow rate was constant at 200 ml/min when MEA is used as the adsorbent for the separation of CO2. As it is expected, the gas concentration slope is descending from the shell side to the membrane side and final to the tube side. In fact, the aim is to separate CO2 from the shell side and then solve it in the flowing solvent, which is obviously evident in different liquid flow rates. According to the figure, an increase in liquid flow rate leads to more removal of CO2 from the gas mixture. Since the concentration gradient in the membrane-tube surface increases when the solvent flow rate is higher and, thus, the mass transfer rate increases. Figure 12 shows variation in dimensionless CO2 concentration versus dimensionless axial distance in different liquid flow rates and constant gas flow rate of 200 ml/min for the tube side and shell side while MEA solvent is used. As per Fig. 12a, it can be observed that CO2 concentration increases with increase in dimensionless axial distance in the tube side. This trend is rational since the solvent absorbs more CO2 while moving in its path, and CO2 concentration grows up along the tube length. In addition, dimensionless CO2 concentration decreases with a decrease in liquid flow rate, since the lesser liquid flow rate causes solution rate decrease in the solvent and, therefore, mass transfer rate in tube-membrane surface decreases. As shown in Fig. 12b, the trend of variation in the shell side is descending because CO2 diffuses to the membrane, leading to a decrease in its concentration. On the other hand, with an increase in liquid flow rate, CO2 concentration decreases along the shell length. Actually, with an increase in liquid flow rate, owing to increase in concentration gradient in the membrane-tube surface, and subsequently, in the shell-membrane surface, it is rational that CO2 concentration more decreases along the shell length. Figure 13 demonstrates CO2 removal percentage versus variation in liquid and gas flow rates. With the increase in gas flow rate, CO2 removal percentage from the gas mixture reduces considering the fact that more gas flow velocity is; so the less time is available for the gas phase to diffuse into the membrane. Nevertheless, with an increase in liquid flow rate, since the liquid reclamation rate intensifies, the mass transfer occurs with a higher rate, and this is why CO2 removal percentage grows up.

Fig. 11
figure 11

CO2 concentration profile in the radial direction for the different liquid flow rates in three sections of tube, membrane and shell

Fig. 12
figure 12

a Dimensionless CO2 concentration versus dimensionless axial distance in different liquid flow rates and constant gas flow rate of 200 ml/min for the tube side. b Dimensionless CO2 concentration versus dimensionless axial distance in different liquid flow rates and constant gas flow rate of 200 ml/min for the shell side

Fig. 13
figure 13

CO2 removal percentage versus variation in liquid and gas flow rates

Evaluation of a proposed method of methanol production from CO2

In this section, the operability of methanol synthesis from CO2 reactor is evaluated in their different conditions, which is named as follows:

  1. 1-

    Industrial unit in its conventional type with the gas mixture feed of CO, CO2, H2 and H2O.

  2. 2-

    Industrial unit in which CO2 is fed instead of CO.

  3. 3-

    Regarding the kinetic of methanol production reaction from CO2, for 1 mol of CO2, 3 mol of H2 is fed into the reactor.

Figure 14 compares the performance of methanol synthesis reactors in three cases. The molar fraction of CO, CO2 and H2 is illustrated through the reactor length. As shown in Fig. 14a, CO is just entered into the reactor as the feed in the industrial case (case (1)), and in two other cases CO concentration is considered zero. In the cases (2) and (3), CO molar fraction increases along the reactor length because H2O is produced by the reaction of methanol synthesis through CO2, and then it reacts with the existing CO2 through WGS reaction. As per Fig. 14b, it can be observed that molar fraction of CO2 decreases along the reactor length owing to its consumption in all the three cases. As shown in Fig. 14c, H2 molar fraction demonstrated along the reactor length. Considering that the ratio of H2 to CO2 is 3 (H2/CO2 = 3). Since H2 is one of the reactants in methanol production reaction, its molar rate decreases along the reactor length. Figure 14d shows the molar flow rate of methanol versus dimensionless reactor length. According to this figure, methanol production rate in the cases at which 25% of the feed is CO2 and 75% of H2, approximately is equal to the methanol production rate from the synthesis gas in case (1). Besides, it shows H2 and CO2 conversion percentage. As in Fig. 14e, it is evident that the highest conversion percentage of H2 can be achieved in case (3), and the reason for this result is the appropriate ratio of the input components to the reactor. The lowest H2 conversion percentage is obtained in case (2) since in this case the CO concentration is considered zero, and CO2 is fed instead of CO. As per Fig. 14f, it can be observed that CO2 conversion in the case (2) is higher than two others. It may seem that this figure contradicts the results of previous figures; however, it should be emphasized that the conversion percentage is the ratio of the converted amount to the amount fed and consequently in case (3), with higher CO2 flow rate in the feed, it is reasonable to observe higher conversion percentage in case (3) than case (2). However, in case (1) it remains to be asked why in this case the input CO2 is lower than that of other cases, why the mentioned results have not been obtained. To explain, this result is due to the existence of CO in case (1). In the kinetic of methanol production, 1 mol of CO reacts with 2 mol of H2 while 1 mol of CO2 reacts with 3 mol of H2, and thus the former reaction (with CO) occurs more than the latter (CO2), and this is why conversion percentage decreases in this case.

Fig. 14
figure 14

a Comparison between the variation of CO molar fraction in the three flow cases vs. methanol reactor length. b Comparison between the variations of CO2 molar fraction in the three flow cases vs. methanol reactor length. c Comparison between the variations of H2 molar fraction in the three flow cases vs. methanol reactor length. d Comparison between the variations of CH3OH molar flow rate in the three flow cases vs. methanol reactor length. e Comparison between the variations of H2 conversion in the three flow cases vs. methanol reactor length. f Comparison between the variations of CO2 conversion in the three flow cases vs. methanol reactor length

Conclusion

In this investigation, two subjects are evaluated through simulation of mathematical models including (1) separation of H2 and CO2 from the flare gas (N2/CH4/CO/CO2/H2) with sorbent/solvent method, (2) presentation and evaluation of methanol production from CO2, and comparison between three different cases of input feed. In addition, the results of simulation through selected models are validated through comparison with those results which are obtained by simulation of empirical data. With this purpose in mind, separation through sorbent/solvent method is studied while a gas mixture that is analogous to real flare gas is considered. Results of simulation illustrate that owing to a high volume of H2 in the inlet as well as simplicity of separation through PSA method, the first stage of separation is preferred to be performed through PSA method, while activated carbon and zeolite 5A are used as the sorbents. In addition, some influential parameters such as P/F and pressure are evaluated to simulate the best separation process. In the next separation stage, CO2 is separated from the outlet stream of the first stage of separation (N2/CO/CO2/CH4) through MEA solvent. In this stage, according to the obtained results, the best gas and liquid (solvent) flow rates are 200 ml/min and 720 ml/min, respectively. Also, results show that the recycled gas flow rate is 473.37 kmol/h, and 99.83% CO2 and 75% H2 can be removed from the gas mixture. The simulation results for the second part (methanol production) demonstrate that methanol production flow rate is 0.0344 mol/s, 0.0248 mol/s and 0.0330 mol/s for cases (1), (2) and (3), respectively. Furthermore, methanol production of the case (1) is approximately close to that of the case (3), and it is reduced 4% in case (3).