Brand Logo
Brand Logo

Improving Soft Sensor

Author:

Alden Olyniec

Alden Olyniec

At the end of the last blog, we took note of an somewhat unexpected behavior where, during a MFR transition, the density controller automatically detected density drift and moved comonomer molar ratio.

Below shows one such MFR transition, where the density controller failed to predict the drift in density caused by MFR movements and had to rely on feedback action as lab results became available, leading to 6 hours of out of specification density production.

MFR Transition with original density model
MFR Transition with original density model

The original set of soft sensors we developed were effectively single-input single-output. We had observed during exploratory data analysis that rH2 was correlated with MFR and rM2 was correlated with density, and no other variables showed significant correlation with either resin properties. The pair-plots supported these observations as well.

However, once we actually applied the models for control, we saw that there is obviously some relationship between either rH2 or MFR with density.

In this blog, we will explore other predictors of MFR and density, incorporate them into the model, and re-deploy the upgraded models. We will also look into other ways of improving control performance when using soft sensors.

Improving the density model

We know either rH2 or MFR somehow affect density, but which one? Actually, it is well known that MFR has an effect on density; physically, this effect can be understood by thinking about packing efficiency of long rigid chains - the longer the chains, the more they tangle, and the less tightly they pack together.

Unfortunately, we cannot use MFR directly as a predictor for density since we do not have a good estimate of instantaneous MFR (recall that our model does exhibit varying degree of offset depending on the grade). On the other hand, hydrogen mole ratio rH2, which we know to be the primary driver of MFR, is readily available and measured on-line frequently.

Before we fit the model though, let's see if the residuals (i.e., the unexplained variance) of the model is at all correlated with either rH2 or MFR. If our eyes didn't lie to us, there should be some clear correlations.

Density Model Residuals
Density Model Residuals

Indeed, the Pearson correlation coefficient, which tells us if the variables have a linear correlation with each other (a value of -1 means perfectly negatively correlated, a value of 1 means perfectly positively correlated, a value of 0 means no apparent correlation), suggests there is a strong linear correlation of rH2 with the density model residual. That is,

e_\rho\equiv\rho-(c_1\times r_{M2} + d)\propto r_{H2}

where c_1 and d are the fitted coefficient and intercept, respectively. From the residual equation above, we can rearrange and write directly the new density model using rH2 as the additional predictor.

\rho=c_1\times r_{M2} + c_2\times r_{H2} + d + e

Fitting the new density model to the same dataset, we get the following. The errors/residuals are still mostly spread around 0, and a positive relationship between rH2/MFR and density emerged. That makes sense - more hydrogen leads to shorter chains, facilitating tighter packing and thus higher density.

New Density Model Diagnostic
New Density Model Diagnostic

Applying The Improved Density Model

Without further ado, let's apply the new density to the same MFR transition and see if it is any better! Conveniently, since we are working with simulations, it is possible to rerun the exact same transition with the same starting conditions. Actual evaluation in a real plant environment is bound to be more troublesome.

MFR Transition with new Density Model
MFR Transition with new Density Model

Check that out, the density controller now proactively increases rM2 as the MFR controller increased rH2, leading to a much stabler density trajectory! Nevertheless, it seems the rH2 overshoot caused by poor rH2 controller tuning did almost drive the MFR out of spec. Let's fix that...

MFR Transition with new Density Model and better H2 tuning
MFR Transition with new Density Model and better H2 tuning

After tuning the hydrogen controller (it was a standard PID controller), the MFR response now looks even better. This is a great example demonstrating the necessity of good inner loop tuning for successful deployment of advanced process control (APC) systems and the need for consistent loop monitoring to properly identify which control loops are drifting and potentially causing issues in its cascades. Atlas' Remote Resident is a cost effective way to offload all your loop monitoring, troubleshooting, and tuning needs at the fraction of the cost of a full time engineer. Reach out today to learn more about it!

Elephant In the Room - Lab Errors

Throughout the blogs in the soft sensor series, we have been relying on lab results are the ground truth for our analysis. However, anyone who has had the honor of dealing with labs know better to trust them blindly.

