Wednesday, January 15, 2014

DeltaV Insight - Dealing with Wrong Modes

DeltaV Insight is Emerson’s next generation control monitoring and tuning application.  It was introduced in DeltaV Version 9.3 replacing DeltaV Inspect and DeltaV Tune in earlier versions.  The control performance monitoring piece of DeltaV Insight monitors how well your control loops are performing.  It does this by constantly monitoring for control loops that fall into the following 4 categories.

·         Incorrect Modes
·         Control Limited
·         High Variability
·         Questionable Inputs

This blog will focus on the first of these categories; Incorrect Modes.

If your site is anything like mine, as soon as you begin enabling control loops for monitoring in DeltaV Insight, you will begin to see loops that are being flagged as having an incorrect mode.  Any loop whose “Actual” Mode is not equal to the “Normal” mode will be flagged.  In many cases, sites have not even made an attempt to set the “Normal” mode.

The default “Normal” mode in the PID function block is AUTO.  If the control loop is the secondary loop of a cascade strategy, then the normal mode needs to be changed to CAS or RCAS.  Some control loops normally operate in manual and their normal modes will need to be set accordingly.

Changing Normal Mode Values

The normal mode value is an attribute of the MODE parameter for any function block that supports mode.  It can be set from DeltaV Explorer or DeltaV Control Studio.  The allowable values area any of the current permitted and operator selectable modes.  This means that IMAN and LO cannot be sued for normal modes.

The normal mode can be changed online from DeltaV Insight.  Drill down to a single function block in the Insight tree and select the Summary tab.  From there you can make an online change to both the target mode and the normal mode.  Unfortunately, because of the way that this change is written to the change log, it cannot be uploaded into the configuration database.  To make the change permanent you will need to make the change in Control Studio or DeltaV Explorer.

Dealing with Multiple Normal Modes

Sometimes a control loop can have more than one normal mode.  In this case, you will need to add some logic to programmatically modify the normal mode values based on the criteria that you define.  Some of the situations that I have found where this is required are listed below.

1.      Loops that are only intermittently used.  When not in use, the loop will be in MAN with an output of 0.0%.  When it is in use, the loop should be operated in AUTO.  You can use the controller output value as the trigger to change the normal mode.  To do so, just insert the following code into a CALC block inside the module.  The value of OUT that you use as the trigger condition can be set to any appropriate value.

(* Set Normal mode = MAN if actual mode is MAN and output < 10% *)
IF ‘^PID1/MODE.ACTUAL’ = MAN AND ‘^PID1/OUT.CV < 10 THEN
   IF ‘^PID1/MODE.NORMAL’ != MAN THEN
      ‘^PID1/MODE.NORMAL’ := MAN;
   ENDIF;
ENDIF;

(* Set Normal mode = AUTO if actual mode is MAN and output > 10% or actual mode is AUTO*)
IF (‘^PID1/MODE.ACTUAL’ = MAN AND ‘^PID1/OUT.CV >= 10) OR ‘^PID1/MODE.ACTUAL’ = AUTO  THEN
   IF ‘^PID1/MODE.NORMAL’ != AUTO THEN
      ‘^PID1/MODE.NORMAL’ := AUTO;
   ENDIF;
ENDIF;

2.      Loops that have multiple valid normal modes, for example, AUTO and CAS.  In this case you could use code similar to that above to set the normal mode to AUTO if the actual mode is AUTO and set the normal mode to CAS if the ACTUAL mode is CAS.

Dealing with IMAN and LO

There are two modes, IMAN (Initializing Manual) and LO (Local Override) that are not operator selectable and cannot be set as the normal mode.  The actual mode of the primary loop of a cascade control strategy will go to IMAN if the actual mode of the secondary loop is not CAS.  This will trigger an incorrect mode in DeltaV Insight for both the primary loop and the secondary loop.  If this is sometimes a normal operating condition, you could set the normal mode of the secondary loop to AUTO but there is no way to keep the IMAN in the primary loop from being flagged in DeltaV Insight.

The same is true for LO mode.  Any loop in LO mode will be flagged by DeltaV Insight regardless of the target mode.  The only workaround I have found is to redesign the control logic to use something other than the tracking function to manipulate the loop output.  One option would be to use the ROUT mode to set the loop output.

