Wednesday, October 24, 2012

Generation of Equilibrium Curve for the Use of McCabe-Thiele method

As I did separation homework, questions sometimes asked to plot given data points to construct equilibrium curve before doing anything. This can produce errors because hand construction of curve is not accurate enough. In order to avoid this and get to the real question faster, I developed a .m Matlab file to generate the curve automatically.

Users need to input liquid and vapor compositions. Then curve will be plotted for further use. I am not sure if this is actually helping you. But I feel the joy doing it.

Below is an example and the consequent curve.

Step 1. Open and run the Equilibrium.m file


Step 2. Input liquid compositions from lowest to highest. Remember to enter 0 in the beginning and 1 at the end. This should be in a vector form, which is in a pair of [ ] and separated by a space. For example,

Step 3. Input vapor compositions in the same manner as Step 2. For example,

Step 4. An equilibrium curve should be generated like the following graph.

If you need to download the .m file. You can do so by going to the following link. Thank you.

Sunday, October 21, 2012

Non-Elementary Reaction with Elementary Rate Law

There are many non-elementary reactions following the elementary rate law. How can someone spot them? This is an application of PSSH (Pseudo-Steady-State Hypothesis).

For example:

(CH3)2O à CH4 + H2 + CO

We can say this is a reaction follows the form of
AàP
rp = -k[A]
The mechanism of this reaction consists of 3 elementary reactions.

1. Activation of A: A + M àA* + M          (K1 as rate constant)
2. Deactivation of A*: A* + M àP + M     (K2 as rate constant)
3. Decomposition of A*: A*àP                  (K3 as rate constant)

Here: M is inert species that does not react at all. A* is denoted as the active intermediate of A. Its presence is due to collision of A molecules. When collision occurs, kinetic energy of one A molecule is transferred to internal rotational and vibrational energies of the other A molecule, so it is activated and being highly reactive. 

From 1. r1A* = k1[A][M]
From 2. r2A* = -k2[A*][M]
From 3. r3A* = -k3[A*]
             rp = k3[A*]

Now we will apply PSSH, which states that the net rate of formation of an active intermediate is zero.
rA* = r1A* + r2A* + r3A*
rA* = k1[A][M] - k2[A*][M] - k3[A*]

Apply PSSH, rA* = k1[A][M] - k2[A*][M] - k3[A*] = 0

Solve for [A*]

Since rp = k3[A*], by substitute this, we get the following.
Because concentration of M is constant, we say the following.
 So, rA = -rp = k[A]

This shows the reaction follows first order rate law, and it is elementary. But, again, the reaction is not an elementary reaction. However, it is a series of elementary reactions.

PS: In a rate law, if there is a concentration in the denominator, it is probably the species that is colliding with the active intermediate. If there is a constant in the denominator, that probably implies there is a reaction step which is the decomposition of the active intermediate. If there is a concentration in the numerator, that probably says there is a step to produce the active intermediate.

Saturday, October 20, 2012

Feedback Control Closed-Loop Transfer Function


Figure source:

B. Bequette, Process control: modeling, design. and simulation, Prentice Hall Press, Upper Saddle River, NJ 2002

Block diagram (Laplace domain) variables:
c(s) = controller output
e(s) = error
r(s) = setpoint (reference signal)
u(s) = manipulated variable
l(s) = load disturbance
y(s) = process output
ym(s) = measured output

Transfer functions:
gc(s) = controller
gv(s) = valve
gp(s) = process
gm(s) = measurement
gCL(s) = closed-loop
gd(s) = disturbance

Calculations:

y(s) = l(s)gd(s) + u(s)gp(s)
u(s) = c(s)gv(s)
c(s) = e(s)gc(s)
e(s) = r(s) – ym(s)
ym(s) = y(s)gm(s)

Lump all expressions together, we can get the following:

y(s) = l(s)gd(s) + c(s)gv(s)gp(s)
y(s) = l(s)gd(s) + e(s)gc(s)gv(s)gp(s)
y(s) = l(s)gd(s) + (r(s) – ym(s))gc(s)gv(s)gp(s)
y(s) = l(s)gd(s) + (r(s) – y(s)gm(s))gc(s)gv(s)gp(s)

then:
Equation (1)

If there is no disturbance:

Equation (2)


Equation (3)