Short-cut distillation columns based on orthogonal polynomials of a discrete variable Peter Lory Institut für Wirtschaftsinformatik, Universität Regensburg, D 93040 Regensburg, Germany Dedicated to Professor Roland Bulirsch on the occasion of his 65th birthday Summary. Increasing competition in the process industries enforces the application of mathematical simulation techniques both in the design phase and in the operating phase of a plant. The basic apparatus for separation processes is the distillation column. Its rigorous (tray by tray) mathematical modelling results in a system of simultaneous nonlinear equations (algebraic in the steady-state case, differential-algebraic in the dynamic case). For high (however realistic) numbers of trays and components, these systems may become rather large (thousands of equations). In addition, realistic plant models often include several distillation columns. As a consequence, the numerical solution of these models may become difficult and time consuming. This has led to attempts to model the distillation columns less rigorously with the aim to achieve a considerable reduction in the number of equations. The name short-cut distillation columns is common for models of this type. The present paper uses a discrete weighted residual method for the development of short-cut models. It suggests a Galerkin method based on orthogonal polynomials of a discrete variable, the tray number. It is a remarkable advantage of this technique that even very coarse models satisfy all global balances exactly. Keywords: Mathematical models, distillation columns, discrete weighted residual method, discrete Galerkin method, Hahn polynomials. 1
1. Introduction Separation processes are ubiquitous in chemical engineering, see e.g. Holland (1981) or King (1980). The basic apparatus for these purposes is the distillation column. A tray distillation column consists of numerous stacked equilibrium stages that operate at different pressures and temperatures. The following system of equations is a steady-state model of a distillation column with N trays. The index i refers to the number of a tray (stage) starting at the bottom (i = 1) and ending at the top (i = N). The mixture consists if n c components. The index j denotes its number. L i+1 + V i 1 L i V i + F i = 0, (1.1a) L i+1 x i+1,j + V i 1 y i 1,j L i x i,j V i y i,j + F i z i,j = 0 (j = 1,..., n c ), (1.1b) n c y i,j = 1, (1.1c) j=1 y i,j K i,j (T i, P i, x i, y i ) x i,j = 0 (j = 1,..., n c ), (1.1d) L i = Φ(M i ), (1.1e) L i+1 h L i+1 + V i 1 h V i 1 L i h L i V i h V i + F i h F i + Q i = 0, (1.1f) h L i = h L i (T i, P i, x i ), h V i = h V i (T i, P i, y i ), (1.1g) P i P i+1 = Ψ(M i+1, V i ). (1.1h) These equations determine the following state variables: M i : molar liquid holdup on stage i, L i : molar liquid flowrate descending from stage i to stage i 1, V i : molar vapour flowrate ascending from stage i to stage i + 1, x i,j : mole fraction of component j in the liquid at stage i, y i,j : mole fraction of component j in the vapour at stage i, h L i, h V i : molar enthalpies of liquid and vapour at stage i, T i : temperature at stage i, P i : pressure at stage i. The following quantities are given: the external heat input Q i to stage i, the feed flowrate F i to stage i as well as its mole fractions z i,j and its molar enthalpy h F i, the liquid flowrate L N+1 to the top tray together with its mole fractions x N+1,j and its molar enthalpy h L N+1, the vapour flowrate V 0 to the bottom tray as well as its composition y 0,j and the molar 2
enthalpy h V 0, the external pressure at the column top P N+1. The row vectors x i collect the mole fractions of the liquid at stage i: x i = (x i,1,..., x i,nc ). The vectors y i are defined analogously. Equation (1.1a) is the total material balance on stage i, while (1.1b) are individual material balances for the n c components. Equation (1.1c) expresses the fact, that the mole fractions in vapour sum up to 1 (see below). Equations (1.1d) describe the thermodynamic equilibrium relation between the mole fractions in the vapour phase and in the liquid phase. The so-called K values K i,j are determined by a physical property system based on given T i, P i, x i,j, y i,j. The flowrate L i of the liquid leaving stage i is a known function Φ of the holdup M i on this stage (1.1e). Equation (1.1f) describes the total enthalpy balance over stage i, with the liquid and vapour molar enthalpies defined by (1.1g). Both values are again given by a physical property system. Equation (1.1h) expresses the pressure drop between two consecutive stages. For more details, see Eich-Soellner et al. (1997). It is assumed that both the mole fractions x N+1,j of the liquid flow to the top tray and the mole fractions y 0,j of the vapour flow to the bottom tray and the mole fractions z i,j of each feed sum up to 1. Then it is a consequence of (1.1a) and (1.1b) that n c x i,j = 1 (i = 1,..., N). (1.2) j=1 As a consequence, these equations can substitute the group of equations with j = n c in (1.1b). However, the present paper stresses the exact satisfaction of the global balances (see Section 3). Thus, it is reasonable to enforce all the local mass balances in (1.1b) explicitly. The system (1.1) consists of N(2n c + 7) equations for the same number of unknown variables. In practical applications, the number of trays is within 10 N 100, and the number of components is less than 50. As a consequence, it is not uncommon that the the system (1.1) comprises thousands of equations. Additionally, a realistic plant may include several distillation columns. Consequently, the numerical solution of these models may become difficult and time consuming. This has led to attempts to reduce the number of equations in distillation column models without losing the required level of detail. The name short cut distillation column is common for a model of this type. Most of these approaches use engineering experience and have a low level of mathematical sophistication. The paper of Eckert & Vanek (1985) is a representative for short-cut models of this type. Other authors, in particular Stewart et al. (1985), use discrete weighted residual methods for the development of short-cut models. The article of Canu & Ray (1991) gives a survey of this and subsequent papers. These authors use collocation and cannot guarantee the exact satisfaction of the global balances (see Section 3). The present paper uses a discrete weighted residual method, too. However, the weighting functions are chosen according to the discrete Galerkin method. As shown in 3
Section 3, this has the advantage that the global balances are satisfied exactly (up to roundoff errors and up to the errors due to the nonlinear equation solver, of course). In other words, the reduction in the dimensionality of the model does not diminish the exactness of the global balances. The following section (Section 2) describes the discrete Galerkin method, in particular the use of the Hahn polynomials as basis and test functions within the frame of the discrete weighted residual method. Section 3 shows that the proposed method produces results that satisfy the global balances exactly. Section 4 summarises first numerical experiments. 2. The discrete Galerkin method At those trays, where a feed of material or energy enters the column, the solutions obviously change abruptly. As a consequence, it is convenient for the short-cut approach to partition the column in sections, where no feed is present (e.g. rectifying or stripping sections). In the following, it is assumed that such a section is given. Its modelling equations are given by (1.1) with the exception that feeds can occur only at the bottom or top tray. Let the trays in the rigorous model for such a section be numbered from i = 1 (bottom) to i = N (top). Then the feeds of this section can be added to the corresponding flowrates (L N+1, L N+1 x N+1,j, V 0, V 0 y 0,j ) and enthalpies (L N+1 h L N+1, V 0 h V 0 ) that enter the section. As a result, the transformed (equivalent) rigorous model of this column section does not contain any feeds F i, F i z i,j, F i h F i or Q i explicitly. This is assumed in the following. It has been suggested to built a short-cut model by transforming the discrete variable i into a continuous one. The paper of Canu & Ray (1991) gives a review of these attempts. This approach yields a differential equation in the continuous variable, that has to be discretized for its numerical solution. However, it seems much more natural to retain the discrete nature of the original problem. This is pointed out in the papers of Deuflhard & Wulkow (1989, 1995) in the context of a different field of application, namely the computational treatment of polyreaction kinetics. The present paper also uses a discrete version of the classical Galerkin method. For that purpose, the unknown functions are approximated by linear combinations of certain basis functions. E.g. for the flowrates: n n L(s) = Λ k H k (s), V (s) = Φ k H k (s), s {1, 2,..., N}. (2.1) k=0 k=0 The discrete Galerkin method is a special case of the discrete weighted residual method and needs a scalar product for its formulation: The discrete Galerkin equations for (1.1a) are N f, g := f(s)g(s). (2.2) s=1 L(s + 1) + V (s 1) L(s) V (s), H l (s) = 0 (l = 0, 1,..., n). (2.3) 4
The Galerkin equations for (1.1b) (1.1h) are analogous. Altogether, a nonlinear algebraic system of (n + 1)(2n c + 7) equations for the same number of coefficients in the representations of the state variables arises. The number n has to be selected as small as possible without sacrificing too much accuracy. It is computationally convenient to use orthogonal polynomials as the basis functions H k (s). The scalar product (2.2) suggests the use of Hahn polynomials, which are defined by Q k (s; α, β, N) = k ν=0 ( k) ν ( s) ν (k + α + β + 1) ν ( N) ν (α + 1) ν ν! see e.g. Askey (1975). Here, the definitions (a) 0 = 1, (a) ν = a (a + 1)... (a + ν 1) for ν > 0, α, β > 1, k = 0,..., N ; (2.4) have been used. For α = β = 0, these polynomials satisfy the following orthogonality relation: 0 for k l N Q k (s; 0, 0, N) Q l (s; 0, 0, N) = (2.5) N + 1 s=0 for k = l, π k where π k = ( 1)k ( N) k (2k + 1). (N + 2) k As a consequence, the polynomials H k (s) = Q k (s 1; 0, 0, N 1) (2.6) are orthogonal with respect to the scalar product (2.2). The present paper uses these polynomials both as basis and as test (weighting) functions. The paper of Karlin & McGregor (1961) lists some interesting relations for Hahn polynomials. Please note that they use a slightly different notation: their polynomials Q k (s; α, β, N) are orthogonal on s = 0, 1,..., N 1. 3. Global balances According to Section 2, it is assumed that the rigorous model of a column section has been transformed to an equivalent model with no explicit feeds. Straightforward calculations show that such a rigorous model (1.1) satisfies the following global balances for material and enthalpy: L N+1 + V 0 L 1 V N = 0, (3.1a) L N+1 x N+1,j + V 0 y 0,j L 1 x 1,j V N y N,j = 0 (j = 1,..., n c ), (3.1b) L N+1 h L N+1 + V 0 h V 0 L 1 h L 1 V N h V N = 0, (3.1c) 5
It is a very attractive feature of the Galerkin method as proposed in Section 2 that even for arbitrary n the results of the short-cut model satisfy the same balances. Indeed, the Galerkin equations (2.3) contain the equation L(s + 1) + V (s 1) L(s) V (s), H 0 (s) = 0 (3.2) with the Hahn polynomial H 0 of degree 0 as test function. This polynomial is a constant, and from Equation (3.2) follows immediately L(N + 1) + V (0) L(1) V (N) = 0. (3.3) This is the mass balance (3.1a). The other global balances follow analogously. Remark: Stewart et al. (1985) have developed short-cut models for distillation columns on the basis of discrete weighted residual methods, too. These authors use collocation with the zeros of the Hahn polynomials as collocation points. See Canu & Ray (1991) for a survey of this and subsequent papers. However, these methods cannot guarantee the exact satisfaction of the global balances. Intuitively, the Galerkin approach seems to be more adequate than collocation because the equations of the former method merge the different stages to a higher degree. 4. Numerical experiments The test problems of Fletcher (1990) have been used as the basis for first numerical experiments. These problems are simplified versions of the system (1.1). They do not include holdups and pressures as variables. Consequently, Equations (1.1e) and (1.1h) are dropped. The K-values are given by the relationship ( ) K i,j = 1 P i exp b j a j + c j + T i, (4.1) where the Antoine constants a j, b j, c j (j = 1,..., n c ) and the stage pressures P i are data values. The molar enthalpies are given by n c h L i = j=1 x i,j (α j + α jt i + α j T 2 i ), h V i = n c j=1 y i,j (β j + β jt i + β j T 2 i ), (4.2) where the liquid enthalpy constants α j, α j, α j and the vapour enthalpy constants β j, β j, β j (j = 1,..., n c ) are again data values. In the following, these and other necessary data are given in the schematic form of Table 1. Here, f 1,..., f nc are the individual flowrates of the feed components. In the case of a rectifying section, this means a vapour feed to the bottom tray; in the case of a stripping section it is a liquid feed to the top tray. In any case, T f is the temperature of this feed. All computations have been performed with the function fsolve of the Optimization Toolbox of MATLAB with a precision of roughly 16 significant decimal digits. The termination criteria both on the independent variables and on the function (options(2) and options(3)) were 1.E 8. 6
N, n c ; a 1, b 1, c 1,..., a nc, b nc, c nc ; α 1, α 1, α 1,..., α nc, α n c, α n c ; β 1, β 1, β 1,..., β nc, β n c, β n c ; f 1, f 2..., f nc, T f ; P 1, P 2,..., P N ; L N+1, T N+1, x N+1,1, x N+1,2,..., x N+1,nc ; V 0, T 0, y 0,1, y 0,2,..., y 0,nc. Table 1: Scheme of numerical data Example 1 Example 1 is the stripping section (without the reboiler) of the hydrocarbon-20 problem of Fletcher (1990). Its data are given in Table 2. Figures 1 and 2 give the results for the mole fractions and for the temperatures at the different stages. 9 3 9.647 2998.00 230.66 9.953 3448.10 235.88 9.466 3347.25 215.31 0. 37.6 0. 0. 48.2 0. 0. 45.4 0. 8425. 24.2 0. 9395. 35.6 0. 10466. 31.9 0. 30. 30. 40. 100. 1. 1. 1. 1. 1. 1. 1. 1. 1. 228.483155 119.604.0495711.418733.531696 290.693680 138.218261 0.1E 5.004067.995932 Table 2: Data of Example 1 Table 3 summarises the results of the short-cut models. For the most important components of the solution vector, it gives the maxima of the relative errors between the short-cut solutions for n = 2, 3, 4 and the solution of the rigorous model. In Example 1, the components x i,1 and y i,1 are very small in comparison with the others, and the absolute errors are given in these cases. The number n is the maximum degree of the Hahn polynomials that are involved in the corresponding short-cut model. 7
1 0.9 0.8 0.7 Mole fractions 0.6 0.5 0.4 0.3 0.2 0.1 0 1 2 3 4 5 6 7 8 9 Number of tray Figure 1: Example 1 ( refers to liquid, refers to vapour) 140 138 136 Temperatures 134 132 130 128 126 124 122 1 2 3 4 5 6 7 8 9 Number of tray Figure 2: Example 1 8
Example 1 Example 2 n = 2 n = 3 n = 4 n = 2 n = 3 n = 4 x i,1 0.0104 0.0048 0.0013 6.420 % 3.686 % 0.629 % x i,2 7.211 % 1.585 % 0.755 % 7.741 % 4.445 % 0.759 % x i,3 2.826 % 0.521 % 0.130 % y i,1 0.0423 0.0131 0.0038 3.799 % 2.056 % 0.189 % y i,2 5.795 % 3.579 % 1.398 % 8.553 % 4.628 % 0.424 % y i,3 4.836 % 0.558 % 0.294 % L i 0.452 % 0.073 % 0.026 % 0.936 % 0.712 % 0.058 % V i 0.394 % 0.114 % 0.013 % 0.964 % 0.445 % 0.086 % T i 1.071 % 0.169 % 0.022 % 1.798 % 0.859 % 0.122 % Table 3: Errors between short-cut solutions and the rigorous solution Example 2 Example 2 is an enlarged version of the rectifying section (without the condenser) of the methanol-8 problem of Fletcher (1990). Its data are given in Table 4. Figures 3 and 4 show the results for the mole fractions and for the temperatures at the different stages. Table 3 presents the results of the short-cut models. Here, for all components the relative errors are given. 8 2 18.5751 3632.649 239.2 18.3443 3841.2203 228. 0. 15.97.0422 0. 18.1 0. 9566.67 1.59.0422 10834.67 8.74 0. 0. 0. 1180. 1170. 1160. 1150. 1140. 1130. 1120. 1110. 620. 72. 0.96 0.04 950. 105. 0.57 0.43 Table 4: Data of Example 2 Final remarks The numerical experiments show that the proposed approach for short-cut distillation columns is very promising. In accordance with the theoretical results of Section 3, 9
1 0.9 0.8 0.7 Mole fractions 0.6 0.5 0.4 0.3 0.2 0.1 0 1 2 3 4 5 6 7 8 Number of tray Figure 3: Example 2 ( refers to liquid, refers to vapour) 100 95 Temperatures 90 85 80 75 1 2 3 4 5 6 7 8 Number of tray Figure 4: Example 2 the balances (3.1) were statisfied with a relative precision of at least 2.2 E 12 in all rigorous and short-cut computations. This feature is particularly attractive when shortcut models are used as units in large flowsheets, see e.g. Eich-Soellner et al. (1997). 10
References Askey, R., 1975. Orthogonal Polynomials and Special Functions, Philadelphia, Society for Industrial and Applied Mathematics. Canu P. & Ray W. H., 1991. Discrete weighted residual methods applied to polymerization reactions. Computers Chem. Engng. 15, 549 564. Deuflhard P. & Wulkow M., 1989. Computational treatment of polyreaction kinetics by orthogonal polynomials of a discrete variable. IMPACT Comput. Sci. Eng. 1, 269 301. Deuflhard P. & Wulkow M., 1995. Simulationsverfahren für die Polymerchemie. In: Mathematik in der Praxis (A. Bachem et al., Eds.). Berlin, Springer. Pp. 117 136. Eckert E. & Vanek T., 1985. Simulation of stage separation columns based on the block short-cut approach. Chemical Engineering Science 40, 2361 2367. Eich-Soellner E., Lory P., Burr P. & Kröner A., 1997. Stationary and dynamic flowsheeting in the chemical engineering industry. Surveys on Mathematics for Industry 7, 1 28. Fletcher R., 1990. Distillation column test problem. In: Computational Solution of Nonlinear Systems of Equations (E. L. Allgower et al., Eds.). Lectures in Applied Mathematics 26, Providence, American Mathematical Society. Pp. 727 733. Holland, C. D., 1981. McGraw-Hill. Fundamentals of Multicomponent Distillation, New York, Karlin S. & McGregor J. L., 1961. The Hahn polynomials, formulas and an application. Scripta Mathematica 26, 33 46. King, C. J., 1980. Separation Processes, New York, McGraw-Hill. Stewart W. E., Levien K. L. & Morari M., 1985. Simulation of fractionation by orthogonal collocation. Chemical Engineering Science 40, 409 421. 11