process model based control of distillation columns …

135
PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS by RUPAK SINHA, B.S. in Ch.E. A THESIS IN CHEMICAL ENGINEERING Submitted to the Graduate Faculty of Texas Tech University in Partial Fulfillment of the Requirements for the Degree of MASTER OF SCIENCE IN CHEMICAL ENGINEERING Approved Accepted December, 1988

Upload: others

Post on 28-Apr-2022

12 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS

by

RUPAK SINHA, B.S. in Ch.E.

A THESIS

IN

CHEMICAL ENGINEERING

Submitted to the Graduate Faculty of Texas Tech University in

Partial Fulfillment of the Requirements for

the Degree of

MASTER OF SCIENCE

IN

CHEMICAL ENGINEERING

Approved

Accepted

December, 1988

Page 2: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

—o

-•o

T3

^f^ ACKNOWLEDGEMENTS Ci>pv

I would like to express my sincere appreciation to my graduate

advisor, Dr. James B. Riggs, for his guidance and support throughout

this work. I wish to express my thanks to Dr. R. Russell Rhinehart for

his constructive suggestions.

I would like to dedicate this work to my family, especially my

parents, for their unbending support and love throughout this project

and my academic career.

Last, but not least, I would like to thank my friends who always

took time to listen and make suggestions. I am thankful to Kamal M.

Mchta for his friendship, and Lisa M. Trueba for proofreading this

document.

Appreciation is also extended to Dow Chemicals U.S.A. for

providing the financial support that made this research possible.

11

Page 3: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

b J

TABLE OF CONTENTS

ACKNOWLEDGEMENTS ii

LIST OF TABLES v

LIST OF FIGURES vi

NOMENCLATURE vii

CHAPTER

1. INTRODUCTION 1

2 . LITERATURE REVIEW 4

2.1 Dynamic Simulation of a Distillation Column 4

2 . 2 Distillation Control 7

2 . 3 Sidestream Control 17

2.4 Control of High-Purity Columns 19

3 . DYNAMIC MODELING OF A DISTILLATION COLUMN 22

3.1 Tray-to-Tray Model 22

3 . 2 Modelling of High-Purity Columns 26

4. PROCESS MODEL-BASED CONTROL OF A HIGH-PURITY COLUMNS 31

4.1 Process Model-Based Control 31

4.2 Parameterization of Process Model-Based Controller 32

4.3 Implementation of Process Model-Based Controller 36

5 . RESULTS AND DISCUSSION 39

6. DEVELOPMENT AND VERIFICATION OF A STEADY-STATE APPROXIMATE MODEL OF A DISTILLATION COLUMN WITH A SIDESTREAM DRAWOFF 66

6 .1 Model Derivation 66

111

Page 4: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

i

6 . 2 Implementation of the Approximate Model 71

6 . 3 Approximate Model Verification 74

7 . CONCLUSIONS AND RECOMMENDATION 85

7 .1 Conclusions 85

7 . 2 Recommendations 86

LIST OF REFERENCES 87

APPENDICES

A. LISTING OF THE COMPUTER CODE FOR PROCESS MODEL-BASED CONTROL OF HIGH-PURITY COLUMN 89

B. DETAILED DERIVATION OF THE APPROXIMATE MODEL FOR A DISTILLATION COLUMN WITH A SIDESTREAM DRAWOFF 106

C. LISTING OF THE COMPUTER CODE FOR THE APPROXIMATE MODEL 115

iv

Page 5: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

LIST OF TABLES

PAGE

TABLE 5 .1 Data for PMBC base case ^3

TABLE 6.1 Base case results for approximate model 77

TABLE 6. 2 Data used in the comparison tests 78

TABLE 6.3 Recoveries and Process gains for a change in reflux rate 79

TABLE 6.4 Recoveries and Process gains for a change in sidestream drawoff rate 81

TABLE 6.5 Recoveries and Process gains for a change in boilup rate 83

Page 6: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

LIST OF FIGURES

PAGE

FIGURE 2.1 Schematic of the P-DELTA algorithm (Process Design by limiting thermodynamic approximation) 19

FIGURE 2.2 General configuration of the Adaptive Predictive Control System 20

FIGURE 2.3 Desired temperature profile in face of feed

composition change in propane (Dl; colximn 1) 21

FIGURE 3.1 Typical seive tray N 28

FIGURE 3 .2 Flowsheet of the main driver program 29

FIGURE 3 . 3 Flowsheets of subroutines 30

FIGURE 4.1 Flowsheets 37

FIGURE 4.2 Flowsheet of subroutine CONT 38

FIGURE 5.1 Effect of an increase in XSP on bottom tray 44

FIGURE 5.2 Effect of an increase in XSP 45

FIGURE 5.3 Effect of a decrease on XSP on Tray 1 46

FIGURE 5.4 Effect of a decrease in YSP 47

FIGURE 5. 5 Effect of an increase in YSP 48

FIGURE 5.6 Increase in XSP and 5X increase in feed rate; Tray 1....49

FIGURE 5 - 7 Increase in XSP and 102 increase in feed rate; Tray 1... 50

FIGURE 5.8 Increase in XSP and 152 increase in feed rate; Tray 1...50

FIGURE 5.9 Increase in XSP and 102 decrease in feed rate; Tray 1...51

VI

Page 7: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

FIGURE 5.10 Increase in XSP and 152 decrease in feed rate; Tray 1...51

FIGURE 5.11 Increase in YSP and 52 increase in feed rate; Tray 1 52

FIGURE 5.12 Increase in YSP and 102 increase in feed rate; Tray 1...52

FIGURE 5.13 Increase in YSP and 152 increase in feed rate; Tray 1...53

FIGURE 5.14 Increase in YSP and 52 decrease in feed rate; Tray 1...54

FIGURE 5.15 Increase in YSP and 102 decrease in feed rate; Tray 1...55

FIGURE 5.16 Increase in YSP and 152 decrease in feed rate; Tray 1...56

FIGURE 5.17 +52 Upset in feed composition; Tray 1 57

FIGURE 5.18 +52 Upset in feed composition; Top Tray 57

FIGURE 5.19 +102 Upset in feed composition; Tray 1 58

FIGURE 5.20 +102 Upset in feed composition; Top Tray 58

FIGURE 5.21 Effect of a 102 upset in feed composition 59

FIGURE 5.22Effect of a 102 upset in feed composition using NLDMC...60

FIGURE 5.23 Effect of a 52 upset in feed composition 61

FIGURE 5.24 Effect of a 52 upset in feed composition using NLDMC....62

FIGURE 5.25 Effect of an increase in XSP 63

FIGURE 5.26 Effect of a decrease in XSP 64

FIGURE 5.27 Effect of a change in gain 65

FIGURE 6.1 Split of the distillation column with a

sidestream drawoff 75

FIGURE 6 .2 Flowsheets for approximate model 76

FIGURE B.l Split of the distillation column with a sidestream drawoff 114

vii

Page 8: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

NOMENCLATURE

M Molar tray holdup (moles)

L Liquid flow rate (moles/sec)

V Vapor rates (moles/sec)

h Liquid enthalpy (Btu/lbn,-°F)

H Vapor enthalpy (Btu/lbm-^F)

X(i,j) Liquid composition of component j on tray i

Y(i,j) Vapor composition of component j on tray i

hf Enthalpy of the feed (Btu/lbn,-OF)

F Feed rate (moles/sec)

z Liquid feed composition of the light key

K Equilibrium constant

T Temperature on all trays (°F)

T- Temperature at the top of the column (°F)

T j Temperature at the bottom of the column (°F)

Tf Temperature of the feed coming into the column (°F)

P Pressure in the column (Psia)

S Separation factor

B Bottoms rate (moles/sec)

D Distillate rate (moles/sec)

G Sidestream drawoff rate (moles/sec)

viii

Page 9: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

f

f Fractional recovery of comoponet i in the bottoms

g Fractional recovery of component i in the sidestream

dd Fractional recovery of component i in the distillate

a Constant relative volatility.

IX

Page 10: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 1

INTRODUCTION

Distillation is a process widely used in the petroleum and chemical

process industry to separate a mixture into its components. The

separation is based on the fact that the vaporized portion of a liquid

mixture has a composition richer in the more volatile components from

that of the liquid. Binary columns have been widely studied and linear

controllers such as the Proportional-integral (PI) and Proportional-

integral-derivative (PID) usually perform satisfactorily for low purity

columns that also have consistent feed quality and feed flowrate.

However, at moderate purities the binary column exhibits nonlinear

behavior and coupling effects become important. Today, many industrial

areas, such as pharmaceuticals, plastics, and polymer production,

require very high purity products. High purity columns are both

extremely nonlinear and highly coupled thus limiting the applications of

linear model-based multivariable controllers and classical PID

controllers.

Process Model-Based Control (PMBC) is a new controller that has the

potential to overcome the limitations of linear model-based controllers.

PMBC is a multivariable model-based controller which uses an approximate

model directly for control purposes. The approximate model does not

have to be a rigorous simulator, but does need to contain the major

characteristics of the process. The approximate model is adaptively

Page 11: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

updated on-line in order to keep it "true" to the process as changes in

the process and process operating conditions occur. Since the PMBC

controller has a relatively accurate description of the process, it

provides nonlinear feedback control along with nonlinear feedforward

control. Therefore, the PMBC controller is able to "anticipate" the

required control action to absorb feed composition and feed flowrate

changes through its feedforward capabilities, as well as absorb the

results of an unmeasured disturbance (heavy or light feed composition

change, cooling water temperature change, head losses, etc.) using its

feedback features. As a result, PMBC can offer significant advantages

for distillation columns that produce high purity products. The

objectives of the first phase of this research are to develop a rigorous

dynamic simulation model for a high purity binary distillation column,

and then test the implementation of the PMBC algorithm to control the

column.

The second phase of this research involves the study of

distillation columns with sidestream drawoffs. A distillation column

that uses a sidestream drawoff can provide substantial economic savings.

Sidestream drawoff can reduce the number of columns required for certain

multicomponent separations. For instance, if we had to separate a

mixture of ABC, it would require two columns, one to separate A from BC

and the other to separate B and C whereas, a distillation column with a

sidestream drawoff could perform the required separation in a single

column. They also can be used for binary separations to obtain

Page 12: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

different purities of the two components. Despite these process

advantages of columns with sidestream drawoff columns, control is

inherently more difficult than with conventional columns since there are

more degrees of freedom. Product quality control loops and material

balance control loops are more complex, less direct, often more

sensitive and more interacting. Sometimes unexpected dynamic and steady

state behavior can be observed due to transient and steady state changes

in internal liquid and vapor rates. In order to use all the economic

advantages of a distillation column with a sidestream drawoff, better

control techniques will have to be developed. In order to apply PMBC to

the sidestream column we need an approximate model of a column with a

sidestream drawoff. The last phase of the research includes the (1)

development of an extension of the Smith and Brinkley approximate model

to incorporate the sidestream drawoff and (2) the verification of the

approximate sidestream drawoff model.

Page 13: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 2

LITERATURE REVIEW

2.1 Djmamic Simulation of a Distillation Column

The advent of analog computers in the early 50's allowed attempts

to be made, to model distillation dynamics in a reasonable manner, but

simplifications were imposed by the limitation of the analog equipment

However, the widespread availability of digital computers in the 60's

promted new attack on the d3mamics problem, but a number of earlier

simplifications remained. For instance, Huckaba et al. (1963) limited

their attention to binary distillation at constant pressure, with

constant liquid holdups and negligible vapor holdups. Waggoner and

Holland (1965) required independent specifications of the transient

behavior of the liquid holdups, and vapor holdup was once again

neglected. Levy, Foss, and Grens (1969) effectively treated the

varying liquid holdups but made the following assumptions:

(1) Constant vapor holdup that is small compared to the liquid holdup.

(2) Perfect liquid mixing at every stage.

(3) Negligible holdup in condenser.

(4) Adiabatic column.

(5) Constant liquid holdup in reflux drum and reboiler.

Page 14: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

(6) Stationary process, described by linear differential equations for

small perturbations from steady state.

However, in the 70's, linearized, dynamic models were developed.

In their book, Rademaker et al., (1975) extensively cover linearized

dynamic modeling of distillation columns, and they use these models for

stability analysis and control systems design.

Luyben (1973) extensively covers the dynamics of multicomponent

distillation columns, and presents an algorithm using Euler's method to

solve the differential equations. In his approach almost all possible

nonlinarities are eliminated by local linearization, using the following

assumptions:

(1) There is one feed plate onto which vapor and liquid feed are

introduced.

(2) Pressure is constant on each tray but varies linearly up the

column.

(3) Coolant and steam dynamics are negligible in condenser and

reboiler.

(4) Vapor and liquid products are taken off the reflux drum and in

equilibrium. Dynamics of vapor space in reflux drum are

negligible.

(5) Liquid hydraulics are calculated from the Francis weir formula.

(6) Volumetric holdups in the reflux drum and column base are held

constant by changing the bottoms and distillate rates.

Page 15: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

(7) Dynamic changes in internal energy on trays are negligible compared

with latent-heat effects, so the energy equation on each tray is

just algebraic.

Luyben also presents a code for the algorithm in his text. However,

with the availability of some differential equation solving packages,

Euler's method is inefficient by contrast.

Sourisseau and Doherty (1982) studied various different dynamic

models and classified them according to the state variables employed.

Following their definitions, a model in which the state vector consists

of only liquid compositions was called the C-model. If both

compositions and enthalpies are included, the CE-model results. The

most complex model is the CHE-model and has a differential equation for

each state variable on each tray (composition, holdup and enthalpy).

The constant molar-overflow model (CMO-model), assumes fast holdup and

energy changes as well as fixed liquid and vapor rates at all times.

Sourisseau and Doherty studied all five dynamic models for various

distillation problems involving relatively ideal mixtures. They

concluded that the transient response results for all of the models were

in good agreement. Furthermore, they concluded that the CE and CHE

models were too time consuming considering the relatively little

additional information obtained; they preferred the use of the C or CMO

models. These conclusions are in agreement with earlier work by Levy et

al. (1969), which indicate that the significant dynamics in distillation

processes are retained in the differential equation modeling liquid

phase compositions.

Page 16: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

Chimowitz, Anderson and Macchietto (1985) used the C and CMO models

of Sourisseau and Doherty to present an algorithm for the dynamics of a

multicomponent distillation column using local thermodynamic and

physical property models. They split the system into two tiers, as

shown in Figure 2.1, the inside tier uses an approximate process model

and local thermodynamic models, the outside tier contains a rigorous

thermodynamic model which is used to update the validity of the local

model based upon rigorous thermodynamic evaluations. The system they

investigated was a non-ideal ternary system. One of the characteristics

of this system is that the composition trajectories for adjacent trays

during a transition period can be distinctly different. In their

conclusions they acknowledge the fact that this approach requires larger

storage space, but it significantly improves the execution time, often

by a factor of 5 - 10 when compared to algorithms that rigorous

thermodynamic evaluations. This is a significant improvement especially

when we are considering on-line control of multicomponent distillation

columns.

2.2 Distillation Control

Feedback, feedforward, material balance control, decoupling and

cascade control are some of traditional approaches to distillation

control. All these generally involve PI or PID controllers, however,

distillation processes are non-stationary and nonlinear in nature, and

Page 17: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

their operating conditions change frequently. For this reason

computerized distillation control has become an active research topic

for the past decade.

This was the main motivating factor for the development of adaptive

control. Model reference adaptive systems (MRAS), self-tuning

regulators or controllers (STR or STC) and adaptive predictive control

systems (APCS) have been developed from different perspectives.

Martin-Sanchez (1976) developed the adaptive predictive control

system which is related to the traditional dead-beat control idea of

bringing a system to its final state or set point in minimum time. It is

characterized by the following principles:

(1) At each step a future desired process output is generated, and the

control input is computed in order to make the predicted process

output equal to the desired process output.

(2) The predicted output is based on an adaptive predictive (AP)

model, whose parameters are estimated by a recursive estimation law

with the objective of minimizing the prediction error.

(3) The previously mentioned desired process output belongs to a

desired output trajectory, that satisfies a certain performance

criterion, e.g., this trajectory can start from the current 'state'

of the plant and evolve according to some chosen dynamics to the

final desired setpoint.

Page 18: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

However, the dead-beat control idea seems impractical because (i) it

requires an exact knowledge of the process model and (ii) its implicit

objective function is closed in nature and generally requires an

excessive control effort. Predictive control as defined by APCS is

unlike dead-beat control. It is in fact a very practical and powerful

strategy because it includes the concept of a desired output trajectory

based on a finite-time horizon objective.

Martin-Sanchez and Shah (1984) introduced the adaptive predictive

control methodology with special emphasis on the key issues involved in

the practical applications of APCS to real processes, using SISO and

MIMO control of a binary distillation column. Figure 2.2 shows a

general confguration of APCS, the specific functions at each control

instant are explained as follows:

The driver block generates a future desired process output value,

that belongs to a desired output trajectory.

The adaptive predictive model is used to generate a control signal

that makes the predictive process output equal to the desired output

generated by the driver block.

The adaptive mechanism: (i) adjusts the adaptive predictive model

to minimize the prediction error and (ii) allows the driver block to

redesign the desired output trajectory for the optimization of the

control system performance.

Martin-Sanchez and Shah also provide the mathematical formulation

and implementation of APCS. Their experimental results easily out

Page 19: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

10

perform all classical techniques, and have put APCS beyond the

theoretical stage.

Yu and Luyben (1984) used multiple temperatures for the control of

distillation columns. They studied two columns, one had three

components and thirty-two trays and the other had five components and

twenty trays. Using a steady-state model they proposed three different

control systems as follows:

(1) The Single Temperature Control involves selecting the 'optimum'

tray which gave minimum steady-state error in distillate

composition for the 'worst' disturbance.

(2) The Temperature/Differential Temperature Control follows these

design procedures:

a) find the 'optimum' single temperature control tray;

b) generate the desired temperature profiles for the worst

disturbance case (e.g.. Figure 2.3);

c) locate the section of the column where there is the most

change in temperature differential.

This control works well for lighter than light key (LLK) feed

composition changes, but it may not work as well for light key (LK)

and heavy key (HK) changes in feed composition.

(3) The Temperature/Dual Differential Temperature Control (TD2T) is

based on adjusting the temperature controller using two temperature

differentials. It is almost like the Temperature Differential

Controller except that it works with the temperature that least

Page 20: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

11

disturbs the LLK composition. LK and HK feed composition changes

are handled better using this type of controller.

Yu and Luyben concluded that the TD2T controller gave the best overall

performance on both columns. It also has several advantages over the

more complex and conventional 'inferential controls.'

Bryan (1985) studied the heat-integration technique to control

distillation columns. In this method a sequence of distillation columns

has to be chosen and then integrated to provide a joint effect. Heat

integration has some economic advantages in that it can reduce energy

consumption nearly 502 (Roffel and Fontein, 1979) when compared to a

conventional system using steam reboilers and water-cooled condensers.

However, heat integration does have some drawbacks which present many

control problems. Product qualities are difficult to maintain, because

the common reboiler - condenser affects operation in both columns. Also,

changes in the vapor rate in the high-pressure column effect the

performance of the low-pressure column. But the main objective of

Bryan's research was to design a control strategy that could overcome

these problems and still maintain the economic incentives of heat

integration.

There have been some attempts at developing a control strategy for

nonlinear systems, most notable by Morari and Economu (1986). They

extended the Internal Model Control approach to the nonlinear system.

Their paper describes the differences in treating the linear and

nonlinear systems both from a mathematical as well as control point of

Page 21: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

12

view. The article shows that even when dealing with processes that have

relatively mild nonlinearities, no linear controller can match the

performance and robustness of a rationally designed nonlinear

controller.

Process Model Based Control (PMBC) is a technique based on the