Thursday, September 12, 2013

Using the Rosemount 3051 Scaled Variable

The Rosemount 3051 DP and pressure transmitters (Rosemount 3051) have a functionality called Scaled Variable that we have found very useful for a variety of reasons.  In this post I’ll share some of our experiences with this feature. 

The scaled variable allows you to configure the relationship between the transmitter variable and real world engineering units in either a linear or square root function.  You define the engineering units, an upper range limit and a transfer function.

History

The concept of a scaled variable was first introduced in the 3051 Revision 3.   In this revision it was called a Custom Meter Scale.  Configuration consisted of a transfer function (Linear or Square Root), an engineering units string, number of decimal places, and an upper scale value in engineering units that corresponds to the transmitter upper range limit.  The custom meter scale value was not assigned to one of the 4 HART variables.

In Revision 6 of the transmitter, the Scaled Variable as we know it today was introduced.  Configuration was through a “Configure SV” method.  The scaled variable value was assigned by default to the TV HART variable.

In Revision 7 of the transmitter, the functionality remained the same but with the new EDDL, the method was replaced with a pushbutton and the ability to trend variables was added.  By default the scaled variable value was assigned to the TV HART variable.

Why Use the Scaled Variable?

Using the Scaled Variable provides a number of useful benefits.

1.      The scaled variable allows the engineering unit value to be visible within the transmitter from either AMS or the handheld communicator.
2.      The scaled variable configuration documents the associated engineering unit range values within the transmitter.  With the QuickCheck Snap-On (QuickCheck Snap-On) a report can be generated that shows the transmitter configuration for both the DP and engineering units.
3.      The Scaled Variable is not limited at the transmitter Upper Range Value.  The transmitter will continue to calculate the Scaled Variable value all the way to the transmitter Upper Sensor Limit.  For example, let’s look at a 3051S Range 2 (+/- 250 inH2O) DP flow transmitter configured for 10 GPM at 100 inH2O.  At a DP just above 100 inH2O, the transmitter will become saturated and the analog output will be 20 mA.  However, the scaled variable calculation will continue all the way to a differential pressure of 250 inH2O and will indicate a scaled variable value of 158 GPM.
4.      In DeltaV, the Scaled Variable value can be brought into control strategies with a standard AI function block configured to the HART variable associated with the scaled Variable (TV by default).  A word of caution.  The update rate of the HART variables is not fast enough for closed loop control.  Do not use the scaled variable value for control.
5.      If you are using the new DeltaV CHARMS I/O, the HART variables can be viewed within DeltaV Diagnostics.  Having the engineering unit value available along with the primary transmitter variable can be useful for troubleshooting.

Using the Scaled Variable as the PV

It is possible to use the Scaled Variable as the PV.  To do so, you assign the Scaled Variable to the PV in the HART variable mapping.  When you do this, the Upper and Lower range limits of the transmitter must be entered in the scaled variable units.  The transmitter transfer function must be changed to linear because the square root function is now part of the scaled variable calculation.  Additionally, you would not use a square root transfer function in the DCS input block.

We have chosen not to do this for our flow transmitters.  For an instrument technician, using the scaled variable as the PV completely changes the interaction with the transmitter and could potentially be confusing.

Summary

We have found that configuring the scaled variable in the Rosemount 3051 DP pressure transmitters has value.  It takes an extra 30 seconds or so to do the configuration but the value justifies the extra time.  I would really be interested in comments from others that have experience with the scaled variable.

Friday, September 6, 2013

So You Think Your Flow Meters are Correct? - Part 3

In Parts 1 and 2, I wrote about some of the things that I found after doing a verification of the flow meter calculations and transmitter configurations in our diesel hydrotreater unit.  I discussed how mistakes during engineering, procurement, startup and ongoing maintenance can lead to flow meter errors.  In this post, I will describe some of the things that we have done to prevent these errors from causing problems in the future.

Double Check Flow Calculations

