JOHN: Here we're gonna look at,
obtaining kinetic parameters,
if we were to do the experimental measurements,
in an isothermal plug flow reactor.
And we did those experimental measurements
by changing multiple reactor conditions.
And what I mean by that is if we have a reactor
and a reaction gas phase A goes to B.
And so we have flow rate of A
and in general flow rate of B entering the reactor.
What we're gonna measure is the flow rate leaving
that allows us to determine conversion.
And the parameters we're going to change
to make these measurements are these two flow rates
and the pressure in the reactor.
And then we're gonna use Excel spreadsheet
and nonlinear regression
to determine the kinetic parameters.
And that's for this rate expression
where this is a catalytic rate expression.
This is the rate constant,
this is adsorption equilibrium constant.
And so there are other screencasts
that describe the details of how we do calculations,
if we change just one condition, namely,
if we just change the inlet volumetric flow rate.
And so all the ideas are the same,
except now that we're changing three,
it's a little more complicated in some aspects,
but most of it is very similar.
So you should watch those screencasts
before watching this one, because it's not possible
to explain all the details in this one screencast
that are explained in several other screencasts.
So let's look at the approach.
So we're gonna use Excel
to solve ordinary differential equation mass balance.
In this case, use a fourth order Runge-Kutta method,
fixed step size where the dependent variable
is the molar flow rate.
The independent variable is the cumulative volume
in the reactor.
And we're gonna actually solve two differential equations.
So I've written down the mass balance
in terms of molar flow rate, rate of reaction for A and B.
Now, we don't actually have
to solve two differential equations
because if we know the flow rate of A,
then we can determine the flow rate of B
from stoichiometry and from our initial conditions.
But I've done this just to show you more general procedure
that we can solve more than one differential equation,
simultaneously in Excel,
just using, in this case, a fixed step size.
Now I won't go through all the equations,
but you can pause the screencast
and look at these, they're more detailed,
they're certainly explained in more detail
in the other screencasts.
So the things that are different from those others is
that we're solving in terms of flow rate of A.
So each new value, the flow rate if we take a step,
we calculate from that small step, dV
and the rate of reaction.
We also have to calculate the concentration at each step
because the concentration is related
to the molar flow rate, which is changing.
So that is the difference from the other screencasts
where we only were changing the feed volumetric flow rate.
Because we have three reactor conditions
that we're changing.
We have to create more than one data table.
For this particular example, I've created two data tables.
We could certainly have done it with three data tables,
but that's just a matter of how we carry our experiments,
what conditions we need.
Excel then solves the ordinary differential equations
for each set of values
and puts the output into those data tables.
And it can do this relatively quickly
for solving the differential equations
for 10 or 15 different conditions.
What we do next is guess values for the rate constant
and the adsorption equilibrium constant.
Use Solver to minimize the sum of squares of residuals.
This is the equation for the residuals,
the flow rate at the exits.
So FA in the spreadsheet,
and then we square this and that's what we're minimizing.
And then the last step is
to calculate the confidence intervals.
So let's look at the spreadsheet just briefly.
So you get an idea of what we're doing.
So here's the part of the spreadsheet
where we're solving the differential equations.
We calculate these K values that are
in the Runge-Kutta calculation.
Here are our two parameters
for adsorption equilibrium constant
and K that we've calculated when we run the Solver
for nonlinear regression.
These are the values we use to generate the data.
So I've generated the data and then added some noise
to that data and called that experimental data.
You can see as we step through,
we're calculating flow rate of A, flow rate of B.
And as we step through here in a volume change of 0.05.
We also remember to calculate the concentration of A,
since we need that in the rate expression.
And then what I'm showing on the right,
are the two data tables.
In this case, for these values of the flow rate of A
and for these pressures and for flow rate of B of zero.
I could generate all these solutions
by repeatedly solving these ordinary differential equations.
And then the second table shows where we fixed the flow rate
of A and again, we saw for all these values.
We don't use all these values,
but it's much easier to generate them all.
And then pick out the values.
These are our experimental conditions.
So if I picked the value from the table, for example,
for flow rate of A of 40
and B of zero and a pressure of 1.5
That's this value here that gets put in here.
Here are our experimental values,
residuals, square the residuals.
This is what we minimize with Excel Solver.
The other aspect then is,
calculating the confidence intervals.
And I won't go into details of how we've done this,
but what's important to note is that we're going
to take a...
Calculate values for the
adsorption equilibrium constant and the rate constant.
And for a small difference, delta value.
So this is, KA[1+delta], KA[1-delta].
And it's this likewise for the rate constant term.
We then calculate how that changes the flow rates,
leaving the reactor
by solving the differential equations
for the different K values.
Here are the solutions.
Here are the solutions
when we change different rate constant values,
and we've essentially made small changes in the K values
and looked at small changes in the flow rates.
And we can use that to approximate the partial derivatives.
And then the solution here.
And this is described more detail elsewhere.
Our parameters and our confidence intervals.