dynamic simulation of the real process. However, selection of a process

model can be a key factor in the design of the control system; Cott,

Reilly, and Sullivan (1986) present a procedure for the selection of a

process which can be used for PMBC. The ideal model would have the

following qualities:

(1) It would exactly predict the operation of the real process over the

entire operating region with only one set of parameters.

(2) It would require very little computational effort.

However, it is impossible to find a perfect model for a real process.

The two main criteria for selecting a model should be :

(1) Model Accuracy: preference would go to the model that most closely

reflects the real process over the operating region.

(2) Computational Effort: the model requiring the fewest calculations

would be preferred.

They also suggest an algorithm for the integration of the model

selection techniques, accuracy and computational effort as follows:

Page 22: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

13

(1) Select candidate model on rough computational effort criterion,

based on control computer capacity.

(2) Determine the accuracy of the candidate models by validating with

respect to the process data.

(3) Determine the computational effort required for each model.

(4) Select the 'best' model, based mainly on accuracy criterion.

This algorithm provides a basis for a model selection procedure for

model-based control.

They also present a detailed application of these techniques to

distillation control. They use the model presented by Luyben (1973) as

the rigorous simulation model and then evaluate four shortcut methods

using the model selection procedure. Process Model Based Control is

then applied using the selected model, which was the Smith-Brinkley

model. The implementation of model-based controllers involves two

steps: a model parameter update and control action calculations. The

controller follows the following pattern:

(1) Model Parameter Update

measure D,B,y,x,L,P from the column;

' back-calculate a pseudo feed stream based on products;

solve for the Smith-Brinkley parameters.

(2) Control Action Calculation

determine the product set points;

measure F,z,P from the column and put through digital filters;

Page 23: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

using the filtered data, solve model for L and VP;

implement L and VP on the column.

They also compared PMBC with two other strategies (1) Internal Material

Balance and (2) Dynamic Matrix Control and concluded that PMBC out­

performs both techniques.

2.3 Sidestream Control

Despite the process advantages of a sidestream distillation column,

control is inherently more difficult than with conventional columns,

since there are more control variables, interactions and degrees of

freedom.

Luyben (1966), presents a qualitative discussion and comparison of

ten different schemes to control distillation columns with sidestream

drawoffs. The configurations he presents range from simple temperature

and composition control loops to internal reflux or vapor and feed­

forward control, using a ternary system. If the feed contains a small

amount of light component, then the light component is taken off the

top. the sidestream is a liquid in the rectifying section. However, if

the feed contains a small amount of the heavy component then the system

is reversed, and the sidestream will be vapor in the stripping section.

In his discussion he has assumed pressure dependence of temperature, and

states that "variations in pressure due to barometric or column pressure

drop changes, may have more effect on temperature than changes in

composition." However, pressure dependence can be reduced by placing

Page 24: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

15

the sidestream tray farther away from the end of the column to a spot

where the temperature gradient is steeper and more composition

dependent. The choice of scheme is governed by the economic and process

considerations of the application.

Tyreus and Luyben (1975) applied the sidestream drawoff to study

the control of a binary distillation column. Various schemes were

simulated on a digital computer, but due to the limited range of steady-

state operability, none of the schemes proved satisfactory. But.

controlling the sidestream composition by varying the drawoff tray

location proved to be very successful. The overhead composition was

approximately controlled by holding the temperature of a tray near the

top of the column with reflux flow. Bottoms composition was similarly

controlled by the temperature in the lower section of the column.

Doukas and Luyben (1981) present the 'L' and the 'D' --schemes to

control a two-column configuration consisting of a prefractionator

column and a sidestream column. The 'L'-scheme used the manipulation of

the sidestream drawoff tray location to control one of the sidestream

compositions. While the 'D'-scheme utilized the overhead distillate

product rate from the prefractionator to control one of the sidestream

compositions. The 'D'-scheme can handle the lightest component in the

feed better, while the 'L'-scheme the larger changes in the heaviest

component better. However, they concluded that the 'D'-scheme is much

easier to implement and hence the more favorable scheme to use.

Alatiqi and Luyben (1986) compare the controllability of two

sidestream drawoff configurations. The systems they studied are the

Page 25: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

16

sidestream column/stripper configuration (SSS) and the two column

sequential 'light-out-first' (LOF) confguration. They tested a ternary

system of benzene/toluene/o-xylene. In the LOF system the heat inputs

and reflux flow rates to each column can be manipulated, the heat input

to feed ratio (QB/F) provided good control of the column. For the SSS

system they maintained the temperatures of the trays above and below the

sidestream drawoff tray constant by manipulating the sidedraw rate. The

SSS was controlled by four PI controllers. They conclude that the load

response of the SSS was as good as, if not better than the LOF system.

2.4 Control of High-Purity Columns

Fuentes and Luyben (1983) studied the dynamics and controllability

of high-purity columns. They first studied the dynamic responses of the

open-loop system for changes in various manipulated and disturbance

variables in order to gain some insight into the dynamic difficulties

associated with the control of these columns. Then several types of

closed-loop systems were investigated. The system they used had

purities ranging from 5 mol 2 to 10 ppm (molar) impurity in both

distillate and bottoms product for two values of relatively volatility

(a=2 and a-4). They used the following assumptions: constant relative

volatility, equimolal overflow, theoretical trays, total condenser,

partial reboiler, and saturated liquid feed and reflux. To study the

Page 26: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

17

open-dynamics they linearized the nonlinear ordinary differential

equations using the Lamb and Rippin technique. From their results they

concluded that the responses are highly nonlinear. The response is

completely different for a positive change than for a negative change.

There is little difference in the dynamic behavior of systems with

different relative volatilities when purity levels are low. However, as

the purity increases, the dynamic response begins to differ greatly for

different relative volatilities. For systems with high relative

volatility the response is quite fast and highly nonlinear. Disturbance

in feed composition is felt rapidly in the bottom of the column.

Fuentes and Luyben then applied a closed-loop control on the

column. They basically used feedback controllers for each end of the

column: reflux was controlling distillate composition and vapor boil-up

controlling bottoms composition. These controllers worked well for low

relative volatility, however, for higher relative volatility the results

were very poor and large errors occurred in the product purities. So it

was concluded that simple product composition controllers cannot be used

for high-purity columns with high relative volatilities. In order to

overcome this problem they studied another controller; the Temperature/

Composition Cascade Controller. This gave a lot better results for the

high relativity columns. In conclusion they state that high purity

columns can be effectively controlled despite their highly nonlinear

behavior. They also conclude that high purity columns respond much

.re quickly than predicted by linear analysis. This fact must be mo]

Page 27: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

18

recognized when specifying analyzer cycle times and in designing control

systems.

Georgiou, Georgakis and Luyben (1988) compared the conventional

diagonal control with the Dynamic Matrix Control (DMC) design for

moderate and high purity columns and showed that the performance of DMC

can be significantly improved by the use of nonlinear transformations of

the composition measurements. They studied three systems: one had a

product composition of 992 and 1.02 light component at the top and

bottom, respectively, the other had product purities of 99.92 and 0.12.

The third column was the same as that studied by Fuentes and Luyben

(1983). The first two columns worked well with standard DMC and the

third column was rejected because it had an unstable closed-loop DMC

response. However, using the nonlinear transformations they were able

to control the third column. In conclusion they state that the DMC

performed better that conventional controllers; however, simple

nonlinear output transformations improve significantly the performance

of DMC for high purity columns.

Page 28: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

19

• • • 1 i « v • I c

t(i|a«ie>0*a*«iC

O A t * • • • t l

FIGURE 2.1 Schematic of the P-DELTA algorithm (Process Design by limiting thermodynamic approximation)

Page 29: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

20

SET POINT ^ onivER BLOCK

i

DESIRED OUTPUT ADAPTIVE

PREOICTIVC MODEL

.

CONTROL SIGNAL ^

'

P H W ^ C O O

ADAPTIVE MECHANISM

i

PROCESS OUTPUT ^

FIGURE 2.2 General configuration of the Adaptive Predictive Control System

Page 30: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

21

-• i2

i —r 74.

TE/r. a>€s cj

FIGURE 2.3 Desired temperature profile in face of feed composition change in propane (Dl; column 1)

Page 31: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 3

DYNAMIC MODELING OF A

DISTILLATION COLUMN

3.1 Tray-to-Tray Model

Performing dynamic mass and energy balances around each tray are

the first steps in developing a dynamic model of a distillation column

For a typical sieve tray shown in Figure 3.1, the equations are

Total Mass Balance:

dM(N)/dt - L(N+1) + V(N-l) - L(N)- V(N) (3.1)

Component Mass Balance:

dM(N)X(N,J)/dt - L(N+1)X(N+1,J) + V(N-l)Y(N.l,J)

+L(N)X(N,J) - V(N)Y(N,J) (3.2)

Overall Energy Balance:

dM(N)h(N)/dt - L(N+l)h(N+l) + V(N-1)H(N-1) -

L(N)h(N) - V(N)H(N) (3.3)

where there are N-tray and J-components. For every tray there are one

each of equations (3.1) and (3.3) and J-1 of equation (3.2). All the

above equations assume that vapor holdup on each tray is negligible

compared to liquid holdup. For the feed tray the equations are

22

Page 32: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

23

Overall Mass Balance:

dM(I)/dt - L(I+1) + V(I-l) - L(I) - V(I) + F (3.1a)

Component Mass Balance:

dM(I)X(I,J) - L(I+1)X(I+1) + V(I-1)Y(I-1) -

L(I)X(I,J) - V(I)Y(I,J) + FXF(J) (3.2a)

Overall Energy Balance:

dM(I)h(I) - L(I+l)h(I+l) + V(I-1)H(I-1) -

L(I)h(I) - V(I)H(I) + Fhf (3.3a)

where I is the feed plate, F is the feed rate. XF(J) is feed composition

of the Jth component and hf is liquid feed enthalpy. The equations for

the condenser and reboiler are, respectively.

Overall Mass Balance:

dM(l)/dt - L(2) - V(l) - L(l) (3.1b)

dM(N)/dt - V(N-l) - L(N) - D (3.1c)

Component Mass Balance:

dM(l)X(l,J)/dt-L(2)X(2,J) - V(1)Y(1,J) - L(1)X(1,J) (3.2b)

dM(N)X(N,J)/dt - V(N-1)Y(N-1,J) - (L(N)+D)X(N,J) (3.2c)

Overall Energy Balance:

dM(l)h(l)/dt - L(2)h(2) - V(1)H(1) - L(l)h(l) + QR (3.3b)

dM(N)h(N)/dt - V(N-1)H(N-1) - (L(N)+D)h(N) - QC (3.3c)

where tray N is the condenser, QR is the reboiler duty, QC is the

condenser duty and L(l) is the bottoms flow rate.

Page 33: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

24

To complete the model we need algebraic equations for phase

equilibria, thermal properties, and equations for the flow rates

(Luyben, 1973):

Phase Equilibrium:

Y - f(X,T,P) (3.4)

Equations of Motion:

L - f(M,V,X,T,P) (3.5)

V - f(P,Y.T) (3.6)

Thermal Properties:

h - f(X,T) (3.7)

H - f(Y,T.P) (3.8)

hf - f(Xf,Tf). (3.9)

Equations (3.1)-(3.3) can be solved simultaneously and then

equations (3.4)-(3.9) can be used to calculate column profiles of L, V,

T, X, Y and P to any step input. Equations (3.1)-(3.3) form a 'stiff

set of differential equations. This means that the system is made up of

a system of equations that represents both slow and fast dynamics. The

overall mass balance being the fastest to reach steady-state and the

component mass balance being the slowest. Numerous numerical techniques

have been proposed to solve this system of equations. Lamb et al.

(1961), used the Runge-Kutta method with the Adams predictor-corrector.

Luyben (1973), used Euler's method. Gear's method which was designed to

solve stiff systems was used by Holland and Liapus (1983).

Page 34: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

25

3.2 Modeling of High-Purity Columns

Modeling of a high purity column poses a very difficult problem,

because of the composition split. One of the objectives of this study

was to simulate a high purity distillation column. The system chosen

was ethane-butane splitter, with light component compositions between

0.012 and 99.992 in the bottom and the top. respectively. Equations for

this system are the same as those discussed in section 3.1. In the

course of this study a couple of different numerical techniques were

tried, but the Runge-Kutta method was implemented and proved to be quite

efficient. The assumptions used in modeling this column are:

(1) Constant pressure throughout each tray, but varies linear up the

column.

(2) Coolant and steam dynamics are negligible in condenser and

reboiler.

(3) Constant liquid and vapor holdups on the trays, reflux drum and

condenser.

(4) Perfect liquid mixing at every tray.

(5) Molar holdup on trays were calculated from the Francis weir

formula.

(6) There is only one feed tray on which either liquid or vapor feed is

introduced.

Most of these assumptions are standard for a column. However,

assumption (3) assumes that the vapor and liquid holdup on any tray is

constant. The liquid and vapor dynamics for a system such as ours are

Page 35: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

26

so fast that they hardly provide any extra information but consume a lot

of extra computer time. While the component balance alone can provide

all accuracy and information required, previous work done by Sourisseau

and Doherty (1982) support this assumption. The feed can be either a

liquid or vapor or a mixture; the only changes that have to be made are

in equation (3.2a). Assumption (3) also eliminates the need for any

thermal properties or the use of equations for flow. The phase

equilibrium can be calculated using one of two options; one is by doing

a bubble point calculation on each tray and the other is only valid for

a binary system and that is to use constant relative volatility (a) that

varies linearly. In this work constant relative volatility was used,

because it provides the required accuracy in less computational time and

is easier to implement. Constant relative volatility is defined as:

a - K1/K2 - Y1X2A2X1 (3.10)

and hence, the equilibrium curve can be calculated using:

Yi - Xia/(l+(a+l)Xi). (3.11)

The molar holdups on the trays are calculated using the Francis weir

formula:

L - 3.33whl-5 (3.12)

where L is the liquid rate (ft3/sec)

w is the weir length (ft)

h is the weir height (ft).

Figure 3.2 is the flowsheet for the code used in this project. The

main program is the driver program; all the data needed to run the

column is fed directly into the first few lines of the program and the

composition data is read in from the data section of the program,

Page 36: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

27

subroutine DATAIN contains all the initial data for the controllers,

comment cards throughout the program indicate exactly where all the data

is to be fed in. The bottom section of the main program contains the

ordinary differential equation solver, in this case, the Runge-Kutta

method. Subroutine FX is called from within the equation solver and it

contains the call statements for the subprograms that perform the phase

equilibrium and molar holdup calculations, it also has the ordinary

differential equation required to do dynamic calculations; Figure 3.3

illustrates the flowsheet for the subroutine FX and the subprograms

called from it. A fully documented listing of this program appears in

appendix A,

Page 37: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

28

' N

Ln+1 Vn

Ln Vn-1

FIGURE 3 .1 Typica l s e i v e t r a y N

Page 38: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

29

sun

feed in alldau

initialize

set tareet tune

ves

no

controller

call subrouone func to setup ODES

equation soKrr

ves

parameterize

no

pnnt icsults

FIGURE 3.2 Flowsheet of the main driver program

Page 39: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

w

30

CaU LDHUP

Calculate Y

Set up the ODE'S

END

(a)

(b)

FIGURE 3.3 Flowsheets of subroutines a) Subroutine FX b) Subroutine LDHUP

Page 40: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 4

PROCESS MODEL-BASED CONTROL

OF A HIGH-PURITY COLUMN

4.1 Process Model-Based Control

Process model-based control (PMBC) is a nonlinear control scheme,

which, as its name indicates, is based directly on an approximate model

of the process in study. The advantage of using mechanistic process

models in control is that they reflect the nonlinearities of the real

process and they account for interaction among process variables. Using

this type of a model to predict the control action required to meet the

control objectives can be expected to improve the control performance

over the simple traditional cause-and-effect controllers. Therefore,

PMBC can predict control actions to move all controlled variables to

their setpoints while single loop may interact with each other.

Cott et al. (1986) presented selection techniques for approximate

models of process model based controllers for distillation columns. In

their article they state what the qualities of an ideal model ought to

be and then go on to develop a selection procedure using the following

guidelines:

(1) Model Accuracy

(2) Model Selection Procedure

(3) Model Parameter Update.

31

Page 41: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

32

They considered the following short-cut models:

(1) the Douglas-Jafaery-McAvoy model

(2) the Edmister Group method

(3) the Fenske-Underwood-Gilliland model

(4) the Smith-Brinkley (SB) model

and concluded that the SB model was the best-suited based on its

accuracy and computational ease for controlling a distillation column.

Based on their conclusion we used the SB model to design our process

model-based controller.

4.2 Parameterization of Process Model-Based Controller

In the implementation of PMBC, the model parameter and control

action calculations are the two major steps. The model parameters,

which are the theoretical stages in the stripping section (M) and the

number of theoretical stages in the entire column, are updated only once

and the control action is performed periodically at each control

interval.

Steps involved in updating the model parameters are as follows:

(1) Measure the distillate rate (D), bottoms rate (B), the liquid and

vapor compositions (x,y), liquid rate (L) and the pressure (P)

from the column.

Page 42: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

33

(2) Calculate pseudo-feed qualities from products.

FP - D + B (4.1)

zP - (Dy + Bx)/FP. (4.2)

(3) Calculate reflux ratio (R) and internal flowrates (L) and (V).

R - L/D (4.3)

LP - F + L (4.4)

VP - LP - B ( .5)

V - VP. (4.6)

(4) Calculate feed, top (Tt) and bottom (Tb) stage temperatures.

zPKi(Tf,P)+(l-zP)K2(Tf,P8)-l (4.7)

y/Ki(Tt.P)+(l-y)/K2(Tt.P) - 1 ( -8)

xKi(Tb.P)+(l-x)K2(Tb.P) - 1 ( -9)

where Tf is the feed temperature.

(5) Calculate the average temperatures in the rectifying and stripping

sections.

Tn - (Tt + Tf)/2 ( -10)

Tm - (Tf + Tb)/2 ( -11)

where n and m are tray numbers in the rectifying and stripping

sections, respectively.

(6) Calculate the separation factors (S) for each section.

Sni - Ki(Tn.P)V/L i - 1.2 ( - 2)

Smi - Ki(Tn„P)V/L i-1.2. (^13)

(7) Calculate h-factors.

hi-[Ki(Tn,.P)L(l-Sni))/lKi(T„.P)LP(l-Sn,i)] i-1.2. (4.14)

(8) Calculate current recoveries for each component.

Page 43: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

34

fl ' Bx/(FP2P) (4.15)

f2 - B(l-x)/(FP(l-zP)). (4.16)

(9) Solve for model parameters using the recoveries. The two equations

are then solved simultaneously to determine the number of

theoretical stages in each section.

fi-l(l-Sni^"")+R(l-Sni)]/lalpha] i-1,2 (4.17)

alpha-(l-SniN-M)+R(l-Sni)+hiSniN-M(l.Snii"+^).

Figure 4.1 is a flowsheet of the subroutines involved in parameterizing

the system. The subroutine PARM is the parameterizing subroutine called

by the main program when initializing a system. Subroutine PARM then

calls subroutine DERP, which generates the Jacobian from the recoveries,

that are generated in the subroutine FUNC which is called by DERP.

Subroutine FUNC solves equations (4.1) through (4.17) to evaluate the

required recoveries. Subroutine DERP then generates the Jacobian. Then

Newton's method is used to solve n nonlinear equations containing n in

our case n-2, unknowns as follows:

n

(6fk/6xi)l d(J)i- -fk(x(J)) k - 1,2 n (4.18)

i-l IxU)

where Xi(J+l) - Xi(J) + d^W

where fy is the function and Xi is the independent variable. This

Jacobian is a 2 X 2 matrix. The linear forms of the two nonlinear