When you receive flow meter calculations done by others, take the time to double check the results.  We have decided to standardize on the Instrument Toolkit Software (Rosemount Instrument Toolkit) by Rosemount to do our internal flow meter calculations.  When we receive calculations from others, we reproduce the calculations in the Instrument Toolkit.  This not only verifies the results but allows us to have a method to revise the calculations if process conditions change.

Consolidate Your Documentation

I hate to admit it, but we had flow meter documentation stored in a variety of places.  For many years, we tried to keep paper datasheets done before the digital age in a master “Orifice Book”.  I later years, this was moved to an electronic spreadsheet that frequently did not contain all of the data required to reproduce the calculations.  We also had datasheets stored in the project manuals that get distributed at the end of a major project and in electronic project files that we archive after a project is complete.

We are now in the process of locating as much of this documentation as we can and storing it in digital format in a common location.  Having a single location for all of this documentation has proved extremely valuable.

Audit Your Field Devices

We have the AMS Intelligent Device Manager (AMS Device Manager) integrated into our DeltaV System.  We have DeltaV Maintenance Workstations that are also AMS Clients distributed throughout the refinery.  Engineers and Instrument Technicians use these workstations to communicate to our HART and Fieldbus devices.  We also use the QuickCheck Snap-On (QuickCheck Snap-On) to pull data from multiple HART and Fieldbus devices.  QuickCheck has proven invaluable for auditing field devices to insure that they are properly configured.

Review Your Maintenance Work Practices

Take a look at your work practices and procedures to insure that when transmitters are modified or changed that everything gets done correctly.  This includes the DCS side of things because DCS changes frequently have to be made at the same time that devices changes are made.

I would be interested in feedback from other users that have struggled with similar flow meter issues.

So You Think Your Flow Meters are Correct? - Part 2

In Part 1, I wrote about some of the things that I found after doing a verification of the orifice calculations and transmitter configurations in our diesel hydrotreater unit.  I focused on the design phase of the instrument lifecycle.  Two systemic errors in the orifice calculations done by the E&C firm led to errors on about 75% of the meters in the unit.  In this post, I'll discuss some of the things that we found that were the result of events that took place after the unit was started.

Commissioning and Startup

Anyone that has gone through the commissioning and startup of a new unit knows the challenges of dealing with DP flow measurement.  Orifice plates get mixed up, they get installed backwards, transmitters get installed backwards, impulse lines leak and the orifice plates act as strainers for all of the trash left in the lines during construction.  We assume that once we get all of these issues resolved and our meters are finally working, we can begin to relax.  Think again.  There are any number of things can go wrong over the next several decades that the unit will operate.

Ongoing Maintenance and Operation

Today's high quality transmitters last a long time.  We have some Rosemount 1151 pressure transmitters that are more than 25 years old and still going strong.  During the life of a transmitter it may get re-ranged or relocated.  Transmitters fail and get replaced.  The control systems that these transmitters are connected to may get upgraded or replaced.  Every time one of these events take place, something can go wrong that will cause a flow meter to read incorrectly.  Some of the things that we have found are listed below.

Incorrect Re-ranging - We found two transmitters that had their range in the DCS increased by a factor of two.  We assume that everyone knows that the DP increases with the square of the flow.  Not so in this case, as the DP in the transmitter was also increased by a factor of 2 instead of 4.

No Transfer Function - Somewhere in the loop, a square root transfer function has to be applied to the signal.  This can be done in either the transmitter (if it is smart) or the DCS.  Our standard is to do it in the transmitter.  We found two transmitters in this audit than did not have the square root transfer function enabled.

Changes in Service Conditions - Sometimes service conditions change and orifice calculations have to change with them.  In our hydrotreater audit, we found one meter whose service had changed.  The temperature and pressure conditions were similar but the molecular weight changed by a factor of 4.  That makes a big difference in the calculated differential pressure.
Physical Changes - We had one meter in the hydrotreater unit where we were unable to rationalize the orifice calculation and the transmitter configuration.  We finally sent someone to field verify the orifice bore.  It turns out that the bore was different than the documentation.  The transmitter was actually correctly configured.  Sometime in the past the orifice was changed and the transmitter was reconfigured but the documentation was not updated.