MFR and density lab results are especially prone to error and difficult to leverage due to two reasons:

  • They are infrequent - resin samples are usually taken once every couple hours, making them few and far between. Retesting a sample is also slow.
  • They are suspectable to variability due to sampling and preparation technique, and sometimes even interpretation method.

Thus, our current approach with IMC, which takes the entire model error as correction in the reference trajectory, is suspectable excess lab-originated noise propagating through the controller into the process.

In a future blog, we will explore how to overcome the noise issue using more advanced techniques such as Kalman Filters and its siblings, which take into account measurement and model variance when updating model parameters or estimates.

People

Alden Olyniec

Alden Olyniec

Alden leads technical development of Atlas Advisor™, Atlas’s on-premise control-room intelligence tool. His work sits where chemical engineering, advanced process control (APC), and machine learning meet inside live process units. His earlier Atlas work spans APC commissioning, first-principles reactor simulation, and IMC/MPC correction. He built a gas-phase copolymerization reactor testbed in Python that removed the dependency on third-party plant trial access during controller testing. He also completed multiple on-site commissioning cycles in China, supporting operators and troubleshooting in Mandarin.

Alden leads technical development of Atlas Advisor™, Atlas’s on-premise control-room intelligence tool. His work sits where chemical engineering, advanced process control (APC), and machine learning meet inside live process units. His earlier Atlas work spans APC commissioning, first-principles reactor simulation, and IMC/MPC correction. He built a gas-phase copolymerization reactor testbed in Python that removed the dependency on third-party plant trial access during controller testing. He also completed multiple on-site commissioning cycles in China, supporting operators and troubleshooting in Mandarin.

Alden leads technical development of Atlas Advisor™, Atlas’s on-premise control-room intelligence tool. His work sits where chemical engineering, advanced process control (APC), and machine learning meet inside live process units. His earlier Atlas work spans APC commissioning, first-principles reactor simulation, and IMC/MPC correction. He built a gas-phase copolymerization reactor testbed in Python that removed the dependency on third-party plant trial access during controller testing. He also completed multiple on-site commissioning cycles in China, supporting operators and troubleshooting in Mandarin.

Madhur Bedre

Madhur Bedre

Madhur Bedre is the founder and president of Atlas Prediction Control. A chemical engineer by trade, he built his process control and APC expertise from supporting a number of polyethylene and polypropylene startups and upgrade projects around the world on contract assignments for large licensors such as Univation Technologies and WR Grace. He founded Atlas in 2019 and built it into a world-renowned leader in practicing implementors of APC and AI technologies for chemicals and petrochemicals industries. He received the Small Business Person of the Year award from the U.S. Small Business Administration for West Virginia in 2026. Atlas is also proud to be a part of the Goldman Sachs 10000 Small Businesses WV 2026 cohort.

Madhur Bedre is the founder and president of Atlas Prediction Control. A chemical engineer by trade, he built his process control and APC expertise from supporting a number of polyethylene and polypropylene startups and upgrade projects around the world on contract assignments for large licensors such as Univation Technologies and WR Grace. He founded Atlas in 2019 and built it into a world-renowned leader in practicing implementors of APC and AI technologies for chemicals and petrochemicals industries. He received the Small Business Person of the Year award from the U.S. Small Business Administration for West Virginia in 2026. Atlas is also proud to be a part of the Goldman Sachs 10000 Small Businesses WV 2026 cohort.

Madhur Bedre is the founder and president of Atlas Prediction Control. A chemical engineer by trade, he built his process control and APC expertise from supporting a number of polyethylene and polypropylene startups and upgrade projects around the world on contract assignments for large licensors such as Univation Technologies and WR Grace. He founded Atlas in 2019 and built it into a world-renowned leader in practicing implementors of APC and AI technologies for chemicals and petrochemicals industries. He received the Small Business Person of the Year award from the U.S. Small Business Administration for West Virginia in 2026. Atlas is also proud to be a part of the Goldman Sachs 10000 Small Businesses WV 2026 cohort.