equations is given by:

Page 44: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

35

A(1,1)AI + A(1,2)AN - -B(l) (4.19)

A(2,1)AI + A(2,2)AN - -B(2) (4.20)

where Al and AN are deviations in the number of theoretical

stages. The solutions to these equations are then used to update the

guess values for the number of trays in each section of the column.

Convergence is assumed when the difference between the deviation in the

number of theoretical stages is less than the set error limit.

4.3 Implementation of the Process Model-Based Controller

Once the system has been parameterized, the control actions can be

put to work. Control action is taken after a certain time step which is

set by the main program. The calculations involved are as follows:

(1) Determine the setpoints (y* and x*), and the number of trays in

each section(N and M) from the model parameter update.

(2) Measure the feed rate, composition and pressure (F, z, and P) from

the column.

(3) Calculate external flowrates required to obtain the desired

products.

D - F(z-x*)/(y*-x*) (4.21)

B - F - D. (4.22)

(4) Calculate recoveries for the desired products.

fl - Bx*/(Fz) (4.23)

f2 - B(l-x*)/(F(l-z)). (4.24)

(5) Calculate the new top and bottom temperatures.

Page 45: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

36

yVKi(Tt,P) + (l-y*)A2(Tt.P) - 1 (4.25)

x*Ki(Tb,P)+(l-x*)K2(Tb,P) - 1. (4.26)

(6) Solve equations (4.3) and (4.7) to solve for reflux ratio and

feed stage temperatures.

(7) Calculate the new liquid and vapor rates.

L* - RD (4.27)

LP* - F + L* (4.28)

VP* - LP*-B. (4.29)

(8) Implement control changes L* and VP* on column.

Figure 4.2 illustrates how the control subroutine (CONT) is structured.

CONT calls the subroutine DERC to obtain the Jacobian for the change,

DERC works similarly to DERP and it also calls FUNC to calculate the

recoveries and that generates the Jacobian. CONT uses the Jacobian in a

manner similar to PARM and obtains the required control actions which

are then implemented to the liquid and vapor rates.

Page 46: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

37

intiol data

call DERP for Jacobian

solve equation for deviation in parameter

(a)

Stan

call func for Jacobian 1 caJcD(l)«t B(2)

update N

caJl tunc

caJc A ( I . l ) & A( l . : )

updJic M

caJc AC.DcS;: AC.Z)

return

(b)

FIGURE 4.1 Flowsheets

a) Subroutine PARAM b) Subroutine DKRl'

Page 47: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

38

Stan

feed ill all data

call DERC

caJc control action for

update V & L

return

FIGURE 4.2 Flowsheet of subroutine CONT

Page 48: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 5

RESULTS AND DISCUSSION

The PMBC controller was tested on a simulation of a high purity

binary column with several setpoint changes and a variety of

disturbances. Table 5.1 shows the base case conditions with all the

values. The tests performed were: changes in the top and bottom

setpoints, disturbances in the feed rate and composition, variation in

the liquid and vapor with an increase or decrease in the bottom

setpoint, and we also compared how the controller behaves for a SOX

increase or decrease in the gain. In order to fully understand the

effect of these tests, the top and bottom product compositions were

observed during each test. Results from PMBC were qualitatively

compared with results from a similar high-purity column studied by

Luyben et al. (1988) using nonlinear djmamic matrix control (NLDMC).

In order to study the effects of changes in the setpoint for the

bottom light component composition (XSP), the value of XSP was increased

by 15X and the decreased by lOZ (it could not be decreased more than 10%

due to total reflux restrictions). Figure 5.1 shows the effects of an

increase in XSP on the LK composition in the bottoms product. Whereas,

it has no effect on the LK composition on the top product. From Figure

5.1 we can see that around the 10- and 15-minute mark it shows a

disturbance. This happens throughout the whole column. Figures 5.2 (a)

and (b) show the same effects on trays 5 and 8, and this was found to

occur throughout the whole column for every upset

39

Page 49: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

40

or disturbance tested. The effects of a decrease in XSP can be seen in

Figure 5.3 and again there is a disturbance at the 10- to 15-minute mark

and then the system reaches 95X of the steady state changes in about 5

time constants (process time constant is about 5 min). Once again there

is no significant change in the LK composition on the top product.

Effects of an increase in setpoint of the LK composition (YSP) can be

seen in Figures 5.4 (a) and (b). Figure 5.4 (a) shows the effect that

this change had on the LK composition in the bottoms and Figure 5.4 (b)

shows the effects on the top composition. Disturbance rejection caused

by a setpoint change in the top (YSP) causes a sharp drop in the bottoms

composition. This shows that the bottoms composition control is very

sensitive. The bottoms composition behaves in a similar way to a

decrease in the value of YSP. Figure 5.5 (b) shows the effect of a

decrease of YSP on the LK composition in the top of the column.

The next set of tests was done using a small upset in either XSP or

YSP along with a step change in the feed rate of 5, 10 or 15X. Figures

5.6 through 5.8 show how the LK component compositions in the bottoms

product for a small increase in XSP and for a 5, 10 or 15X increase in

feed rate, respectively. LK compositions for the top product are not

shown because there is less than a O.OOOIX change in that composition

during these tests. Similarly, Figures 5.9 and 5.10 show the behavior

of the LK composition on the bottom tray for a decrease in the feed rate

by 5. 10 or 15X. In all these cases the LK composition in the bottoms

behaves in an almost identical manner except that it reaches steady-

state faster in cases with higher feed rates. These tests were repeated

for a small increase in the value of YSP, Figures 5.11 through 5.13

Page 50: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

41

show the trend of the LK compositions in the bottoms product for an

increase in feed rate while Figures 5.14 through 5.16 show the trends

for a decrease in the feed rates. There was a strong similarity in the

results from each of these test for both the top and bottoms products.

The next set of disturbances studied were in the feed composition

of the LK. Disturbance of +5X and +10X was made in the feed composition

of the LK and the trends of the LK composition for the top and bottoms

product were studied. Figure 5.17 shows how the LK composition changes

in the bottoms and Figure 5.18 shows how it is affected in the top of

the column for a +5X step change in the feed composition. Similarly

Figures 5.19 and 5.20 show the trends for the bottoms and top,

respectively, for +10X step change.

Luyben et al. (1988) extensively compared linear and nonlinear DMC

for three sets of columns, the moderate purity column which is 99X and

IX LK in the top and bottom, respectively, the high purity column with

product purities of 99.9X and O.IX of the LK in the top and bottom,

respectively, and then the very high-purity column with impurities

down to 10 ppm. The column in study for this project falls in the high-

purity category, and so some of the results from this study were

quantitatively compared to their results, even though the system may not

be exactly the same. Figures 5.21 (a) and (b) and 5.22 (a) and (b) are

a comparison of the behavior of the HK on the top product for a +10X and

+5X step change in the feed composition. While Figures 5.23 (a) and (b)

and 5.24 (a) and (b) show the trend of LK on the bottoms tray for the

same changes, respectively. From both these figures it seems that in

Page 51: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

42

their column the controller had more of an effect on the top product

than this study. Their column also seems to show an initial disturbance

in the bottom tray like the one used in this study. Based on these

observations it seems that the PMBC is faster since it reaches 95X

steady state in 5 time constants while NLDMC takes 10 time constants,

also observed was that the PMBC gave a lot less upset than the NLDMC.

Effects of an increase or decrease in the bottom setpoint on the

liquid and vapor flowrate in the column are shown in Figures 5.25 (a)

and (b) and 5.26 (a) and (b), respectively. In both cases we can see

that the vapor rate is effected a lot more than the liquid rate, that

could be explained by the fact that both graphs are for an upset in the

bottoms setpoint. For a decrease in the setpoint both values increase

to compensate and then level off, however, for an increase they decrease

and then level off.

Figures 5.27 (a) and (b) prove that the controller has to be

carefully tuned to obtain the right results. In both the increase and

decrease the system becomes unstable and can no longer be controlled.

This goes to show that the PMBC is very sensitive to the control

parameters.

Page 52: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

TABLE 5.1 Data for PMBC base case

Xf

F

R

V

XSP

YSP

N

M

NT

K1

K2

0.3

4000

6000

7000

0.47864 E-3

0.99888

21.3

8.872

18

2.05

2.05

43

SYSTEM : C2 C4 MIXTURE

Page 53: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

44

>^ (fl u iJ

e o 4J U O

JO

a o cu CO

X

o VI

0) u o C C

o

O (U

tM

i n

UJ

:^ o (—1

(% 3noH) Mcaisodrioo iNBNOdrDO iHon

Page 54: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

1#

2.24.

2 . 2 2 -l{

y o JiS.

^ ' z Q. • -en O OL

5 O

»--UJ

z o a •-• >

^

5 U -J

2 .2

2 . 2 a

2.2B ,

2 . 2 2

2 .2

2 .16

2 . I d

2 . i a

2 .12

•J

r Q

O

a

UJ

O a u •— I c

45

—r-20 'lO

— 1 —

CO — I —

BO 100 120

TIMC (MIN)

a

2 1.3 -f

TrMC ( M I N )

b

FIGURE 5.2 Increase in XSP a) Effect on Tray 5 b) Effect on Tinv 8

Page 55: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

46

o

o -*

o r< »-

o o r-

o 03

O u

o -i

O n

^^ z 5 UJ

1-

r-l

n T

ray

o

n X

SP

o 0) V) (Q 0)

U 0)

CO

(4-1

o u u

3 E

ffe

ICU

RE

5

Uu

<% JlCiN) NCIilSOdltCO iN3NOdr*:X) iHOH

Page 56: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

I

47

C.Ci

li 0.0J.7B -

0.0-176 -

Q0.04.7A -

^O.GA72 -

B O.OA7 -1 CO

po.OAca -

§ o.OAea -•- 0 . 0< id4 -

z Z O.O.ifi2 H o

^ O.OAC -4 ^o.OAsa -I

•^O.OiSfl - I o

0.0-t?4. -J

0 . 0 4 J 2 -I r —T— 3 0

t

0 0 I I I

flO 100

T1»/.C (MIN)

a

1 2 0 l A O lao — I leo

9 9 . 9

SS 09 -

^ 99 .00 W

- 9 9 . 0 7 -J g ^. 9 9 . 2 0 -

^ 9 9 . 0 * -] UJ

^ 99 02 ->

O 99 .02 -

9 99 .01

99.S -r-A, a

T >

> I O 1

TlMC ( M I N )

b

1 a 18

FIGURE 5.4 E f f e c t of d e c r e a s e in YSP a) Tray 1 b) Top t r a y

Page 57: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

0.04S

in

go.0450 -§ 0 . 0 4 6 6 -O ^ 0 . 0 4 6 4 H UJ z O . 0 4 6 2 H O

% 0 .046 H

O0.045Q

g 0 . 0 4 5 6 -

"^0 .0454-

0.0452 4

99.9

A 99.09 H

UJ

2

99.00 -

99.07

-00 99.06 O Q.

^ 99.05 -

^ 9 9 . 0 4 -UJ

2 99.03 -

O gg.02 -. 99.01

99.0

48

20 40 I

60 —r~ 00

—I r 100 120

I 140 160 100

TIMC ( M I N )

1^

2 4 6 0 10 I

12 14 16 -J—

10

TIME ( M I N )

FIGURE 5.5 Effect of increase in YSP a) Tray 1 b) Top tray

Page 58: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

49

0 . 0 5

0.04.9S -

0 .04-96 -

0.04.94. -Ul

2 0.04-92 \ - / Z O 0.04.9 H t

p 0 .04 .88 H

Q 0 . 0 4 5 6 - I

1 0 . 0 4 8 4 . - I O

0 . 0 4 8 2

0 . 0 4 8 -

0 . 0 4 7 8 - — I — 20

—T" 4 0

—1— BO

T r "I 1 1 r T r BO 1C0

TIME (MIN)

1 2 0 140 160

FIGURE 5.6 I n c r e a s e i n XSP and 5X inc rease in feed r a t e ; Tray 1

Page 59: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

50

r\ r.n

0.04.39 -

0 .049B -

_ O.OAga -O ^O.OA92 H S ^ C.04.9 -8 ^..,o.OAee -

o *° 0.0- ie J.

p .04f i2 -

0 .04a -

O.OJ.78

TIMC (MIN)

FIGURE 5.7 Increase in XSP and lOX increase in feed rate; Tray 1

r. f\*^

Q •^O.OJ-SA -

t:0.0A92 -

o & o.oag -p ^o.ooc- -

^0.0-tse -o

8 •-O.O.i£2 4 I o Ij o.o-ie -

o.o«t~s — I —

20 A.O eo — I —

eo I I —

100 120 — I 1

I A O ICO

TIME (MIN)

FIGURE 5.8 Increase in XSP and 15X increase in feed rate; Tray 1

Page 60: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

51

y 0.04-98 -Q ^ 0 . 0 4 . 9 4 . H

t : 0 . 0 4 . 9 2 H en O 9: 0 .049 -

o . 0 4 e e -

^ 0 - 0 4 . B B O a 5 O.o-teA -

» -0 .04e2 g - I 0 . 0 4 S

0 . 0 4 . 7 8

2 0 I

4 0 CO OO 1 0 0

TIME ( M I M )

— I 1 2 0 1 4 0 ICO

FIGURE 5.9 Increase in XSP and lOZ decrease in feed rate; Tray 1

. ^ •0 .04 -9 3 -

• y 0 . 0 4 . 9 6 -O

^ 0 . 0 4 9 4 z Q t 0 . 0 4 9 2 -01 O 9: 0 .049 -

-I Z 0 . 0 4 Q 6

O , II °> O.U4-e4.

t - 0 . 0 4 e 2 -X -1 0 . 0 4 8 -

O . O 4 7 0

/ y

-I r :o

— I —

e o 8 0 1 0 0

Tlf^C ( M I N )

— I r i r o 1 4 0 i c ;

FIGURE 5.10 Increase in XSP and 15X decrease in feed rate; Tray 1

Page 61: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

52

0 . 0 4 7 9

C O . 0 4 7 8 -

•^ 0 . 0 4 7 7

r 0 . 0 4 7 0 -

^ 0 . 0 4 . 7 5 H

a t> 0 . 0 4 . 7 4 -a 5 0.04.73 A

o a 0 . 0 4 7 2 -

~1

0 .04 .71 -X o D 0 . 0 4 7 -

0 . 0 4 f i 9 — I — 2 0

— I — 4 0

~T r CO

— I —

eo 1O0 I Z O

T I M E ( M I N )

FIGURE 5.11 Increase in YSP and 5X increase in feed rate; Tray 1

0 . 0 4 7 9

^. /•• /-, ^r» o _ \i

y 0 . 0 4 7 7 -o

• ^ 0 . 0 4 7 0 -

C, t 0 . 0 4 7 S H

& 0 . 0 4 7 4 -

^. 0 . 0 4 7 2 -

2 0 . 0 4 7 2 H

d 5 0 . 0 4 7 1 -O

•- 0 . 0 4 7 -I c - I 0 . 0 4 f i 9 -

o.04£e 2 0 4 0

— I —

eo — I —

OO — I 1 1 r 1 0 0 i r o 1 AC

T I M E ( M I N )

FIGURE 5.12 Increase in YSP and lOZ increase in feed latc; Tr.TV 1

Page 62: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

53

o ti T "

o o * -

o CI

^^ u to

o ^

o r

4 ^ \

^ t:

v ^

u 2 1 -

Tray 1

• « 0)

feed rat

c

ease i

u u c

•*4

»4 i n r-l

P and

CO

rease in Y

o c

UJ oi

o • -

r -*

o o

r -^

o d

o> 03 -4 o

t o

in ID

-i O

o (% 31CV^) NOmSOdkVOO irONOdl-'OO iHOn

Page 63: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

54

\

v..

^—I—r on

o

ID Iv

O o I

o

o t

o

O *

o

O I

o

^ d j

'i O

IN (i3 -f O

a) m

d o 6

1—r-

C'

o

o n T -

o o

o OO

o u

o ^

o rt

- r

5 V w *

u 2 h-

.-(

e; Tray

i j (B

feed r

c . f t

0) w (tJ 0) k l

o

and

5X

e in YSP

V)

ncrea

lU

q d o

TlCi'-O NC1il50dk*X) irONOd^'iDO iHOH

i n

UJ

Page 64: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

55

g o d

o I

o

Ii 5 ' s ^ ? 5 5 ?! ' "J o q (.-) o 9 9 9 9 d 9 9 o o o o o o o o o :, TicvV NCiiisod^voa iN3NOd ' *oo man

-i

'^ O

o

n !3 O O

u H

(U iJ cfl

T3

(1) (fl ffl

u o (U

T3

o

T3 C

in

0)

(T3 0)

O c

i n

i n

Page 65: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

'4 O

o

n—r CO to

o o

I T 1 1 1 f' r4 fv nJ ?? •«*

=f=r ft to

5 5 Ii 3 g "-/ 3 O O O o' ^ ^ * 6 6 6 c o o

<% 31CV^) NO«ilSOdP*X) lN3NOdi'*:>a iHun

o fl

o o

-r

o o

-r

o o

T

o T -

"

O - r< T -

o - o ^

o ' tt)

o 03

O

o ' r

1

^

/ ^ i .

3:

Ui "«;

F

ray

H

0) 4J Cd V4

•d <u

M-l

c ••-1

0) en Cd

u 0) •0 »4 »n t - i

•0 C Cd

C • f l

0)

crea

s

r - (

9 ^ o • o

• •

o o

i n

o (—1 U4

56

Page 66: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

57

C O 4.73

^ 0 . 0 4 . 7 8 -

y 0 . 0 4 7 7 H

§ 0 . 0 4 . 7 6 -

2 0 . 0 4 7 5 -

Q S 0.04.74. -O % 0 .0473 -

0 .0472 -»-S 0.04.71 HI Z

2 0 — I — ' t o

I BO

— I — BO 1 0 0 1 2 0 1 4 0

T IMC ( M I N )

FIGURE 5.17 +5% Upset in feed composition; Tray 1

9 9 . 8 9

- 9 9 . e s -

V 9 9 . 8 7 -\

c/i 2 99.BB -

99.85 -

UJ

2 "• ' '^• '

2 99.83 -

O 9 9 . 8 2 -

9 9 . 8 1 -

9 9 . 8 2

-T -e

I

a — I — I O

— I — 1 1 — I 1 — I — I — 1 2 1 4 1 e 1 8

TIMC ( M I N )

FIGURE 5.18 +5X Upset in feed composition; Top Tray

Page 67: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

58

0.04 .79

0.04.7B

"«'0.04.77

^ 0 . 0 4 . 7 B

3^0.04.75

0.04 .74 -

^ 0 . 0 4 . 7 i

2o.04.72

0 0.04.71

•_ 0 . 0 4 7

y 0 . 0 4 e 9

0 . 0 4 e B -

i 0 . 0 4 e 7

^_o.04aB X g o . 0 4 e 5 - I

O.OAfiit

0 . 04 f l3 1 1 1 1 1 1 1 1 1 1 1 1 1 r r —

O 2 0 4 0 BO BO TOO 1 2 0 1 4 0 1 0 0

TIMC ( M I N )

FIGURE 5.19 +10Z Upset in feed composition; Tray 1

9 9 . 9

^ 9 9 . 6 6 -a C 9 9 . a s H

2 9 9 . 8 4 -\ z O a 9 9 . 8 3 H "5

8 o

9 9 . 8 2 -

9 9 . 8 1

9 9 . 8 -+ — I —

I O — I —

2 0

T i v r ( M I N )

— I —

.30 — 1 J O

FIGURE 5.20 +103: Upset in feed composition; Top Trav

Page 68: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

0 . 0 0 2

o.ooig -

2 0 . 0 0 1 B -

g

JC0.0017 -\

CO.OOIB -

59

Z 0 . 0 0 1 S -

0 .0014 . -

^ O . O O l 3 -»-X

3 0 . 0 0 1 2 -

0 . 0 0 1 1 -

0.001 2 0 4 0 6 0 BO 100

TIMC (MIN)

a

1 2 0 — 1 1 1 1 — 1 4 0 160 180

0.04.79

0.0470 -

^ 0 . 0 * 7 7 H Ui r^0.0*76 o ^ 0 . 0 4 7 3 -

gO.04.74 -

S0.0473H

2o.0472 H

0 0 . 0 4 - 7 1 O

K- 0 . 0 4 7 -

^ 0 . 0 4 6 9 -

g 0 . 0 4 G 0 -d o . 0 4 6 7 -O ^ 0 . 0 4 6 6 -X g 0 . 0 4 G 5 --J

0 . 0 4 6 4 -

0 . 0 4 6 3 1 6 0

FIGURE 5.21 Effect a of lOX upset in feed composition a) (1-XD) on top tray b) Tray 1