We have learned a lot from this and other flow audits.  In Part 3 of this series, I'll talk about what we have done to prevent some of these errors from happening in the future and insure that our flow meters stay as accurate as possible.

So You Think Your Flow Meters are Correct? - Part 1

Flow is probably the most important measurement in the process industries.  The ability to measure and control the flow of materials through the various parts of a process is critical for most all unit operations.  Good flow measurement is essential for mass and energy balances and other calculations used to evaluate process performance.

Differential pressure based flow elements are still the primary mechanism for flow measurement in most locations.  The basic technology behind DP flow has been around for over a century. It has been around for so long that we sometimes take it for granted.  There are many places where this well-known technology can go wrong and give us less than satisfactory results. 

During a recent process control audit of our diesel hydrotreater unit, I decided to verify all of the orifice calculations and DP transmitter configurations in the unit.  I was unpleasantly surprised at the results.  They were a perfect example of many of the things that can go wrong in the design, procurement, installation, commissioning and maintenance of a flow measurement device.  It was a good reminder of the things that we should all be aware of in the life cycle of a DP flow device.  In the sections below, I'll share what I found and what we can all learn from it.

Anyone Can Size an Orifice, Right?

There are hundreds of programs available to do the basic calculations required to size a DP flow measurement device.  All of them use the same basic equations and will generally give the same results.  The problem is with the data that goes into the calculations.  When I reviewed the calculations made by the E&C firm that built the unit 9 years ago, I found two fundamental flaws that created significant errors in about 75% of the meters in the unit.

Our refinery sits at an elevation of 3200 ft.  That means that our atmospheric pressure is not 14.7 psia but 13.1 psia.  We always use 13.1 psia to convert to absolute pressure.  The E&C firm that did the calculations used the 13.1 value as requested.  However they also used 13.1 instead of 14.7 as the pressure value in the definition of “standard” conditions.  It sounds like a small thing but it resulted in an error of about 15% in all of our gas flows that were referenced back to standard conditions.

Refineries in the US typically measure hydrocarbon flows in Barrels per Day (BPD).  These volumetric measurements are converted back to the density of the fluid at 60 degrees F. This allows flows of the same material to be compared without having to compensate for temperature.  The original E&C firm calculations were done in GPM at flowing conditions and were not corrected back to standard conditions.  When the ranges were configured in the DCS they were converted to BPD but were not corrected then either.  This resulted in errors of a few percent to almost 80% depending on how far away the flowing temperature was from 60 degrees F.

These two simple mistakes resulted in bad flow measurement indications on about 75% of the meters in the unit that were not identified for almost 9 years. 

This was not the first time that we have found errors in orifice calculations done by others.  A couple of years ago we had to replace a 6" stainless steel venturi two weeks before a turnaround when we discovered that someone had misplaced a decimal point in the gas density used in the calculation.

Orifice calculations are simple, right?  We assume that anyone can do them and we generally accept the results without question.  However, this practice will lead to errors that may cause problems during startup, or worse yet, go undetected for years.

In Part 2, I'll discuss other things that can go wrong during procurement, startup and ongoing maintenance of a DP flow meter.

Thursday, September 5, 2013

About this Blog

My name is Jay Colclazier.  I am a Sr. Automation Engineer at the CHS Refinery in Laurel, MT.  My intent with the blog is to share some of my experience with the day to day challenges of process improvement with automation.  In this first post I will share a little about myself.

I have been doing process automation work for over 35 years.  My time has pretty much been split between end-users and Emerson Process Management.  As an end-user, I have worked for Monsanto, Celanese , Biosource Fuels and now CHS.  My primary focus areas here at CHS are automation project execution and a variety of process improvement activities. 

During my time with Emerson, I was involved with engineering, sales and product marketing and industry consulting.  I have experience in a variety of different industries.  I have experience with DeltaV, PROVOX and RS3 DCS platforms as well as a wide variety of Emerson field devices.

For the last 5 years, I have been on the Board of Directors for the Emerson Global Users Exchange and served as Chairman during 2012.

There a lot of technology and product blogs availble in the automation industry today.  However, very few are written from an end-user perspective and focused on the day to day real world challenges of process improvement.

I welcome any feedback you may have!