Page 69: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

60

- - 14 .0 O

T r T > r 1 r-

^ 12.0 - ; V

. /

<. 10.0 cc

§ 8 .0

^^.

*^NLDMC

a X I

6 .0 -L

eO.O 160.0 240 .0 320.0 400.0 480.0

TIME (MIN)

4 4 . 0

2 36.0 X

-T 2B.0 »-o -<• IZ u.

1 — r T — ' — r

2 0 . 0 -J o I

C3 1 2 . 0 X

4 . 0 I L

BO.O 1 6 0 . 0 2 4 0 . 0 3 2 0 . 0 4 0 0 . 0 4 8 0 . 0

TIME tKJN)

FIGURE 5.22 Effect a of lOZ upset in feed composition using rJLDMC a) (1-XD) on top tray b) Tray 1

Page 70: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

Ii

61

O.O02

O.OO J 19 -

o.ooie -

0 . 0 0 1 7 -

Vo.ooie -X o'o.oois -I I .'O.O014 -

0 . 0 0 1 3 -

O.0012 -

0 . 0 0 1 1 4

0 .001 t—r

0.0479

^ 0 . 0 4 7 0 -H ujO.0477 -_ j

§0.0476 H

= 0 . 0 4 7 5 -Q ^ 0 . 0 4 7 4 -O ^ 0 . 0 4 7 3 H O <->0.0472 -

i j jO.0471 -

a 0 .047 H

o 0 . 0 4 6 9 H

O 0 . 0 4 6 0 -

0 . 0 4 6 7 -

0.0466 4

—I r 2 0 eo

I

BO 1 0 0 1 2 0 1 4 0 leo 1 8 0

TWkCC ( M I f . ' )

a

60 00

TIMC ( M I N )

1 40

FIGURE 5.23 Effect a of 5Z upset in feed composition a) (1-XD) on top tray b) Tray 1

Page 71: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

62

Q X

I

20 .

0 1

LV

^ . LOMC.

CD X

80 ,

40 ..

0 1

NLDMC

0 30 60 90 120 TIME (MINUTES)

150 180

FIGURE 5.24 Effect a of 5X upset in feed con,position using NLDIU a) (1-XD) on top tray b) Tray 1

Page 72: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

63

TIMC (MIM)

a

1.90

u

\ C".

o • UI

< a' Q

X O c t >

I . t c - r -

O 2 0 4 0 eo Tl?/.C ( ' . ' I* . ! )

?

eo i c ;

FIGURE 5.25 Effect of an increase in XSP a) Liquid rate b) Vapor rate

Page 73: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

1 . 4 S

o Ui \ (A

UI

a:

9

O 3

64

O BO

TIJ/.C (MtM)

eo 1 0 0

1.9

' J UJ VI

t/1 UJ

d

or

O

O

5

I.OS A

1.B

1.75 H

1.7

i.es

i.e -

1.55 -

o 2 0 —r— 4 0 eo

Tll/.C (»XIN>

eo I C O

FIGURE 5.26 Effect of a decrease in XSP a) Liquid rate b) Vapor rale

Page 74: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

0.075

UI

0.11

0.1 -

0.09 -

o c

S' c a « 8 -

Ul

c

o.oc

0.07

O.OB

0.C5

y.

c O.C.3 -

O

TWAZ, (MIN)

a

65

T'M^ (*'"N)

FIGURE 5.27 Effect of a change in gain a) Increase b) Decrease

Page 75: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 6

DEVELOPMENT AND VERIFICATION OF A STEADY-STATE

APPROXIMATE MODEL OF A DISTILLATION COLUMN

WITH A SIDESTREAM DRAWOFF

6.1 Model Derivation

This material presents the general development of an approximate

model of a distillation column with a sidestream drawoff. A

relationship between the concentration of any given component and the

stage number can be developed using the calculus of finite differences

as follows:

write a component balance around stage n+1 for any component to obtain

Lr,+2Xn+2 + V^Yn - Ln+lX^+i + Vn+i^n^l (6.1)

since Y^-K^Xn and Yn+i-K^+iXn+i

then equation (6.1) becomes

Ln+2Xn+2 + V^K^Xn - l^+lXn+l + "^u-^l^n-^l^-^l- (6-2)

Rearranging gives

Xn+2 - [(Kn+lVn+l/Ln+2) + (Ln+l/Ln+2)]Xn-l + (^'^n/^^2)^n " 0.(6.3)

To simplify things the distribution coefficient and phase rates must be

assumed constant within the column section under consideration. Making

these assumptions and writing the equation in terms of a linear operator

form gives

66

Page 76: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

67

[E2 . (KV/L + 1)E + KV/L]Xn - 0 (6.4)

or

(E - KV/L)(E - l)Xn - 0 (55)

where E defined as the linear operator.

Let S and SA represent the two roots

S - KV/L and SA - 1.0.

The solution is then

Xn - C (S)n + CA. (6.6)

To implement this on our column the column is divided into three

sections as shown in Figure 6.1. Based on these assumptions and Figure

6.1 the following equations can be written for the different sections:

section I

Xi - CiSi^ + C2 (6.7)

section II

XN - C3S2N + C4 (6.8)

section III

XM - C5S3M + C6 (6.9)

where I, N, and M are the number of trays in sections I, II and III,

respectively, and S is the separation factor and C are integration

constants. The equation for the separation factor for each section is:

Page 77: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

68

SI - KiVi/Li I - 1,2.3. ^6.10)

The constants in equation (6.7) can be eliminated by simultaneously

solving component balances around the condenser and the top tray.

Similarly constants in equation (6.9) can be determined using a

component balance around the reboiler and tray 1 or bottom most tray.

Then C3 and C4 can be determined by doing component balances on the tray

above the feed tray and below the sidestream drawoff tray.

The final forms of these equations are as follows:

section I

Xi-(l-f-g)A{Li(l/Ki.l)/V){SiI-i-l)/KiD(l/Si-l)

(l-f-g)A/KiD (6.11)

section III

XM-[fA/(B(l-S3)){l-(K3V+B)/L3){S3M-l-l))]+fA/B (6.12)

section II

XN-(l/(l-S2")(A/F.gA/G)(S2N.l) + A/F. (6.13)

All the nomenclature is defined in appendix A. The product rates f and

g for the bottoms and sidestream drawoff respectively can be obtained by

doing component balances on the feed tray and sidestream drawoff tray

and solving them simultaneously. The two product rates are as

follows:

Page 78: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

69

(aOi+a+VK2di/G+L2/G+VK2/G+l] [ -L2dKf/K2-L2Kf/K2+VKf+L3+F] -

[-L2/G](aOi+a+(di+l)VK2/F]

^" (6 .14)

(VK3( -1)/B][aOi+a+VK2di/G+L2/G+VKg/G+l]-[aOi+a]

(-L2d/G]

and

(aOi+a+(di+l)VK2/F]-[aOi+a)f

S" . (6.15)

(aOi+a+(dx+l)VK2/G+L2/G+l]

and from a material balance

dd- 1 - f - g (6.16)

where d - (S2-l)/(l-S2") (6.17)

dl - (S2"-l)/(l-S2") (6.18)

0 - (S3»-2-l)/(l.S3)(l.(VK3+B)/L3) (6.19)

01 - Li(Sil-i-l)/(l/Si-l)(l/Ki-l)/V (6.20)

a - Li/(Kx D). (6.21)

The solutions of equations (6.14), (6.15) and (6.16) will result in

the required recoveries of component I in each of the exit stream.

Section 6.2 discusses how the program that solves these equations is

implemented along with parameterization of the system.

Page 79: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

70

6.2 Implementation of the Approximate Model

6.2.1 Data Entry

The first step in implementing the approximate model is to

parameterize the model using initial guesses for the number of

theoretical stages in each of the sections. The temperatures and

pressures for the sections are set by the distillate, sidestream, feed

and bottoms temperatures and pressure, respectively. Values for the

feed rate, bottoms rate, boilup rate, sidestream drawoff rate and the

reflux rate are read into the program. All other values can be obtained

from material balances. The program is also given the values of the

recoveries in the bottoms, sidestream and the distillate.

6.2.2 Parameterization

To parameterize the column the main program calls the subroutine

PARAM that calculates the number of theoretical stages in each section

of the column. This subroutine uses the same approach as described for

the parameterization of the SB model, used in the high purity column

control in chapter 4, section 4.2. Only for this system there are three

parameters instead of two. Figure 4.1 is a flowsheet of the subroutines

involved in parameterizing the system. Subroutine EVAL calculates the

function values for the Jacobian. The function values are the errors in

the recovery equations (6.14) through (6.16). That is, since the number

of theoretical stages are unknown equations (6.14) through (6.16) are

not exact, even though all the other values are known. Subroutine

Page 80: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

71

DERP numerically generates the full Jacobian using equation (4.18). The

Jacobian forms a 3 X 3 matrix which is converted into the following set

of equations by Subroutine PARAM

A(1.1)DI + A(1.2)DN + A(1,3)DM - -B(l) (6.22)

A(2.1)DI + A(2,2)DN + A(2.3)DM - -B(2) (6.23)

A(3.1)DI + A(3.2)DN + A(3.3)DM - -B(3) (6.24)

where Dl. DN, and DM are the changes in the number of theoretical

stages in each section of the column.

These equations are solved by Cramer's rule to give the deviation

in the number of theoretical stages in each section. The entire process

is repeated until the deviations become acceptably small.

Parameterization can be done using either the LK or the HK. To be

consistent the recoveries for each component are used to parameterize

the model. That is, number of theoretical stages of each section

obtained from each component is averaged to give the number of

theoretical stages for each section of the column.

6.2.3 Implementation

Once the system has been parameterized, then the approximate model

can be used to estimate fractional recoveries for a variety of

conditions. Figures 6.2 (a) and (b) are the flowsheets of the program

that evaluate the product recoveries f. g, and d. The main part of the

program is used to call the evaluating subroutine EVAL, read in the data

as stated in the first paragraph of this section, and print out the

results. Subroutine EVAL calls subroutine CONST and KVAL for each

component. Subroutine KVAL calculates the K-values using equilibrium

Page 81: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

72

constants for each component. Whereas subrotine CONST calculate the

constant 0, d. a, etc., asing equations (6.17) through (6.21). Finally,

subroutine EVAL solves equations (6.14) through (6.16) to obtain the

required recovery estimates. These values are then compared in the next

section for a specified system with values obtained from a commercial

package.

6.3 Approximate Model Verification

A ^1 Model

The system that was studied is a binary with ethane as the light

key (LK) component and propane as the heavy key component (HK). A

commercial program was used to calculate the initial recoveries by which

the approximate model was parameterized. Table 6.1 shows the

comparison between the recoveries of the approximate model and the

commercial program.

6.3.2 InJM'al Parameters

Table 6.2 shows the parameters used in the model and in the

commercial program. A comparison between the model and the commercial

design package was performed by making changes in the reflux rates, the

sidestream drawoff rates, and the boilup rates.

6.3.3 Description of the Data Tables

The three values predicted by the approximate model were the

recoveries in the distillate, sidestream drawoff and bottoms. These

values and the process gains (K) for each of the changes predicted by

Page 82: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

73

the approximate model and the commercial package were compared. Process

gain which is referred to as the gain in the rest of this section is

evaluated as follows:

Kc-Change in recovery (f. g, or d)/Change in (L, G. or V) (6.25)

Tables 6.3 (a) and (b) show a comparison of the recoveries when the

reflux rate is increased or decreased by 3Z and Tables 6.3 (c) and (d)

show a comparison of the gain caused by these changes in both the model

and the commercial program. Tables 6.4 (a) and (b) are the comparisons

for a 3Z increase and decrease in the sidestream drawoff rate, while

Tables 6.4 (c) and (d) are gains for the increase and decrease in the

sidestream drawoff rates. Similarly. Tables 6.5 (a) and (b) are the

comparisons for a 3Z change in the boilup rate and Tables 6.5 (c) and

(d) show the slopes for the changes.

6,3.4 Case Study for Process Gain

Tho process gairt p1- icts the direction of change of the measured

value in comparison to the change in a manipulated variable, the sign of

the gains is extremely important because it also predicts the future

values of the liquid and vapor compositions on each tray. For instance,

if changes caused by a change in the reflux rate in both systems are

studied; then logically for an increase in the reflux rate, it would be

expected that the recovery in the distillate and sidestream drawoff to

increase for the LK and decrease for the HK, indicatingP°^^t^"^® gains

for the LK and negative for the HK. Similarly the sign of the gains is

expected to be the same for a decrease in the reflux rate, however, from

Tables 6.3 (c) and (d) we can see that while the model

Page 83: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

74

seems to follow this expected result, whereas, the commercial design

package differs in some places. One of the reasons for this difference

in results could be due to the equilibrium package used by the

commercial program, since there is no technique to duplicate the exact

package and it may not be well suited for this system. Also the values

in certain cases are so small that a minor roundoff error in the

commercial program could have an effect on the sign of the gain.

6.3.5 Conclusions

Based on these comparisons we can conclude that the extension of

the Smith and Brinkley approximate model to include the sidestream

drawoff can be used as an independent approximate model for a

distillation column with sidestream drawoff, and also for further

control studies.

Page 84: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

II

III

75

D

^

B

FIGURE 6.1 Split of the distillation column with a drawoff sidestream

Page 85: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

76

Read in all data

Yes Parameterize

no

Evaluate

rccoveries

Print results

End

Do # of comp.

Calc. K-Values

Calc. constants

Other calcs.

Calc. f,g. & d

FIGURE 6.2 Flowsheets for approximate model

a) Main program b) Subroutine EVAL

Page 86: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

77

0) •o o E

0) (fl

E

X o Wi a a CO u o

LU

> > < LLt

O O

o o

T—

r m (D ^ CO o

CO o IO r T -

o

O) C\J V —

CO CO ^

o o

UJ

o o

00 CD

CO

C\J

d o d

w

3 V) 0) i-t

a; en CO u a> (0 CO

CQ UJ

o cc CL

o o

CO CO o> (O CD O O

-^ CO o y—

CO y—

o

r CM o CNJ CO h-o

U -J OQ <

I

o LU a o

r CJ o o 00 o

T —

o CO 00 y—

CD a> CO CO r

O)

Page 87: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

TABLE 6.2 Data used in the comparison tests

CASE STUDIED C2 - C3 MIXTURE

78

1.556 mole/sec

0.2778 mole/sec

0.70056 moles/sec

0.7223 moles/sec

L(1)

•R

Tf

Tb

R

Pf

Pb

0.32478 moles/sec

18.3 DEGF

53.6 DEG F

108.6 DEGF

254.10

254.3 Psia

254.6 Psia

Page 88: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

79

TABLES 6.3 Recoveries and Process gains for change in reflux rate a) Recovery for 3Z increase b) Recovery for 3Z decrease

f

g

d

LIGHT KEY

MODEL

0.077337

0.18636

0.73630

COMM PROG.

0.084423

0.18175

0.733827

HEAVY KEY

MODEL

0.76862

0.21815

0.013229

COMM PROG.

0.808164

0.179725

0.012111

f

g

d

MODEL

0.082776

0.18562

0.73160

a

COMM PROG

0.089460

0.175913

0.734627

MODEL

0.78113

0.20856

0.010307

COMM PROG

0.81915

0.170305

0.010545

Page 89: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

80

o u * u X D

.—t (4-4

<U u c

H- *

<u bO c c3

X O

V.I

o (4-1

w c

.^ a bO

to w (U o o u a. •o c «0

tfl o

•—1

u o > o o <u

0:2

<U to «0 0) V4 O C

.^

>< r->

V4

o (4-1

c .1-1

CO bO

to to o o o S-i

Ou,

/ " N

CJ

<u to CO (U Ul

o 0)

•D

X r->

>-i

o ( M

c H-t

c bO

to to o u o i-t

a.

^^ •o

r^

> UJ

> > < LU

X

> UJ ^ IH

O _ j

o o cc CL : ^

IE o o

_J UJ Q

o 2

d

PR

O

^

^

o o

_J UJ Q

O 2

in CD CO CNJ

o

.00

o

CO CO r

.00

0

o 1

.00

00

71

5

1

^r^

37

66

-

o o o CD

1

"D

CD h« CO CO

o o o <D

cn CO CO

00

1

o d

18

97

00

0

o o

CNJ

99

7

o

00

0

o o

cn u

^ CNJ TT CO O O

.00

o 1

CNJ

o CO TT TT O O O O

d

51

28

00

0

o o

66

7

CD O O O O

o

•D •D

o o DC 0 .

o o

Q O

O O CC CL

o o

UJ Q o

CO

CO

o o o o

CD o CO r o o o

CNJ

o o o o

eg CO CO r o o o o

CNJ CD TT CO T —

o o o

CD CO CO

r o o o o

CvJ CO Gi CO y—

o o o

in cn CO CO o o o o

o o o

Gi CO r o o o o

o o o o

• D

CNJ

CD O o o o

•D •D

Page 90: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

81

e CO 0) U 4J Vi 0)

-O •H Vi

c •H

(U bO C CO

,C o >-l o

(4-1

c CO b O

(0 (A a) o o u

•d C CO (U

to to 0) M

•H M (4-1 0) (4-1

> 9 O 15 O (0

VO

0) (U CO to CO to 0) 0) M M o o C 0)

« »>« m m

o o IM (4-1

u u > > o o o o (U (U

to x>

> •

UJ

> <

m X

o o DC DL

o O

> UJ

X o

UJ Q o

o DC CL

O O

UJ Q O

C O C\J

CO

d

CNJ CNJ

o C O

CD in o in CJ)

o

CO

r CO CNJ 00 o

T t 00

cn

o cn r o CNJ

CD

o CO

d

CO o o CO

CD 00

o o d

cn

CO

CO

o d

in CO C O CO CN]

cn in

CO

O O DC CL

O O

UJ Q O

CO

O O CC DL

o o

UJ Q O

CO

o cn o CO

CO in cn CD

Tt CNJ

o

CvJ

CJ)

o CO

in o o o d

o o cn eg d

CO

CD

d

CO in CO CO r o

in Tt cn CD CO y—

CJ)

Tt

ro

CNJ

o CNJ CJ)

in evj o CO

C7)

Page 91: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

82

E

<u 4-) to

T) •r-l to

Q) bC C (0

x: u u o

(4-1

c •.-( CO bO

to to <u o o u

( X I

n c <0

to <u

• I - )

l-l

<u > o CJ 0) o

4J (0 ^

(4-1 tw o ? (0 V-i

-o

(U to (0 <u >-l

o c • r ^

« ro

u o

(4-1

c •r-(

(0 bO

(0 (0 (U o o u

0-,

^ \ o

o to CO <u u o (U

T3

>< C*1

M o

(4-1

c •»-( CO bO

(0 to Q) o o V-i

PL.

^-\ •o

UJ .-J

<

> UJ ^

> -> < UJ X

> UJ ^

GHT

_ j

O o DC CL

^

o o

_J UJ Q O :E

d o DC CL

^ ^ o o

_J UJ Q O 2

CJ) T —

in CNJ o

.00

o 1

CO CO r

o

.00

o 1

r CJ) CD

.000:

o 1

h-

0767

o

.00

o 1

^ ^ •D

C D C D • * "

O o o d

i n GO

0001

d

r

953

001

o o

!003

0002

d

CJ) TJ

CJ) r o o o

.00

o 1

r CD o o o

.00

o 1

CO

722

000

o o

1237

o

.00

o •

TD TJ

o

o o DC CL

o o

UJ Q O

O O CC CL

O o

UJ Q O

CO

o CO h-o o o o

CO CO in T —

o o o

CO

o o o

c\j 00 r o o o o

Tt CO o o o o

in CO

o o o

•00 (D o o o o o d

CO O r C\J o o o

CO CO o o o o o o

CO

eg o o o

CO cn CJ)

o o o

cn • D

CsJ

O O O

TD TJ

Page 92: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

83

(U 4J CO U

a. r-l •H O

U3

(U bO C CO

Xi O

M O

(+-I to C <o

•f-» to (0 CO bO (U Vi Vi Oi o o u

PL4

•d c CO

to (U

•H (1) > o o (U

i n

vo

Ui

CQ < H

O C

• H

Oi Vi CO (U >-i O (U

ro ro

U U O O

(4-1 (4-1

M CD > O

o et;

M (U > O o 0)

to X>

> UJ iic: > -

EA

V

X

> UJ ii:: H X O _J

O o DC CL

IE :E o o

_J UJ C2l

O S

d o DC OL

2 2 o o

_J UJ Q O S

i n CD r o 00

o

CNJ CNJ

CD r o

Tt CO eo cn o CD o o

CD CO

cn CD o o

-

r o T —

CD r • • —

o

CNJ

CJ

CNJ

O

CD CO O T —

00

O

r 00 CD OO T —

o

CD

CO T f CNJ CD —

O

o •

CNJ C D CNJ CO

O

O

CD in CM o 00 i n r o

CD

CO Tt r o

TJ

CD O DC Q.

O O

UJ Q o

o o DC CL

O O

UJ Q O

r i n CD CD T —

T f CD Tt CD r C O

d

Gi

in CD o o

T t

in CNJ CO

T t CNJ

o CNJ

in C O CvJ cn o

CO

CD

o CO

in CvJ

o o d

Tf CD

eg

CO Tt CNJ CD O

O O in CO T—

CD in eg eg r^

cn

Page 93: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

84

TABLE 6.5 Recoveries and Process gains for change in boilup rate c) Process gain for 3X increase d) Process gain for 3X decrease

df

dg

dd

LIGHT KEY

MODEL

-0.0001396

0.00001102

-0.00001286

COMM PROG.

-0.000333

-0.000000615

0.0003558

HEAVY KEY

MODEL

-0.00009821

0.00007782

0.00002036

COMM PROG.

-0.000114

0.0000138

-0.00003757

df

dg

dd

MODEL

-0.000159

0.00001244

-0.0001462

COMM PROG

-0.00007587

-0.000005196

-0.009314

C

MODEL

-0.00009821

0.00007962

0.00001871

COMM PROG

-0.00000495

-0.00001839

0.00008633

Page 94: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

CHAPTER 7

CONCLUSIONS AND RECOMMENDATIONS

7.1 Conclusions

7.1.1 PMBC

Based on the following conclusions PMBC is an excellent strategy

for controlling high purity columns.

(1) In a qualitative comparison to NLDMC used by Luyben et.al. (1988),

PMBC performs better.

(2) PMBC is also almost twice as fast as the NLDMC and also the upset

due to the disturbance is a lot less in the PMBC column.

(3) Similar to Luyben's observation, we also observed that the bottoms

product response time is much more sensitive than the top to the

various upsets and changes.

(4) A very strong similarity was found in the response graphs for all

the tests that were done. That is, for any disturbance or step

change in which ever direction, the path changes slightly, but on

the overall the response path still remains the same.

7.1.2 Sidestream Approximate Model

This approximate model is an extension of the Smith and Brinkley

approximate model for a distillation column to include sidestream

drawoffs. It is computational easy to implement and compares very well

with commercial packages currently in use.

85

Page 95: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

86

7.2 Recommendations

Recommendation for continued research in PMBC for high purity

columns should include:

(1) Further exact comparison with other nonlinear control techniques

such as djmamic matrix control (DMC) and internal model control

(IMC).

(2) Extension of this simulator to include multicomponent columns.

Further research on the approximate model should include:

(a) More detailed validation using other commercial packages.

(b) Update the current approximate model to include a vapor

sidestream.

(c) Adding parameters to include pumparounds on the drawoff streams.

(d) Implement this approximate model along with a distillation column

simulator that has a sidestream drawoff.

Page 96: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

LIST OF REFERENCES

1. Alatiqi, I.M., and Luyben, W.L., "Alternative Distillation Configurations for Separating Ternary Mixtures with Small Concentrations of Intermidiate in the Feed," Ind. Eng. Cliem. Proc. Pes. Dev.. v24 (1986).

2. Bryan, K.E., Design and Control of a Heat Integrated Distillation Train, M.S. Thesis, TTU, Lubbock, TX (1985).

3. Chimowitz, E.H., Anderson, T.F., and Macchietto, S., "Dynamic Multicomponent Distillation Using Thermodynamic Models," Chem. Engng. Sci.. v40, no 10 (1985).

4. Cott, B.J., Reilly, P.M., and Sullivan, G.R., "Selection Techniques for Process Model Based Controllers," Presentation at AIChE Meeting. July 1986.

5. Doukas, P.N., and Luyben, W.L., "Control of an Energy-Conserving Prefractionators/Sidestream Column Distillation System," Ind. Eng. Chem. Proc. Pes. Dev.. v20, (1981).

6. Funentes. C., and Luyben, W.L., "Control of High-Purity Distillation Columns," Ind. Eng. Chem. Proc. Pes. Dev.. v22 (1983).

7. Georgiou, A., Georgakis. C., and Luyben, W.L., "Nonlinear Pynamic Matrix Control for High-Purity Columns," AIChE Journal. (1988).

8. Holland, C.P., and Liapis, A.I., Computer Methods for Solving Dynamic Separations Problems. McGraw-Hill, New York, (1983).

9. Huckaba, C.E., May, F.P., and Franke. F.R., "An Analysis of Transient Conditions in Continous Pistillation Operation," AIChE Symposium Series. v46, n59 (1963).

10. Lamb, P.E., Pigford, R.L., and Rippin, P.W.T., "Pynamic Responses and Analouge Simulation of Pistillation Columns," Chem. Eng. Prog. Sym. Ser. . 57, (1961).

11. Levy, R.E., Foss, A.S., and Gren, E.A., "Response Modes of a Binary Pistillation Column," I & E.G. Fundamentals. vl8, n4, (1969).

12. Luyben, W.L., Process Modelling. Simulation, and Control for Chemical Engineers. McGraw Hill, New York (1973).

13. Luyben, W.L., "10 Schemes to Control Pistillation Columns with Sidestream Prawoffs," ISA Journal. vl3, n7 (1966).

87

Page 97: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

88 14 Martin-Sanchez, J.M., "Adaptive Predictive Control Systems,"

U.S.A. patent no.4, 197,576 (1976).

15. Martin-Sanchez, J.M., and Shah, S.L., "Multivariable Adaptive Predictive Control of Binary Distillation Column," Automatica. v20, n5 (1984).

16 Morari, M., and Economu, C.G., "Internal Model Control. 5. Extension to Nonlinear Systems," Ind. Eng. Chem. Proc. Des. Dev.. v25 (1986).

17 Rademaker, 0., Rijnsdrop, J.E., and Maarlveld, A., Dynamics and Control of Continous Distillation Units. Elsevier, Amsterdam (1975).

18. Reid, R.C., Prausnitz, J.M., and Polling, B.E., The Properties of Gases and Liquids. Mc-Graw Hill, New York (1987).

19. Roffel, B., and Fontein, H.J., "Constraint Control of Distillation Processes, "Chem. Eng. Science, v34 (1979).

20. Smith, B.D., and Brinkley, W.K., "General Short-Cut Equation for Equilibrium Stage Process," AIChE Journal. Sept. (1960).

21. Sourisseau, J., and Doherty, M.F., "On Dynamics of Distillation Process-IV. Uniqueness and Stability of the Steady State in Homogenous Continous Distillation," Chem. Engng. Sci.. v37, (1982)

22. Tyreus, B., and Luyben, W.L., "Control of a Binary Distillation Column with a Sidestream Drawoff," Ind. Eng. Proc. Des. Dev.. vl4 (1970).

23. Yu, C C , and Luyben, W.L. , "Use of Multivariable Temperatures for the Control of Multicomponent Distillation Columns," Ind. Eng. Chem. Proc Des. Dev.. v23 (1984).

Page 98: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

APPENDIX A

LISTING OF THE COMPUTER CODE FOR PROCESS MODEL-BASED

CONTROL OF HIGH PURITY COLUMN

89

Page 99: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

90

c********************************************************************* C*** PROGRAM FOR THE SIMULATION *•* C*** AND PROCESS MODEL BASED CONTROL *** C*** OF HIGH PURITY COLUMNS *** C*** *** C*** PROGRAMMER: RUPAK SINHA (B.S. CHE) **• C*********************************** **•*****••*•*••*******•******•****

c THIS PROGRAM FIRST SIMULATES A BINARY HIGH PURITY COLUMN AND THEN

PARAMETRIZES THE SMITH AND BRINKLEY APPROXIMATE MODEL TO OBTAIN THE NUMBER OF THEORETICAL STAGES IN THE WHOLE COLUMN AND THIS APPROXIMATE MODEL IS USED TO CONTROL THE COLUMN.

C C C C C C C C C C c**********************************************************************

THE SYSTFJ1 STUDIED WAS A BINARY MIXTURE OF 02 - Ot WITH 30X C2 AND 702 a*. RANGE-KUTTA METHOD WAS USED TO INTEGRATE THE ODE'S. THE EQUILIBRIUM CALULATIONS ARE DONE USING A LINEARLY VARYING CONSTANT RELATIVE VOLATILITY.

C C C C C C C c c C C C C c c C c c c c c c c c C c c c c c c c c c c

NOMENCLATURE X - THE LIQUID COMPOSITION (MOLES) Y - VAPOR COMPOSITION (MOLES) DYDX - IS THE ODE FOR THE COMPONENT BALANCE ON EACH TRAY TAU - ARE THE TIME CONSTANTS FOR THE CONTROL LAW K - ARE THE EQUILIBRIUM CONSTANTS TFC - TEMPERATURE OF THE FEED IN THE COLUMN (DEG F) TBC - TEMPERATURE IN THE BOTTOM OF THE COLUMN (DEG F) TTC - TEMPERATURE IN THE TOP OF THE COLUMN (DEG F) PC - PRESSURE IN THE COLUMN (PSIA) XF - COMPOSITION OF THE FEED (MOLES) F - FEED RATE (MOLES/SEC) R - REFLUX RATE (MOLES/SEC) V - BOILUP RATE (MOLES/SEC) XB - LIGHT COMPOSITION IN THE BOTTOM (MOLES) YD - LIGHT COMPOSITION IN THE TOP OF THE COLUMN (MOLES) NP - NUMBER OF THEORETICAL TRAYS IN THE WHOLE COLUMN MP - NUMBER OF THEORETICAL TRAYS IN THE STRIPPING SECTION NT - TOTAL NUMBER OF TRAYS IN THE COLUMN ALPHA - CONSTANT RELATIVE VOLATILITY KI & K2 - GAINS FOR THE CONTROL LAW F.RLIM - ERROR LIMIT FOR CONVERGENCE NITR - TOTAL NUMBER OF ITERATIONS HWS - WEIR HEIGHT IN THE STRIPPING SECTION (FT) MUR - WEIR HEIGHT IN THE RECTIRTING SECTION (FT) XLWS - WEIR LENGTH IN THE STRIPPING SECTION (FT) XIWR - WEIR LENGTH IN THE RECTIFYING SECTION (FT) DTS - DIAMETER OF THE COLUMN IN THE STRIPPING SECTION (FT) DTR - DIAMETER OF THE COLUMN IN THE RECTIFYING SECTION (FT)

DEN - DENSITY OF THE COMPONENTS VR - VOLUME OF THE REBOILER (FT3) CAY1.CAY2.CAY3. & CAY^ ARE THE INTERMIDIATE CALULATIONS FOR

THE RUNGE-KUTTA METHOD. T - TIME (SEC) DT - STEP CHANCE

Page 100: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

91

C XSP - SETPOINT FOR THE BOTTOM COMPOSITION C YSP - SETPOINT FOR THE TOP COMPOSITION C ALL OTHER VARIABLES ARE DEFINED AS THEY APPEAR IN THE PROGRAM.

C MAIN PROGRAM C

C

C c c

c c c

c c

c c c

IMPLICIT REAL*8(A-H.0-Z) DIMENSION XM(50).X(50).Y(IOO),DYDX(100),TAU(2) DIMENSION CAY1(100).CAY2(100).CAY3(100).CAY4(100).Y1(100) COMMON /ONE/DC. BC, XC. YC,TFC. TTC, TBC. PC. FC. ZC, KT. KC COMMON /TWO/ ERLIM.NITR,K1.K2.TAU.XINT.YINT.DI.ITYPE COMMON /ON9/ALFA(50),NT.R.V,F.XF.NF.DEN,HWS,HWR,XLUS,XLWR,DTS.DTR COMMON /TW9/ XLL(50).XB.YD.VR.VA.YC1(50) REAL*8 L1.NP.MP.NA.M1.K1(2),K2(2).KT(2).KC(2)

READ IN SOME OF THE CONTROLLER DATA

CALL DATAIN

INITIAL DATA FOR THE COLUMN

XB-.A786AE-3 Y D - . 9 9 8 8 8 NTRAYS-16 NT-NTRAYS+2

NF IS THE FEED TRAY

NF-10 THE LARGEST AND SMALLEST VALUE FOR THE CONSTANT RELATIVE

VOLATILITY

AT-A.56 A B - 4 . 0 5 BETA - 0 . GAM - l . O D - 0 1 DA-(AT-AB) /17 . DO 77 I - l . N T

77 ALFA(1)-AB+DA*FL0AT(I-1) R - 6 0 0 0 . 0 / 3 6 0 0 . V - 7 0 0 0 . 0 0 / 3 6 0 0 . FO - 3 4 0 0 . / 3 6 0 0 . FN - A 0 8 0 . / 3 6 0 0 . XO - 0 . 3 XN - 0 . 3 5 F-BETA*FN + (1-BETA)*F0 XF-GAM*XN+(1-GAM)*X0 DEN-0.9 VR-.120. VA-VR H U S - 1 . / 6 . HWR-HWS XLWS-8.6 XLWR-6.8 D T S - 1 0 . 5

Page 101: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

92

DTR-8.5

DO 821 I-l.NT

821 READ 822.Y(I)

822 FORMAT( E12.5)

PRINT 838.(Y(I).I-l.NT) 838 FORMAT( U\i YI-.5E12.5)

T-O.O

NE-NT

C TMAXO IS THE STEP SIZE FOR THE CONTROLLER

C AND INTEGRATOR.

TMAXO-60.

DI-120.

C P IS THE INTEGRATION FACTOR FOR RUNGA-KUTTA C

P-.OOOl VL-V

DO 1000 II-1.180

TMAX-TMAXO*FLOAT(II)

FC-F

ZC-XF

BC-FC+R-V

DC-V-R

XC-Y(l)

YC-Y(NT)

TFC-40.

TTC-8.

TBC-118.

PC-254.

,\.SI'-0.6 786/.D.03

YSP-.99890

Z1-(YC*DC+XC*BC)*30./((YC*DC+XC*BC)*30.+44.*((1.-YC)*DC+(1.-XC)*BC

D) ZE-Zl/30./(Zl/30.+(l.-Zl)/4<..)

FE-(YC*DC+XC*BC)/ZE

VI-V

Ll-R

NP-21.3

MP-8.872

C

C CALL THE PARAMETERIZATION PROGRAM TO PARAMETERIZE THE SIMITH AND

C BRINKLEY APPROXIMATE MODEL

C

CALL PAKAM(NP.MP.Vl.Ll)

C IF(I.NE.55)STOP

N6-NP

Ml-MP

C

C CALL TWE CONTROLLER FOR UPDATED VALUES OF THE VAPOR AND

C LIQUID FLOWRATE OF THE COLUMN

C

CALL CONT(NA.Ml.XSP.YSP.VI.Ll)

R-Ll

V-Vl

C CALL SUBROUTINE TO CALCULATE THE INTIAL DYDX FOR THE SYSTEM

C

Page 102: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

93

1 CALL F'X(T.Y.DYDX) C

C START THE STEP SIZE CALCULATOR FOR THE RUNGE-KUTTA METHOD C

DDD-DYDX(l) IM-1 IF(DABS(DyDX(l)).LT.1.E-10)DDD-1.E-10 DXM-DABS^*Y(1)/DDD) DO 2 1-2.NE IF(DABS(DYDX(I)).LT.1.E-10)TEST-1.E20 IF(DABS(DYDX(l)).LT.l.E-10)GO TO 2 TEST-DABS(P*Y(I)/DYDX(I)) IF (DABS(TEST).LT.DXM)IM-I

2 IF(DABS(TEST).LT.DXM)DXM-TEST DT-DXM IF(DT.GT.600.)DT-600. XT-DT+T IF(XT.GT.TMAX)DT-TMAX-T

C C START THE RUNGE-KUTTA INTEGRATION TECHNIQUE C

DO 33 I-l.NE CAY1(I)-DYDX(I)

33 Yl(I)-Y(I)+DYDX(I)*DT/2. Tl-T+DT/2. CALL FX(Tl.Yl.DYDX) DO 34 I-l.NE CAY2(I)-DYDX(I)

34 Yl(l)-Y(I)+DYDX(I)*DT/2. CALL FX(Tl.Yl.DYDX) DO 35 I-l.NE CAY3(I)-DYDX(I)

35 Y1(I)-Y(I)+DYDX(I)*DT T1-T4DT CALL FX(Tl.Yl.DYDX) DO 36 I-l.NE CAY4(I)-DYDX(I)

36 Y(I)-Y(I)+DT*(CAYl(I)+2.*CAY2(I)+2.*CAY3(I)4CAY4(I))/6.

T-T+DT

IF(T.LT.TMAX)GO TO 1

C PRINT RESULTS

C 272 PRINT 224.1.Y(1).YC1(1) 224 FORMAT( IX.'TRAYM2 . 2X. 3H X-. E12 . 5 . 2X. 3H Y-. E12 5) 1000 CONTINUE

STOP END

C******** END OF MAIN PROGRAM

C C ****** START SUBROUTINE TO LINEARIZE EQUAATIONS

C

C THIS SUBROUTINE USES THE THOMAS METHOD TO LINEARIZE THE

C NONLINEAR EQUATIONS.

C SUBROUTINE TM(N.C.D.E.B.X)

Page 103: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

94

IMPLICIT REAL*8(A-H.0-Z) DIMENSION C(50).D(50).E(50).B(50).X(IOO).BETA(50).GAM(50) BETA(1)-D(1) GAM(1)-B(1)/BETA(1) DO 10 1-2,N BETA(I)-D(I)-C(I)*E(I-1)/BETA(1-1)

10 GAM(I-1)-(B(I)-C(I)*GAM(I-1))/BETA(I) X(N)-GAM(N) DO 20 1-2.N

J-N-I+1 20 X(J)-GAM(J)-E(J)*X(J+1)/BETA(J)

RETURN END END SUBROUTINE TM C****

C

c ***** c c c c c

c c c

c c c

START SUBROUTINE FX

C C C

THIS SUBROUTINE CALCULATES THE ODES USING THE COMPONENT BALANCE AT THE TRAY. IT ALSO CALULATES THE VAPOR COMPOSITION USING CONSTANT RELATIVE VOLATILITY.

SUBROUTINE FX(T,Y,DYDX) IMPLICIT REAL*8(A-H,0-Z) DIMENSION Y(IOO).DYDX(IOO).XL(50).XM(50).X(50).YC(50),YX(50) COMMON /0N9/ALFA(50),NT.R.V,F.XF.NF.DEN.HWS.HWR.XLWS.XLWR,DTS.DTR COMMON /TW9/XLL(50).XB.YD,VR.VA.YC1(50) XLS-R+F XLR-R DO 88 I-1,NF

88 XLL(I)-XLS NFP-NF+1 DO 89 I-NFP.NT

89 XLL(I)-XLR DO 84 I-l.NT

84 XL(I)-XLL(I) CALL SUBROUTINE TO CALCULATE LIQUID HOLDUP

CALL LHDUP(XM.XLS,XLR)

EF IS THE EFFEICIENCY OF THE TRAY

EF-.75

START CALCUI.ATING THE VAPOR COMPOSITION

DO 2 I-l.NT YX(I)-ALFA(I)*Y(I)/(1.+(ALFA(I)-1.)*Y(I))

2 IF(YX(I).GT.1.)YX(I)-1.

YC(1)-YX(1) YC(NT)-YX(NT) NTM-NT-1 DO 9 1-2.NTM

9 YC(I)-YC(I 1)+EF*(YX(I)-YC(I-1))

SETUP THE ODE ODE FOR THE REBOILER

Page 104: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

95

DYDX(1)-(Y(2)*XLS-YC(1)*V.(XLS-V)*Y(1))/XM(1) NTM-NT-1 DO 3 1-2,NTM

C

C ODE FOR ALL TRAYS C

3 DYDX(I)-(XL(I+1)*Y(I+1)-Y(I)*XL(I)+V*(YC(I-1)-YC(I)))/XM(I) C C ODE FOR FEED TRAY C

DYDX(NF)-DYDX(NF)+XF*F/XM(NF) D-V-R

C C ODE FOR CONDENSER C

DYDX(NT)-(V*YC(NT.1)-R*Y(NT)-D*Y(NT))/XM(NT) DO 666 I-1,NT

666 YCl(I) - YC(I) RETURN END

C****** END SUBROUTINE FX C C***** START SUBROUTINE LHDUP C

SUBROUTINE LHDUP(XM.XL) C THIS SUBROUTINE CALCULATES THE MOLAR HOLDUP ON EACH TRAY C USING THE LIQUID FLOWRATE AND THE FRANCIS WEIR FORMULA C

IMPLICIT REAL*8(A-H.0-Z) DIMENSION XL(50).XM(50).H(50) COMMON /0N9/ALFA(50).NT.R.V.F,XF.NF.DEN.HWS.HWR.XLWS.XLWR.DTS.DTR COMMON /TW9/XLL(50).XB.YD.VR.VA.YCl(50) NFP-NF+1 DO 1 I-l.NF H(I)-((R+F)/(3.33*XLWS*DEN))**.6667+HWS

1 XM(I)-H(I)*3.14*DTS*DTS*DEN/4.

DO 2 I-NFP.NT H(I)-(R/(3.33*XLWR*DEN))**.6667+HWR

2 XM(I)-H(I)*3.14*DTR*DTR*DEN/4. C C HOLDUP ON IN THE REBOILER AND CONDENSER ARE CONSTANT

C

XM(l)-440. XM(NT)-440. RETURN END

C***** END SUBROUTINE HDLUP C C***** START SUBROUTINE DATAIN

C SUBROUTINE DATAIN

C FEED IN ALL THE DATA FOR THE CONTROLLER

C IMPLICIT REAL*8(A-H.0-Z) COMMON /TWO/ ERLIM.NITR.Kl.K2.TAU(2).XINT.YlNT.DT.ir.'PE

Page 105: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

96

COMMON /THREE/XSP.YSP.N.M

COMMON /EDATA/TCl.TC2.PCI.PC2.W1.W2

COMMON /FOUR/ BHV.THV.STMHV.FHV.HWMAX.HWMIN

REAL*8 N.M.KT(2).KB(2).L.K1(2).K2(2)

ITYPE-1

ERLIM-l.E-6

NITR-75.

TAU(1)-1.0

TAU(2)-1.2

Kl(l)-2.05

Kl(2)-2.05

K2(l)-1.0E-03

K2(2)-1.0E-03

XINT-0.0

YINT-0.0

TCl-305.4

TC2-425.2

PC1-48.8*14.7

PC2-38.0*14.7

W1-.099

W2-.199

STMHV-928.

THV-4552.

BHV-5808.

FHV-150.

HWMAX-4.E6

HWMIN-.5E6

RETURN

END

C ***** END SUBROUTINE DATAIN

C

C****** START SUBROUTINE CONT

C

C************************ ABSRACT *••*****•**•••**••*************•****• C

C

C

C

C

C

C

C

C

C

THIS SUBROUTINE CALCULATES THE VAPOR AND LIQUID FLOW RATES (V & L)

BASED UPON THE PROCESS MODEL BASED CONTROL LAW. THE CONTROL LAW

DETERMINES MODIFIED COMPOSITION FOR THE LIGHT COMPONENT IN THE BOTTOMS

AND THE OVERHEAD (XSPP AND YSPP. RESPECTIVELY). THEN A NETOWN'S

SEARCH IS USED TO FIND V AND L THAT SATISFY THE SMITH-BRINKLEY MODEL

WITH XSPP AND YSPP- THIS CONTROLLER CAN ALSO BE USE TO CONTROL

THE BOTTOMS COMPOSITION (X) USING ONLY V ( USE ITYPE-2) OR TO

CONTROL THE OVERHEAD CONPOSITION USING ONLY L (USE ITYPE-3).

NOMENClj\TURE ******************************** C***^i*******************

c THE PARTIAL OF THE ITH EQUATION WITH RESPECT TO THE JTH

UNKNOWN (J-1 IS V; J-2 IS L)

THE FUNCTION VALUE OF THE ITH EQUATION

THE RELATIVE ERROR CRITERIA FOR CONVERGENCE OF THE NEWTON'S SEARCH

THE CHANGE IN THE UNKNOWNS CALCUUVTED BY THE NEWTON'S SEARCH

-1 BOTH X .& Y CONTROLLED; -2 X ONLY; -3 Y ONLY

THE K VALUE OF THE ITH COMPONENT FOR THE AREA OF COLl'M^ BELOf

THE FEED TRAY(1-1 LIGHT COMPONENT; 1-2 HEAVY COMPONENT)

A(I.J)

C(I)-ERLIM-

C. (I) -

ITVPE-

KB(I)-

Page 106: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

97

C KT(1)- THE K VALUE OF THE ITH COMPONENT FOR THE ARFJK OF COLUMN ABOVE C THE FEED TRAY (I-l LIGHT COMPONENT; 1-2 HEAVY COMPONENT) C K1(I)- TUNING PARAMETER FOR THE PROPORTIONAL TERM IN THE CONTROL LAW C K2(I)- TUNING PARAMETER FOR THE INTEGRAL TERM IN THE CONTROL LAW C L.Ll- THE REFLUX FLOW RATE (#MOLES/HR) C M.Ml- THE NUMBER OF THEORITICAL STAGES BELOW THE FEED TRAY C N.NI- THE TOTAL NUMBER OF THEORITICAL STAGE IN THE COLUMN C NERS- THE NUMBER OF VARIABLE THAT DO NOT MEET CONVERGENCE CRITERIA C TB- THE BOTTOMS TEMPERATURE (DEG F) C TEST- THE RELATIVE ERROR IN A VARIABLE C TF- THE TEMPERATURE OF THE FEED (DEG F) C TM- THE AVERAGE TEMPERATURE IN THE STRIPPING SECTION (DEG F) C TN- THE AVERAGE TEMPERATURE IN THE RECTIFYING SECTION (DEG F) C TT THE TEMPERATURE AT THE TOP OF THE COLUMN (DEG F) C V.Vl- THE VAPOR BOIL-UP RATE (/!IM0LES/HR) C XINT- THE INTEGRAL TERM VALUE FOR THE BOTTOMS COMPOSITION C XSP- THE SET POINT FOR THE LIGHT COMPONENT IN THE BOTTOMS (MOLE FRAG) C XSPP- THE MODIFIED COMPOSITION FOR THE LIGHT COMP IN THE BOTTOMS C YINT- THE INTEGRAL TERM VALUE FOR THE OVERHEAD COMPOSITION C YSP- THE SETPOINT FOR THE HEAVY COMPONENT IN THE OVERHEAD (MOLE FRAC) C YSPP- THE MODIFIED COMPOSITION FOR THE HEAVY COMP IN THE OVERHEAD C C************************************************************************ c

SUBROUTINE C0NT(N1.Ml.XSP.YSP.VI.LI) IMPLICIT REAL*8(A-H.0-Z) DIMENSION A(2.2).C(2) COMMON /ONE/ D.B.X.Y.TF.TT.TB.P.F.Z.KT.KB COMMON /TWO/ ERLIM.NITR.K1.K2,TAU(2).XINT.YINT.DT.ITYPE REAL*8 N,M.KT(2).KB(2).K1(2).K2(2).L1.L.G(2).N1.M1

L-Ll V-Vl N-Nl M-Ml

C CALCULATE AVERAGE TEMPERATURES IN STRIPPING AND RECTIFYING SECTIONS

TN-.5*(TT+TF) TM-.5*(TF+TB)

C CALCULATE K VALUES FOR BOTH SECTIONS OF THE COLUMN CALL EQL(TN.P,KT) CALL EQL(TM.P.KB)

C APPLY CMC CONTROL LAW I.E.. CALCULATE MODIFIED COMPOSITIONS XSPP-X-TAU(1)*K1(1)*(X-XSP)-TAU(1)*K2(1)*X1NT YSPP-Y-TAU(2)*K1(2)*(Y-YSP)-TAU(2)*K2(2)*Y1NT

IF(XSPP.LT.l.E-6)XSPP-l.E-6 IF(YSPP.CT.l.)YSPP-.9999

C C BEGIN THE ITERATIVE NEWTON'S SEARCH FOR L AND V THAT SATISFY THE C SMITH-BRINKLEY MODEL WITH XSPP AND YSPP

C ICT-O

1000 ICT-ICT+1 C CALCULATE THE JACOBIAN AND THE FUNCTION VALUES

CALL DERC(N.M.V.L.XSPP.YSPP.A.C)

C CALCULATE THE CHANGE IN V AND L C ( 2 ) - ( - A ( 2 . 1 ) * C ( l ) + A ( l . I ) * C ( 2 ) ) / ( A ( 2 . 1 ) * A ( 1 . 2 ) - A ( l . l ) * A ( 2 . 2 ) )

Page 107: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

98

C(l)-(-C(l)-A(1.2)*G(2))/A(l.l) C CHECK FOR BOTTOMS CONTROL ONLY

IF(ITYPE.EQ.2)C(1)—C(l)/A(l.l) lF(ITYPE.EQ.2)G(2)-0.0

C CHECK FOR OVERHEAD CONTROL ONLY

IF(ITYPE.EQ.3)G(2)—C(2)/A(2.2) IF(ITYPE.EQ.3)G(l)-0.0

C CHANGE VAPOR AND REFLUX RATES V-V+G(l) L-L+C(2) NERS-0

C TEST CONVERGENCE FOR V TEST-DABS(G(l)/V) IF(TEST.GT.ERLIM)NERS-NERS+1

C TEST CONVERGENCE FOR L TEST-DABS(G(2)/L) IF(TEST.GT.ERLIM)NERS-NERS+1 IF(ICT.GT.NITR)GO TO 2000 IF(NERS.NE.0)GO TO 1000

C

C CONVERGENCE OBTAINED C

Vl-V Ll-L

C

C CALCUUVTE CONTRIBUTION TO INTEGRAL TERMS XINT-XINT+(X-XSP)*DT YINT-YINT+(Y-YSP)*DT RETURN

C NEWTON'S METHOD DID NOT CONVERGE; PRINT THAT RESULT AND RETURN 2000 PRINT 25

25 FORMAT( 'NEWTON METHOD DID NOT CONVERGE FOR CONT') RETURN END

C

C**************************** ABSTRACT ********************************

C C THIS SUBROUTINE CALCUUVTES THE DERIVATIVE OF THE TWO EQUATIONS THAT C RESULT FORM THE SMITH-BRINKLEY MODEL WITH RESPECT TO V AND L. THE C DERIVATIVES ARE CALCULATED BY FINITE DIFFERENCE APPROXIMATIONS. THE C ANSWERS ARE STORED IN A(I.J). A(I.J) IS THE JACOBIAN OF THE TWO C NONLINEAR EQUATIONS. C C*************************** NOMENCALTURE ***************************** C C A(I.J)- THE JACOBIAN OF THE ITH EQUATION WITH RESPECT TO THE JTH C VARIABLE ( J-1 V; J-2 L) C B(I)- THE VALUE OF THE ITH EQUATION C DELTA- THE FRACTIONAL CHANGE IN V AND L USED TO CALCULATE THE C NUMERICAL DERIVATIVES C F(I)- THE EQUATION VALUE OF THE ITH EQUATION C L.L1.L2- THE REFLUX LIQUID FLOW RATE (#MOLES/HR) C M.Ml- THE NUMBER OF THEORITICAL STAGES IN THE RECTIFYING SECTION C N.NI- THE NUMBER OF THEORITICAL STAGES FOR THE COLUMN C V .V1.V2- THE VAPOR BOIL-UP RATE FOR THE REBOILER (ilfMOLES/HR)

Page 108: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

99

C X.Xl C Y.Yl C

THE COMPOSITION OF THE LIGHT COMP IN THE BOTTOMS THE COMPOSITION OF THE HEAVY COMP IN THE OVERHEAD

^*****1t**1t******ir***-k**********

SUBROUTINE DERC(N1.Ml.VI.LI.XI.Yl.A.B) IMPLICIT REAL*8(A-H.0-Z) DIMENSION A(2.2).B(2).F(2) REAL*8 N.N1,M.M1.L.L1.L2 N-Nl M-Ml V-Vl l^Ll X-Xl Y-Yl DELTA-.03

DETERMINE BASE CASE VALUE OF F(I) CALL FUN(N,M.V,L.X.Y,F) B(l)-F(l) B(2)-F(2) L2-L*(1.+DELTA)

INCREMENT L CALL FUN(N.M.V.L2.X.Y.F)

CALCULATE NUMERICAL DERIVATIVE WITH RESPECT TO L A(1.2)-(F(1)-B(1))/L/DELTA A(2,2)-(F(2)-B(2))/L/DELTA

INCREMENT V V2-V*(1.+DELTA) CALL FUN(N,M.V2.L.X.Y.F)

CALCULATE NUMERICAL DERIVATIVE WITH RESPECT TO V A(1.1)-(F(1)-B(1))/V/DELTA A(2.1)-(F(2)-B(2))/V/DELTA RETURN END

C************************** ABSTRACT *********************************

C THIS SUBROUTINE CALCULATES THE K VALUES FOR EACH COMPONENT FROM

THE TEMPERATURE AND PRESSURE

NOMENCALTURE C*************************

c K(I)- THE K VALUE OF THE ITH COMPONENT ( 1-1 LIGHT; P- PRESSURE (PSIA)

******************************

C c c c c c c c c c c c c

1-2 HEAVY )

PCI- THE CRITICAL PRESSURE OF THE LIGHT COMP (PSIA) PC2- THE CRITICAL PRESSURE OF THE HEAVY COMP (PSIA) PH- THE FUGACITY COEFICIENT FOR THE VAPOR PHASE PHI- THE FUGACTIY COEFICIENT FOR THE HEAVY COMP PHX- THE FUGACITY COEFICIENT FOR THE LIGHT COMP PL- A-B/(T+C) IN THE ANTOINE EQUATION PR- THE REDUCED PRESSURE T- TFMPERATURE (DEG F) TCI- THE CRITICAL TEMPERATURE OF THE LIGHT COMP (DEG K) TC2- THE CRITICAL TEMPERATURE OF THE HEAVY COMP (DEG K) TK- TEMPERATURE (DEG K)

Page 109: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

100

C TR- THE REDUCED TEMPERATURE C VP- THE VAPOR PRESSURE (PSIA) C Wl- THE ACENTRIC FACTOR FOR THE LIGHT COMP C W2- THE ACENTRIC FACTOR FOR THE HEAVY COMP C C******************************************^k.********^****^t^*^^^^^^*^^^^***

C SUBROUTINE EQL(T.P.K) IMPLICIT REAL*8(A-H.0-Z) COMMON /EDATA/TCl.TC2.PCI.PC2.Wl.W2 REAL*8 K(2)

C CALCULATE TEMPERATURE IN DEGREES KELVIN TK-(T+460.)*5./9.

C CALCULATE REDUCED TEMPERATURE AND PRESSURE FOR LIGHT COMPONENT TR-TK/TCl PR-P/PCl

C CALCULATE VAPOR PRESSURE FOR LIGHT COMPONENT PL-IO.072-1976.1/(TK+12.894) VP-14.69*DEXP(PL)

C CALCULATE FUGACITY COEFICIENT FOR VAPOR PHASE PHX-PH(TR.PR.Wl)

C CALCULATE K VALUE FOR LIGHT COMPONENT

K(1)-VP/(PHX*P) C CALCULATE REDUCED PRESSURE AND TEMPERATURE FOR HEAVY COMPONENT

TR-TK/TC2 PR-P/PC2

C CALCULATE VAPOR PRESSURE FOR HEAVY COMPONENT PL-9.4928-2067.3/(TK-13.437) VP-14.69*DEXP(PL)

C CALCULATE FUGACITY COEFICIENT FOR VAPOR PHASE PHI-PH(TR.PR.W2)

C CALCULATE K VALUE FOR HEAVY COMPONENT K(2)-VP/(PHI*P) RETURN END

C C**************************** ABSTRACT *******************************

C C THIS FUNCTION SUBROUTINE CALCULATES THE FUGACITY COEFICIENT FOR C A COMPONENT FROM THE REDUCED TEMPERATURE. REDUCED PRESSURE, AND THE

C ACENTRIC FACTOR C C************************* NOMENCLATURE **•*••***•******•*********•***

C C PH- FUGACITY COEFICIENT C PR- THE REDUCED PRESSURE C TR- THE REDUCED TEMPERATURE C W- THE ACENTRIC FACTOR

C C***********************************************************************

C FUNCTION PH(TR.PR.W) IMPLICIT REAL*8(A-H.0-Z)

P-( 1445+.073*W)/TR-(.33-.46*W)*TR**(-2)-( 1385+.5*W)*TR**( 3)

l-(.0121*.097*W)*TR**(-4)-.0073*W*TR**(-9)

Page 110: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

101

PH-10.**(PR*P/2.303) RETURN END

C C*************************** ABSTRACT *********•***•***•**•*•***••***• C

C THIS SUBROUTINE CALCULATES THE ERROR IN EACH OF THE TWO NONLINEAR C EQUATIONS RESULTING FROM THE APPLICATION OF THE SMITH-BRINKLEY MODEL C C************************* NOMENCLATURE **•******•*****•••••***••**•** C C B- BOTTOMS PRODUCT FLOW RATE (JJIMOLES/HR) C D- OVERHEAD PRODUCT FLOW RATE (#MOLES/HR) C F- FEED FLOW RATE (#MOLES/HR) C FX(I)- THE ERROR IN THE ITH EQUATION C FD(I)- THE RECOVERY OF THE ITH COMP IN THE BOTTOMS PRODUCT C (I-l LIGHT; 1-2 HEAVY) C HD(I)-C KB(I)- THE K VALUE IN THE STRIPPING SECTION (I-l LIGHT; 1-2 HEAVY) C KT(I)- THE K VALUE IN THE RECTIFYING SECTION (I-l LIGHT; 1-2 HEAV ') C L- THE REFLUX LIQUID FLOW RATE (IMOLES/HR) C R- THE REFLUX RATIO (I.E.. R-L/D) C SM(I)- THE SEPARATION FACTOR FOR THE ITH COMP IN THE STRIPPING SECTIO C SN(I)- THE SEPARATION FACTOR FOR THE ITH COMP IN THE RECTIFTING SECT C V- THE VAPOR BOIL-UP RATE FROM THE REBOILER (idMOLES/HR) C X- THE MOLE FRACTION OF THE LIGHT IN THE BOTTOMS PRODUCT C Y- THE MOLE FRACTION OF THE LIGHT IN THE OVERHEAD PRODUCT C Z- THE MOLE FRACTION OF THE LIGHT IN THE FEED C C***********************************************************************

c SUBROUTINE FUN(N.M.V.L.X.Y.FX) IMPLICIT REAL*8(A-H.0-Z) COMMON /ONE/ D.B.Q.E.TF.TT.TB.P.F.Z.KT.KB REAL*8 N.M.L.KT(2).KB(2).SN(2).SM(2).FX(2).FD(2).HD(2) D-F*(Z-X)/(Y-X) B-F-D R-L/D VB-V/B

C CALCULATE THE SEPARATION FACTORS DO 1 1-1.2 SN(I)-KT(I)*((R+1.)/R)

1 SM(I)-KB(I)*VB/(VB+1.) DO 99 1-1.2

99 IF((SN(I).LT.O.).OR.(SM(I).LT..O))PR1NT 55.SM(I).SN( I) .V.L. F

55 FORMAT( 3H S-.5E12.5) C CALCULATE THE H FACTORS

DO 2 1-1.2

2 HD(I)-SM(I)*(1-SN(I))/(SN(I)*(I-SM(I)))

C CALCULATE THE RECOVERIES IN THE BOTTOMS

FD(1)-B*X/F/Z FD(2)-B*(1.-X)/(F*(1 -Z))

C CALCUUTE THE ERROR IN THE SMITH-BRINKLEY MODEL EQUATIONS DO 3 1-1.2 X1-(1.-SN(I)**(N-M))*R*(1.-SN(I))

Page 111: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

102

XX-(1.-SN(I)**(N-M))+R*(1.-SN(I)) X9-HD(I)*SN(I)**(N-M)*(1.-SM(I)**(M+1)) X2- X9/X1 FX(I)-1./((1.+X2)*FD(I))-1.0

C PRINT 88.X1.X2.FX(I).X9 3 CONTINUE RETURN END

C C************************ ABSRACT *************************************

C C THIS SUBROUTINE CALCULATES THE NUMBER OF THEORITICAL STAGES FOR C THE COLUMN AND FOR THE STRIPPING SECTION. FILTERED STEADY-STATE DATA C FOR THE REFLUX RATE. THE VAPOR BOIL-UP RATE. FEED RATE. AND THE C COMPOSITON OF THE LIGHT COMPONENT IN THE BOTTOMS AND OVERHEAD ARE C PROVIDED TO THIS SUBROUTINE. THE VALUES OF N AND M ARE FOUND USING A C A NEWTON'S SEARCH TO SATISFY THE SMITH-BRINKLEY MODEL. C C************************ NOMENCLATURE ********************************

C C A(I,J)- THE PARTIAL OF THE ITH EQUATION WITH RESPECT TO THE JTH C UNKNOWN'. (J-1 IS N; J-2 IS M) C C ( I ) - THE FUNCTION VALUE OF THE ITH EQUATION C ERLIM- THE RELATIVE ERROR CRITERIA FOR CONVERGENCE OF THE NEWTON'S C SEARCH C G(I)- THE CHANGE IN THE UNKNOWNS CALCULATED BY THE NEWTON'S SEARCH

C ICT- AN ITERATION COUNTER C KB(I)- THE K VALUE OF THE ITH COMPONENT FOR THE AREA OF COLUMN BELOW C THE FEED TRAY(I-1 LIGHT COMPONENT; 1-2 HEAV ' COMPONENT) C KT(I)- THE K VALUE OF THE ITH COMPONENT FOR THE AREA OF COLUMN ABOVE C THE FEED TRAY (I-l LIGHT COMPONENT; 1-2 HEAVY COMPONENT) C L.Ll- THE REFLUX FLOW RATE (l!fMOLES/HR) C M.Ml- THE NUMBER OF THEORITICAL STAGES BELOW THE FEED TRAY C N Nl- THE TOTAL NUMBER OF THEORITICAL STAGE IN THE COLUMN C NERS- THE NUMBER OF VARIABLE THAT DO NOT MEET THE CONVERGENCE CRITERI C TB- THE BOTTOMS TEMPERATURE (DEG F) C TEST- THE RELATIVE ERROR IN A VARIABLE C TF- THE TEMPERATURE OF THE FEED (DEG F) C TM- THE AVERAGE TEMPERATURE IN THE STRIPPING SECTION (DEG F) C TN- THE AVERAGE TEMPERATURE IN THE RECTIFYING SECTION (DEG F) C TT- THE TEMPERATURE AT THE TOP OF THE COLUMN (DEG F) C X- MOLE FRACTION OF THE LIGHT COMP IN THE BOTTOMS PRODUCT C Y- MOLE FRACTION OF THE LIGHT COMP IN THE OVERHEAD PRODUCT

^ J . J . . I . . I * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

C******************************** C

SIIHROUTINF rARM(Nl .Ml . V I . LI)

IMPLICIT REAL*8(A-H.0-Z) DIMENSION A ( 2 . 2 ) . C ( 2 ) COMMON /ONE/ D . B . X . Y . T F . T T . T B . P . F. Z. KT. KB COMMON /TWO/ ERLIM.NITR.K1.K2.TAU(2).XINT.YINT D T m P E REAL*8 N . M . K T ( 2 ) . K B ( 2 ) . K 1 ( 2 ) . K 2 ( 2 ) . L 1 . L . G ( 2 ) . N 1 . M 1

L-Ll V-Vl N-Nl

Page 112: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

103

M-Ml

TN-.5•(TT-^TF) TM-.5*(TF+TB)

CALL EQL(TM.P.KB)

PRINT A4.KT(1).KT(2).KB(1),KB(2) 44 FORMATC 4H KT-.4E12.5)

Xl-X Yl-Y

C

C ITERATIVELY SOLVE FOR N AND M C

ICT-O 1000 ICT-ICT+1

C CALCULATE THE JACOBIAN OF THE TWO NONLINEAR EQUATIONS CALL DERP(N.M.V.L.X1,Y1.A.C)

C CALCULATE THE CHANCE IN N AND M C G(2 ) - ( .A(2 ,1 )*C(1 )+A(1 .1 )*C(2 ) ) / (A(2 .1 )*A(1 .2 ) -A(1 .1 )*A(2 2) ) C G ( 1 ) . ( . C ( 2 ) - A ( 2 . 2 ) * G ( 2 ) ) / A ( 1 . 2 ) ^^^

G ( l ) - ( - A ( 2 . 2 ) * C ( l ) + A ( 1 . 2 ) * C ( 2 ) ) / ( A ( 2 . 2 ) * A ( l . l ) - A ( 1 . 2 ) * A ( 2 1)) G ( 2 ) - ( - C ( 2 ) - A ( 2 . 1 ) * G ( l ) ) / A ( 2 . 2 )

IF(ABS(G(1)).GT..3*N)G(1)-.3*N*ABS(C(1))/G(1) IF(ABS(G(2)).CT..1*M)G(1)-.1*M*ABS(G(2))/G(2) PRINT 22.V.L.N.M.G(1).G(2) N-N+G(l) M-M+G(2) NERS-O

PRINT 2 2 , A ( 1 . 1 ) . A ( 1 . 2 ) . A ( 2 . 1 ) . A ( 2 . 2 ) . C ( 1 ) . C ( 2 ) PRINT 22.V.L.N.M.G(1).G(2) PRINT 23

22 FORMAT( 5H C0N-,6E11.4) 23 FORMAT( / )

C CHECK FOR CONVERGENCE TEST-DABS(G(l)/N) IF(TEST.GT.ERLIM)NERS-NERS+1 TEST-DABS(G(2)/M) IF(TEST.GT.ERLIM)NERS-NERS+1 IF(ICT.CT.NITR)GO TO 2000 IF(NERS.NE.O)GO TO 1000 Nl-N Ml-M RETURN

C IF NEWTON'S METHOD DID NOT CONVERGE. INDICATE THRU A PRINT AND RETURN 2000 PRINT 25

25 FORMAT( 'NEWTON METHOD DID NOT CONVERGE IN PARM') RETURN END

C C>i» ************************** ABSTRACT ******************************** C C THIS SUBROUTINE CALCUU TES THE DERIVATIVE OF THE TWO EQUATIONS THAT C RESULT FORM THE SMITH-BRINKLEY MODEL WITH RESPECT TO N AND M THE

Page 113: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

104

C DERIVATIVES ARE CALCULATED BY FINITE DIFFERENCE APPROXIMATIONS THE C ANSWERS ARE STORED IN A(I.J). A(I.J) IS THE JACOBIAN 0 ^ ™ ° TWO C NONLINEAR EQUATIONS. C C*************************** NOMENCALTURE ************************^^* C

C A(I.J)- THE JACOBIAN OF THE ITH EQUATION WITH RESPECT TO THE JTH C VARIABLE ( J-1 V; J-2 L) C B(I)- THE VALUE OF THE ITH EQUATION C DELTA- THE FRACTIONAL CHANGE IN V AND L USE TO CALCULATE THE C NUMERICAL DERIVATIVES C F(I)- THE EQUATION VALUE OF THE ITH EQUATION C L.Ll- THE REFLUX LIQUID FLOW RATE (#MOLES/HR) C M.M1,M2- THE NUMBER OF THEORITICAL STAGES IN THE RECTIFYING SECTION C N.N1.N2- THE NUMBER OF THEORITICAL STAGES FOR THE COLUMN C V.Vl- THE VAPOR BOIL-UP RATE FOR THE REBOILER (#MOLES/HR) C X.Xl- THE COMPOSITION OF THE LIGHT COMP IN THE BOTTOMS C Y.Yl- THE COMPOSITION OF THE HEAVY COMP IN THE OVERHEAD C c*--C

SUBROUTINE DERP(N1.Ml.VI.LI.XI.Yl.A.B) IMPLICIT REAL*8(A-H.0-Z) DIMENSION A(2,2),B(2).F(2) REAL*8 N.N1.M,M1,L,L1,L2.M2.N2 N-Nl M-Ml V-Vl L-Ll X-Xl Y-Yl DELTA-.01

C DETERMINE F(I) FOR THE BASE CASE CALL FUN(N.M,V.L.X,Y.F) B(l)-F(l) B(2)-F(2)

C INCREMENT M M2-M*(1.+DELTA) CALL FUN(N.M2,V.L.X,Y.F)

C DETERMINE PARTIAL DERIVITATIVES NUMERICALLY A(1,2)-(F(1)-B(1))/M/DELTA A(2.2)-(F(2)-B(2))/M/DELTA

C INCREMENT N N2-N*(1.+DELTA) CALL FUN(N2.M.V.L.X.Y.F)

C CALCULATE PARTIAL DERIVITATIVES NUMERICALLY A(1.1)-(F(1)-B(1))/N/DELTA A(2.1)-(F(2)-B(2))/N/DELTA RETURN END

//GO.SYSIN DD * 0.47864E-03 0 15271E-02 0,38336E-02 0.94629E-02

Page 114: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

105

0.23015E-01 0.54153E.01 0.11832E+00 0.22S22E+OO 0.35515E+00 0.46831E+00 0.70799E+O0 0.84922E+00 0.92741E+O0 0.96633E+00 0.98474E+00 0.99325E+00 0.99712E+00 0.99888E+00

/* //

Page 115: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

APPENDIX B

DETAILED DERIVATION OF THE APPROXIMATE MODEL

FOR A DISTILLATION COLUMN WITH A

SIDESTREAM DRAWOFF

106

Page 116: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

.

107

Based on Figure B.l and \ising the general form of the equation for

the composition in any section derived in Chapter 6, section 6.1, we

shall derive the equations for the recoveries in the bottoms and

sidestream.

For section I:

Consider the condenser

dA - Y^D - XiKiD

Xi - dA/KiD - CiS4 + C2 ( -D

doing a material balance on the top tray we have

LlYi| I VYi

LlXt • T VYi-l

LiYi + VYi.i - VYi - LlXi - 0

using Yi - K^Xi

we have

Yi.i - dA/D + LidA/VD(l/Ki -1)

which implies that

Xi.i - dA/KiD{l+Li(l/Ki-l)/V) - CiSi-h -»- C2 (B.2)

now solving equations (B.l) and (B.2) for Ci and C2 we get the equation

for Xi as follows

Page 117: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

108

XI - (l-f-g)A/KiD(l/Si-l)[Li(l/Ki-l)/V][sI-ii-l]+(l-f.g)A/KiD. (B.3)

Now for the bottom section the following procedure is used.

Considering the reboiler

XiB - fA

Xi - fA/B - C3S3 + C4 (B.4)

now consider the tray above the reboiler,

UX2^ f VYI

U BXl doing a material balance we have

L3X2 - VYi - BXl - 0

and using Yi - K^Xi

Page 118: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

109

we have

X2 - fA/BL3(VK3 + B) - C3S23 + C4 (B.5)

solving equations (B.4) and (B.S) we have

XM - fA/B(l-S3)[l-(VK3+B)/L3][sM-l3-l) + fA/B. (B.6)

For the middle section we shall perform the material balance on the

tray immidiately above the feed tray and the tray right below the

sidestream drawoff tray.

Now considering the tray above the feed tray (remember this tray 1

for this section)

L2X: I f VYI

CZZIl L2X4 f VYf

The material balance is

L2X2 + VYF - L2X1 - VYi - 0 (B.7)

Page 119: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

110

where

X2 - C5S22 + C5; Xi - C5S2 + Ce; Yl - K2X1 Yp - KpXp - AK2/F

substituting these in equation (B.7) we have the following equation

containing C5 and C5

C5 + Ce - A/F. (B.S)

Now considering the tray below the feed tray (this tray will be tray n

for this section)

VYn-l • ^ L2Xn

VYn.2 T • LlXn-l

the material balance yields:

L2Xn + VYn.2 " L2Xn-l ' VY^.i - 0 (B.9)

1-2.

where

Xn - gA/G Xn-l - C5Sn-l2 + Cg and Xn.2 - C5Sn-^2 + ^6

and Yn-i - Kp.iXn-i; "^n-2 ' Xn.2Kn.2

substituting these in equation (B.9) we get the following equation.

C5S' 2 + C6 - gA/G. <»' 0>

Page 120: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

Ill

Solving equations (B.8) and (B.IO) for C5 and C6 we get and

substituting in the general form for the liquid composition in the

middle section we have:

XN - {l/(l-S^2))[VF-gA/G][sN2 -1] + A/F. (B.ll)

Now that we have all the liquid compositions required, we can perform

material balances on the feed tray and the sidestream drawoff tray.

now consider the feed tray;

L2X1^ • VYf

A-

(XIF) , . 1 f VYM

L3Xf^ I

the material balance is:

L2X1 + VYm-1 - VYm - L3Xm + A - 0 (B.12)

where XF - Xm - A/F; XF-1 - Xm-1 - C3Sm-13 + C4 and XI - C5S2 + C6

and Y - KX

Page 121: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

112

substituting these in equation (B.12) yields the following equation in

terms of f and g:

(VK30/B + VK3/B)f + (-L2b/G)g - (VK3 +L3-L2-L2b)/F -1 (B.13)

where

b - (S2-l)/(l.Sn2)

and

0 - (Sm-23-l)/(l-S3)[l-(VK3+B)/L3].

Now consider the material balance on the sidestream drawoff tray:

LlXl ^ f VYn

GXn

L2Xn ^ f VYn-l

the material balance is:

LlXl + VYn-l - L2Xn - VYn - GXn - 0 (B.14)

where Xn - gA/G; XI - ClSl + C2 and Xn-l - C5Sn-12 + C6

now substituting in equation (B.14) we get the following in terms of f

and g:

Page 122: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

113

(-a01-a)f-h(-a01-a-VK2bl/G-L2/G-VK2/G-l)g-a01-a-(VK2bl-VK2)/F (B.15)

where

01 - Ll(Sl-il -1)A(1/S1-1){1/K1-1))

bl - (Sn-12 -1)/(1-Sn2)

and

a - Ll/KID.

Now equations (B.15) and (B.13) can be simultaneously solved to give

the values for f and g as follows:

[aOi+a+VK2di/G+L2/G+VK2/G+l][-L2dKf/K2-L2Kf/K2+VKf+L3+F]-

(-L2/G] [aOi+a+(di-i-l)VK2/F]

f-

[VK3( -1)/B][aOi+a+VK2di/G+L2/G+VKg/G+l]-[aOi+a]

[-L2d/G]

and

[aOi+a+(di+l)VK2/Fl-(aOi+a]f

g- _

(aOi+a+(di+l)VK2/G+L2/G+l)

and from a material balance

dd- 1 - f - g.

Page 123: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

^

T ^ f - . . . I

F

*'

LI I 1 I I

L ( i ) i !

T

II

III

B

- - D

"L> G

^

FIGURE B.l Splic^of the disciUation column „ich a sidescrea.

Page 124: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

APPENDIX C

LISTING OF THE COMPUTER CODE FOR THE APPROXIMATE MODEL

115

Page 125: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

116

C*** COMPUTER CODE FOR THE APPROXIMATE •*•• C*** MODEL OF A DISTILLATION COLUMN WITH **** C*** A SIDESTREAM DRAWOFF **•* C*** **** C*** PROGRAMMER RUPAK SINHA **•* C***********************************************************

C******* MAIN PROGRAM ******* C C THIS PROGRAM IS THE APPROXIMATE MODEL FOR A DISTILLATION COLUMN C UlTH A SIDESTREAM DRAWOFF TRAY IN THE STRIPPING SECTION OF THE COLUMN C IT ALSO CALLS THE PROGRAM TO PARAMETERIZE THE COLUMN. C C NOMENCLATURE C F - FEED RATE (MOLES/SEC) C B - BOTTOMS RATE (MOLES/SEC) C G - SIDESTREAM DRAWOFF RATE (MOLES/SEC) C V - BOILUP RATE (MOLES/SEC) C D - DISTILLATE RATE (MOLES/SEC) C R - REFLUX RATIO C L(l) - REFLUX RATE (MOLES/SEC) C L(2) - LIQUID FLOWRATE IN MID SECTION OF COLUMN (MOLES/SEC) C L(3) - LIQUID FLOWRATE IN BOTTOM SECTION OF COLUMN (MOLES/SEC) C TT - ARE TEMPERATURES IN THE COLUMN IN THE DIFFERENT SECTIONS C PP - ARE PRESSURES IN THE COLUMN C FMB - REQUIRED RECOVERY OF THE COMPONENT IN THE BOTTOMS C GMB - REQUIRED RECOVERY OF THE COMPONRNT IN THE SIDESTREAM C DMB - REQUIRED RECOVERY IN THE DISTILLATE C II - NUMBER OF TRAYS IN THE TOP SECTION OF THE COLUMN C Nl - NUMBER OF TRAYS IN THE MIDDLE OF THE COLUMN C Ml - NUMBER OF TRAYS IN THE LOWER SECTION OF THE COLUMN C X - LIQUID COMPOSITION (MOLES) C Y - VAPOR COMPOSITION (MOLES) C C THIS PROCESS USES C2 AND C3 AS THE TWO COMPONENTS

IMPLICIT REAL*8(A-H.0-Z) COMMON /VAR/ F.B.D.G.R.NT.NJ COMMON /VAR1/AA(3).BB1(3).CC(3).DD(3).X(3.3).P(3).T(3).TC(3).PC(3) COMMON /VAR2/FMB.GMB.DMB DIMENSION XX(3).Y(3).Z(3).FX(3).L(3).TT(5).PP(5) REAL *8 K.L.Il.Nl.Ml.IL.IM.NL.NM.ML.MX DO 1 NN - 1.3

C C READ IN ALL INITIAL DATA C

READ(5.14)AA(NN).BBl(NN).CC(NN).DD(NN).TC(NN).PC(NN) 14 F0RMAT(6D12.5) 1 CONTINUE F - 5600./3600. B - 2600.0/3600. V - 2522.0/3600. C - 1000.0/3600 L(l) - 1169 2/3600. L(2) - L(l)-G L(3) - L(2)+F

Page 126: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

117

c c c c

c c c c c c

CALCULATE ALL AVARAGE TEMPERATURE AND PRESSURES FOR EACH OF THE THREE SECTKWS

TT(1) - 1 8 . 3 TT(2) - 5 3 . 1 TT(3) - 53.60 TT(4) - 108.6 PP(1) - 254 .10 PP(2) - 254 .20 PP(3) - 254 .3 PP(4) - 254.60

P ( l ) - ( P P ( l ) + P P ( 2 ) ) / 2 . P(2) - (PP(2 )+PP(3 ) ) / 2 . P(3) - ( P P ( 3 ) + P P ( 4 ) ) / 2 . T ( l ) - ( T T ( l ) * T T ( 2 ) ) / 2 . T(2) - (TT(2) -HT(3) ) /2 . T(3) - (TT(3) -HT(4) ) /2 . D - F-G-B R - L ( l ) / D FMB - 0 .8416 GMB - 0 .0827 DMB - 1-FMB-GHB IL - 4 . 9 9 1 8 NL - 4 .986795 ML - 9.992715 II - IL Nl - NL Ml - ML XX(1) - 0 . Y d ) - 0.

CALL SUBROUTINE TO PARAMETERIZE THE PROGRAM INITIALLY

CALL PARM(I1.NI,M1,V,L) CALL SUBROUTINE TO EVALUATE THE RECOVERIES FOR THE SYSTEH

100 CALL E V A L d l . N l . M l . V . L . X X . Y . F F ) CONTINUE

C C C C C C

PRINT RESULTS

DO 3 J - l . N J WRITE(6.20)F1.GI

20 FORMAT(6X,2D12.5) STOP END

C * * * * * * * * * * * * * * * * * * * * * * * * * * * *

C THIS FUNCTION SUBROUTINE CALCULATES THE FUGACITY COEFICIENT FOR

A COMPONENT FROM THE REDUCED TEMPERATURE. REDUCED PRESSURE. AND THE ACENTRIC FACTOR

ABSTRACT *******************************

C C C C C * * * * * * * * * * * * * * * * * * * * * * * * *

c NOMENCLATURE

Page 127: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

118

C I'll- FUGACITY COEFICIENT C PR- THE REDUCED PRESSURE C TR- THE REDUCED TEMPERATURE C W- THE ACENTRIC FACTOR C C-J

c •••***•**••*•••*••••*•*•

FUNCTION PH(TR.PR.W) IMPLICIT REAL*8(A-H.0-Z)

P-(.1445+.073*W)/TR-(.33-.46*W)*TR**(-2)-(.1385+.5*W)*TR**(-3) l-(.0121+.097*W)*TR**(-4)-.0073*W*TR**(-9) PH-10.**(PR*P/2.303) RETURN END

C C************************ ABSRACT ************************************* C

C THIS SUBROUTINE CALCULATES THE NUMBER OF THEORITICAL STAGES FOR C THE COLUMN AND FOR THE STRIPPING SECTION. FILTERED STEADY-STATE DATA C FOR THE REFLUX RATE. THE VAPOR BOIL-UP RATE. FEED RATE. AND THE C COMPOSITON OF THE LIGHT COMPONENT IN THE BOTTOMS AND OVERHEAD ARE C PROVIDED TO THIS SUBROUTINE. THE VALUES OF N AND M ARE FOUND USING A C A NEWTON'S SEARCH TO SATISFY THE SMITH-BRINKLEY MODEL. C C************************ NOMENCLATURE **•*•********•***********••*•**• C

C A(I,J)- THE PARTIAL OF THE ITH EQUATION WITH RESPECT TO THE JTH C UNKNOWN (J-1 IS N; J-2 IS M) C C(I)- THE FUNCTION VALUE OF THE ITH EQUATION C ERLIM- THE RELATIVE ERROR CRITERIA FOR CONVERGENCE OF THE NEWTON'S C SEARCH C G(l)- THE CHANGE IN THE UNKNOWNS CALCULATED BY THE NEWTON'S SEARCH C ICT- AN ITERATION COUNTER C KB(I)- THE K VALUE OF THE ITH COMPONENT FOR THE AREA OF COLUMN BELOW C THE FEED TRAY(I-1 LIGHT COMPONENT: 1-2 HEAVY COMPONENT) C KT(I)- THE K VALUE OF THE ITH COMPONENT FOR THE AREA OF COLUMN ABOVE C THE FEED TRAY (I-l LIGHT COMPONENT; 1-2 HEAVY COMPONENT) C L.Ll- THE REFLUX FLOW RATE (iJIMOLES/HR) C M.Ml- THE NUMBER OF THEORITICAL STAGES BELOW THE FEED TRAY C N.NI- THE TOTAL NUMBER OF THEORITICAL STAGE IN THE COLUMN C NERS- THE NUMBER OF VARIABLE THAT DO NOT MEET THE CONVERGENCE CRITERI C Til- THE BOTTOMS TEMPERATURE (DEC F) C TEST- THE RELATIVE ERROR IN A VARIABLE C TF- THE TEMPERATURE OF THE FEED (DEG F)

C TM- THE AVERAGE TEMPERATURE IN THE STRIPPING SECTION (DEG F) C TN- THE AVERAGE TEMPERATURE IN THE RECTIFYING SECTION (DEG F) C TT- THE TEMPERATURE AT THE TOP OF THE COLUMN (DEG F) C X- MOLE FRACTION OF THE LIGHT COMP IN THE BOTTOMS PRODUCT C Y- MOLE FRACTION OF THE LIGHT COMP IN THE OVERHEAD PRODUCT

C C************************************************************************

C Sl'BROUTINE PARMdl .Nl .Ml .V .L) IMPLICIT REAL*8(A-H.0-Z) DIMENSION A ( 3 . 3 ) . C ( 3 )

Page 128: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

119

COMMON /ONE/ D.B.X.Y.TF.TT.TB.P.F.Z.KT.KB COMMON /TWO/ ERLIM.NITR.K1.K2.TAU(2).XINT.YINT.DT.ITYPE REAL*8 I.N,M.KT(2),KB(2).K1(2).K2(2).L(3).GG(3).N1.M1.I1 I-Il N-Nl M-Ml WRITE(6.666)1.N.M

666 FORMAT(6X,'TRAY IN PARM'.3D12.5) C Xl-X C Yl-Y C C ITERATIVELY SOLVE FOR N AND M C

ERLIM - 1.0D-03 NITR - 100 ICT-O

1000 ICT-ICT+1 C CALCULATE THE JACOBIAN OF THE TWO NONLINEAR EQUATIONS

CALL DERPd.N.M.V.L.Xl.Yl.A.C) C CALCULATE THE CHANGE IN N AND M

ALPHA-A(3.2)-(A(3.1)*A(1.2)/Ad.l)) RHO-A(3.3)-(A(3.1)*Ad.3)/A(l.l)) GAMMA-C(2)-(A(2.1)*Cd)/A(l.l)) PHI - C(3).(A(3.1)*C(1)/A(1.1)) OMEGA-A(2,3)-(Ad.3)*A(2.1)/A(l,l)) BETA - A(2.2)-(A(1.2)*A(2.1)/A(1.1)) GG(3) - (PHI-(ALPHA*GAMMA/BETA))/(RHO-(ALPHA*OMEGA/BETA)) GG(2) - (GAMMA/BETA)-(0MEGA/BETA)*GG(3) GG(1) - (C(1)/A(1.1))-(A(1.2)/A(1.1))*GG(2)-(A(1.3)/A(1.1))*GG(3) IF(ABS(GG(l)).GT..l*I)GG(l)-.l*I*ABS(GG(l))/GGd) IF(ABS(GG(2)).GT..1*N)GG(2)-.1*N*ABS(GG(2))/GG(2) IF(ABS(GG(3)).CT..1*M)GG(3)-.1*M*ABS(GG(3))/GG(3) PRINT 22.I,N.M I-I+GG(1) N-N+GG(2) M-M+GG(3) NERS-0 PRINT 24.A(1.1).A(1.2).A(1.3).C(1).GG(1) PRINT 24.A(2.1).A(2.2).A(2.3).C(2).GG(2) PRINT 24.A(3.1).A(3.2).A(3.3).C(3).GG(3)

PRINT 22.I.N.M PRINT 23

24 FORMAT( 5H ACG-.5E12.5) 22 FORMAT( 5H INM-.3E11.4)

23 FORMAT( /) C CHECK FOR CONVERGENCE

TEST-DABS(GG(1)/I) IF(TEST.GT.ERLIM)NERS-NERS+1 TEST-DABS(GG(2)/N) IF(TEST.GT.ERLIM)NERS-NERS*1 TEST-DABS(GG(3)/M) IF(TEST.GT.ERLIM)NERS-NERS+1 IF(1CT.GT.NITR)G0 TO 2000 IF(NERS.NE.0)GO TO 1000 Il-I

Page 129: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

120

Nl-N MI-M RETURN

C IF NEWTON'S METHOD DID NOT CONVERGE. INDICATE THRU A PRINT AND RETURN 2000 PRINT 25

25 FORMAT( 'NEWTON METHOD DID NOT CONVERGE IN PARM') RETURN END

C C********************;******** ABSTRACT ********************************

C THIS SUBROUTINE CALCULATES THE DERIVATIVE OF THE TWO EQUATIONS THAT C RESULT FORM THE SMITH-BRINKLEY MODEL WITH RESPECT TO N AND M. THE C DERIVATIVES ARE CALCULATED BY FINITE DIFFERENCE APPROXIMATIONS. THE C ANSWERS ARE STORED IN A(I.J). A(I.J) IS THE JACOBIAN OF THE TWO C NONLINEAR EQUATIONS. C C*************************** NOMENCALTURE ***************************** C C A ( I . J ) - THE JACOBIAN OF THE ITH EQUATION WITH RESPECT TO THE JTH C VARIABLE ( J - 1 V; J - 2 L) C B(I)- THE VALUE OF THE ITH EQUATION C DELTA- THE FRACTIONAL CHANGE IN V AND L USE TO CALCULATE THE C NUMERICAL DERIVATIVES C F(I)- THE EQUATION VALUE OF THE ITH EQUATION C L.Ll- THE REFLUX LIQUID FLOW RATE (^MOLES/HR) C H.M1,M2- THE NUMBER OF THEORITICAL STAGES IN THE RECTIFYING SECTION C N.N1.N2- THE NUMBER OF THEORITICAL STAGES FOR THE COLUMN C V.Vl- THE VAPOR BOIL-UP RATE FOR THE REBOILER (<>MOLES/HR) C X.Xl- THE COMPOSITION OF THE LIGHT COMP IN THE BOTTOMS C Y.Yl- THE COMPOSITION OF THE HEAVY COMP IN THE OVERHEAD C (;•*•>•;••>*******•***************•*•*•****•*•*•*****•*****•***•**••****••**•**

C SUBROUTINE DERP(II.Nl.Ml.V.L.Xl.Yl.A.B) IMPLICIT REAL*8(A-H.0-Z) DIMENSION A(3.3).B(3).F(3) REAL*8 I.11.N.N1.M.MI.L(3).L2.M2.N2.I2 l-Il N-Nl M-Ml X-Xl Y-Yl DELTA-.01

C DETERMINE F(I) FOR THE BASE CASE CALL EVALd.N.M.V.L.X.Y.F) B(l)-F(l) B(2) —F(2) B(3)-F(3)

C INCREMENT I I2-I*(1.+DELTA) CALL EVAL(I2.N.M.V.L.X.Y.F)

C DETERMINE PARTIAL DERIVITATIVES NUMERICALLY A(1.1)-(F(1)-B(1))/1/DELTA A(2.1)-(F(2)-B(2))/1/DELTA

Page 130: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

121

A(3.1)-(F(3)-B(3))/1/DELTA C INCREMENT N

N2-N*(1.+DELTA) CALL EVAL(I.N2.M.V.L.X.Y.F)

C CALCULATE PARTIAL DERIVITATIVES NUMERICALLY Ad.2)-(F(1).B(1))/N/DELTA A(2.2)-(F(2)-B(2))/N/DELTA A(3.2)-(F(3)-B(3))/N/DELTA

C INCREMENT M M2-M*(1.+DELTA) CALL EVAL(I,N.M2.V.L.X.Y.F) A(1.3)-(F(1)-B(1))/M/DELTA A(2.3)-(F(2)-B(2))/M/DELTA A(3.3)-(F(3)-B(3))/M/DELTA RETURN END SUBROUTINE CONST(K.L.V,I.N.M)

C C THIS SUBROUTINE CALCULATES THE VALUES FOR THE CONSTANTS REQUIERD C IN THE INTERMIDIATE CALCULATIONS FOR THE RECOVERIES. C

IMPLICIT REAL*8(A-H.0-Z) COMMON /VAR/F.B,D.G.R.NT.NJ COMMON /VAR3/PHI.PHIl.ALPHA,EGA.EGAl.GAMMA.GAMMAl,S(3).BETA DIMENSION K(3).L(3) REAL*8 K.L.I.N.M DO 200 II-l.3

C SEPARATION FACTORS CALCULATION C

Sdl) - K(II)*(V/L(II)) 200 CONTINUE

GAMMA - (S(2)-1.)/(1.-S(2)**N) XM - (S(3)**(M-2)-l.)/(l-S(3)) XM2 - (V*K(3)+B)/L(3) EGA - (XM/B)*(1-XM2) ALPHA - L(1)/(K(1)*D) GAMMAl - (S(2)**(N-1)-1.)/(1-S(2)**N) XXMl - L(l)*(l/K(l)-1.)/V XXM - (S(l)**(l-I)-l.)/(l/(S(l))-l.) EGAl - XXM1*XXM RETURN END

C************** CALCULATE K VALUES •*•*••***•**•***** C THIS SUBROUTINE CALCUUVTES THE K-VALUES FOR EACH OF THE COMPONENTS C USING ANTONINES CONSTANTS. C

SUBROUTINE KVAL(K.NJ.J) IMPLICIT REAL*8(A-H.0-Z) COMMON /VAR1/AA(3).BB1(3).CC(3).DD(3).X(3.3).P(3).T(3).TC(3).PC(3) DIMENSION K(3).P0(3).L(3).T1(3).TR1(3).PPC(3).TTC(3).W(3)

REAL*8 K.L C PPC ARE CRITICAL PRESSURES (PSIA) C. TTC - CRITICAL TEMPERATURE (DEC F) C W - ACTIVITY COEFFICIENT C

Page 131: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

122

PPC(l) - 709.8 PPC(2) - 617.4 PPC(3) - 550.7 TTC(l)-550.0 W d ) - .1064 TTC(2)- 665.9 W(2)-0.1538

C AA. BB. 6, CC ARE THE ANTOINES CONSTANTS C

AA(1) - 5.38394 BBld) - 2847.921 CCd) - 434.898 AA(2) - 5.353418 BB1(2) - 3371.048 CC(2) - 414.488 DO 1 N - 1,3 TR - TTC(J)/T(N) PR - PPC(J)/P(N)

POP - AA(J) - (BB1(J)/(T(N)+CC(J))) C CALCULATES PARTIAL PRESSURE

PO(N) - DEXP(POP)*PPC(J) PHX - PH(TR,PR,W(J))

C PHX - 1. C CALCULATES THE K-VALUE

K(N) - PO(N)/(P(N)*PHX) 1 CONTINUE RETURN END

C************* EVALUATE FOR RECOVERY RATES ************* C

C THIS SUBROUTINE CALCULATES THE RECOVERIES. AS WELL AS THE C THE DEVATION FROM THE REQUIRED RECOVERIES C

SUBROUTINE EVAL(I.N.M.V.L.XX.Y.FF) IMPLICIT REAL*8(A-H.0-Z) COMMON /VAR/F.B.D.G.R.NT.NJ COMMON /VAR2/FMB.GMB.DMB COMMON /VAR3/PHI .PHIl. ALPHA. EGA. EGAl .GAMMA.GAMMAl .S( 3) . BETA DIMENSION XX(3).Y(3).Z(3).A(3.3).BB(3).K(3).FF(3).FX(3).L(3) REAL *8 K.L.I.N.M J -1 DO 1 J - 1.2 CALL KVAL(K.NJ.J) CALL CONST(K.L.V.I.N.M) A(l.l) - (V*K(3)*ECA)+(V*K(3)/B) Ad.2) - -L(2)*GAMMA/G A(2.1) - -ALPHA*(EGA1+1.) A(2.2) - A(2.1)-V*K(2)*GAMMA1/G-L(2)/C-(V*K(2)/G)-1. BB(i) - (V*K(3)+L(3)-L(2)-L(2)*GAMMA-F)/F BB(2) - A(2.1)-V*K(2)/F*(1+GAMMA1)

Fl -(A(2.2)*BB(1)-A(1.2)*BB(2))/(A(I.1)*A(2.2)-A(1.2)*A(2.1))

CI - (BB(l)-A(l.I)*Fl)/A(l.2)

Dl - 1-Fl-Gl WRITE(6.102)F1.G1.D1

Page 132: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

123

c c C c c c

FF ARE THE DEVIATIONS OF THE CALCULATED RECOVER FROM THE REQUIRED RECOVERY

FFd)-Fl/FMB-l. FF(2)-G1/CMB-1. FF(3)-D1/DMB-1.

102 F0RMAT(6X.'F1-'.D12.5.'G1-',D12.5.'D1-'.D12.5) 1 CONTINUE RETURN END

//CO.SYSIN DD * 5.38389D+00 2.84792D-t-03 5.35342D+00 3.37711D+03 5.74162D+00 4.12639D+03

//

4.34898D+02-2.03539D+00 3.05400IH02 4.14488D+02-1.38551D+00 3.69800D+02 4.09518D+02-3.13O03D+00 5.63100D+02

4.88000D+01 4.25000D4 01 4.42000D+01

Page 133: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …

PERMISSION TO COPY

In presenting this thesis in partial fulfillment of the

requirements for a master's degree at Texas Tech University, I agree

that the Library and my major department shall make it freely avail­

able for research purposes. Permission to copy this thesis for

scholarly purposes may be granted by the Director of the Library or

my major professor. It is understood that any copying or publication

of this thesis for financial gain shall not be allowed without my

further written permission and that any user may be liable for copy­

right infringement.

Disagree (Permission not granted) Agree (Permission granted)

Student's signature Studentys signature

Date Date

Page 134: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …
Page 135: PROCESS MODEL BASED CONTROL OF DISTILLATION COLUMNS …